telldus / tellstick-server-plugins

Plugins for TellStick Server
14 stars 8 forks source link

Problem building http plugin #5

Open xeor opened 5 years ago

xeor commented 5 years ago

Just a heads-up in this repo as well...

Building the http plugin gives this error:

.... File "/data/repo/tellstick-server/sdk/sdk/plugin.py", line 189, in __downloadRequirements '--dist-dir', self.packageDir File "/usr/local/lib/python2.7/distutils/core.py", line 218, in run_setup exec f.read() in g, l File "", line 25, in File "", line 15, in get_version NameError: global name 're' is not defined Could not build plugin

Created a simple fix and made an issue @ https://github.com/chardet/chardet/issues/166

Anyone else managed to build this plugin without manual fixes?

d01mf commented 4 years ago

I've run into the same issue. How do you apply your workaround? chardet is fetched on the fly so I'm not sure how to modify it before it gets picked up by the plugin build flow.

rullen commented 4 years ago

It seems like the issue was fixed in chardet and merged into master for 8 days ago. It this issue solved then? I want to use the HTTP plugin but I am not comfortable in building the plugin by myself and the Telldus support answered me that the plugin could not be compiled.

mickeprag commented 4 years ago

Unfortunately this is not yet resolved and this plugin is not stable. https://github.com/scoder/lupa/issues/84

martinmuntzing commented 4 years ago

Assuming this is still an issue (TellStick 1.2.0), are there any decent workarounds for exposing http functionality in the Lua script engine? It's such a versatile capability, and I'd love get started using it.

I'm not familiar with the language(s) or architecture at all, so rookie thoughts: can native Lua http request classes be made available instead? Is using a different Python lib than 'requests' possible, and could cause fewer problems?

(crossing fingers...)

mickeprag commented 4 years ago

Assuming this is still an issue (TellStick 1.2.0), are there any decent workarounds for exposing http functionality in the Lua script engine?

The current workaround is to disable reading the response from the http stream. To only support "fire and forget". And finding the time to implement that.

can native Lua http request classes be made available instead?

Unfortunately not

martinmuntzing commented 4 years ago

Check. Thanks, @mickeprag. And the pushover plugin works because it only does http handling inside the plugin, never exposing that object to Lua? (also uses httplib it seems, but that is probably irrelevant here)

atchoo78 commented 4 years ago

And the pushover plugin works because it only does http handling inside the plugin, never exposing that object to Lua? (also uses httplib it seems, but that is probably irrelevant here)

Perhaps generally irrelevant, but still relevant and useful to me ATM, so thanks for clearing that up (both of you).