Page 1 of 1

Python Plugin Beta for Synology

Posted: Wednesday 01 February 2017 22:30
by jumbotroll
Python Plugin Beta for Synology packages.
This packages requires Python 3.5.1-0xxx.spk installed before you install or update the domoticz synology package!
Install the Python 3.5.1-0xxx.spk from Synology (Not the package from Synocommunity)
http://archive.synology.com/download/Package/spk/py3k/

http://www.jadahl.com

The plugins folder is located in /usr/local/domoticz/var/plugins on synology!
After you have installed a plugin.py you have to restart (stop/start) domoticz in Package Center to activate your plugins.

Re: Python Plugin Beta for Synology

Posted: Thursday 16 February 2017 0:47
by waaren
Hi Jumbotroll,'

I would like to test the buienradar plugin but I am on synology DSM 6.1 RC (916+).
Domoticz version: 3.6708, Build Hash: 7b91f74-modified, Compile Date: 2017-02-14 16:52:55

Much obliged if you could point me in the right direction.

Re: Python Plugin Beta for Synology

Posted: Thursday 16 February 2017 11:11
by jumbotroll
waaren wrote:Hi Jumbotroll,'

I would like to test the buienradar plugin but I am on synology DSM 6.1 RC (916+).
Domoticz version: 3.6708, Build Hash: 7b91f74-modified, Compile Date: 2017-02-14 16:52:55

Much obliged if you could point me in the right direction.
I have compiled domoticz Beta versions with Python plugin for DSM6.1 here: http://www.jadahl.com/

Remember to install Python 3.5.1 package from synology before you install domoticz with python.

Re: Python Plugin Beta for Synology

Posted: Friday 17 February 2017 0:11
by waaren
Hi Jumbotroll,

thank you very much for the time and effort. Much appreciated !
I installed the Beta version with the Python plugin activated and everything I checked sofar works including the buienradar plugin.
Only thing I noticed with this version and not with the previous Beta's is Solved by
/usr/local/domoticz/www/i18n:$sudo cp domoticz-ru.json.gz domoticz-et.json.gz
/usr/local/domoticz/www/i18n:$sudo cp domoticz-ru.json.gz domoticz-lv.json.gz
as described in bug area of this forum

Re: Python Plugin Beta for Synology

Posted: Friday 17 February 2017 0:42
by jumbotroll
@waaren
I know about the Browser Cache bug, and the developers to I think :-)
I will compile/update my packages when this is fixed.

Re: Python Plugin Beta for Synology

Posted: Sunday 05 March 2017 16:13
by CRB7
I've try the new domoticz package for DSM 6.1, but when I made an update my scripts folder goes away.

I've several python script so I need to recreate folder an copy all scripts back.

Is there anything I does wrong or is it a normal behaviour ?

Re: Python Plugin Beta for Synology

Posted: Sunday 05 March 2017 16:38
by jumbotroll
CRB7 wrote:I've try the new domoticz package for DSM 6.1, but when I made an update my scripts folder goes away.

I've several python script so I need to recreate folder an copy all scripts back.

Is there anything I does wrong or is it a normal behaviour ?
Fixed!
All versions is updated.

Re: Python Plugin Beta for Synology

Posted: Tuesday 07 March 2017 20:32
by CRB7
Thanks ;)

Re: Python Plugin Beta for Synology

Posted: Saturday 08 April 2017 10:24
by papoo
thanks to

Re: Python Plugin Beta for Synology

Posted: Monday 01 May 2017 12:29
by Gl0ox
Hi guys,

I have Domoticz installed on my Synology DS3615xs with DSM 6.0.2-8451 from http://www.jadahl.com/domoticz_beta/
I am trying to install my Broadlink RM pro following http://www.domoticz.com/wiki/Plugins/BroadlinkRM2.html

I have installed python following Jumbotroll guidelines, however when I type python --version I get "Python 2.7.13".
After opkg install python3-pip, I run "pip3 install broadlink" (as per wiki) but I get:
Traceback (most recent call last):
File "/__init__.py", line 27, in <module>
File "/__init__.py", line 8, in <module>
File "/connectionpool.py", line 33, in <module>
ImportError: cannot import name 'CertificateError'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/opt/bin/pip3", line 7, in <module>
from pip import main
File "/__init__.py", line 21, in <module>
File "/__init__.py", line 62, in <module>
File "/__init__.py", line 29, in <module>
ModuleNotFoundError: No module named 'urllib3'
I tried to cp -R urllib3 from python2.7/site-packages into /volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages (where the SPK from Synology is installed I suppose) and also into Python3.6 and to use pip3.6 but I always have the same error.

So I tried pip install urllib3, went OK but issue remain, so I tried git clone git://github.com/shazow/urllib3.git then python setup.py install: same issue (I think it installs urllib3 into python 2.7).


I have no idea of what I'm doing :shock: ... please help !

Re: Python Plugin Beta for Synology

Posted: Tuesday 23 May 2017 7:29
by bertbigb
Hopefully not a stupid question, but what could be the benefit for me to switch over from my normal beta to this python beta?
Will it solve the problems with running python 3 scripts on a Synology where we very often have a Python 2.7 and a Python 3,x installed?
In that case this could really benefit me.
If I'm going to switch over to this version of the domoticz software what type of issues I might expect? This to know if it is worth to switch ;)

Hope someone can answer these (stupid) questions since I would like to have them answered before I make such a switch :?

Re: Python Plugin Beta for Synology

Posted: Friday 09 February 2018 13:36
by AllesVanZelf
Hello,
I have installed domoticz_88f6281-6.1_3.0.8841-7.spk. This is domoticz for dsm 6.1 including python support.
I installed: py3k-armv5-3.5.1-0105.spk from the synology website. This is the version for my DSM111.
community python has been removed before install of this one.
In the package center there is another package: Python modules. It is based on python 2.
Domoticz log show: PluginSystem: Started, Python version '3.5.1'.

But now I installed Buienradar plugin. But as soon as I add the hardware, domoticz crashes. I'm not able to restart it.
I removed the plugin from /usr/local/domoticz/var/plugins and after that I could restart domoticz. I removed the buienradar hardware after that.

I receive a message:
Multiple errors received in the last 5 minutes:

2018-02-09 11:35:16.191 Error: (Buienradar) failed to load 'plugin.py', Python Path used was ':/volume1/@appstore/py3k/usr/local/lib/python35.zip:/volume1/@appstore/py3k/usr/local/lib/python3.5/:/volume1/@appstore/py3k/usr/local/lib/python3.5/plat-linux:/volume1/@appstore/py3k/usr/local/lib/python3.5/lib-dynload'.
2018-02-09 11:35:16.192 Error: (Buienradar) Module Import failed, exception: 'ImportError'
2018-02-09 11:35:16.192 Error: (Buienradar) Module Import failed: ' Name: plugin'
2018-02-09 11:35:16.192 Error: (Buienradar) Error Line details not available.

and:
2018-02-09 11:36:30.340 Error: Buienradar hardware (11) thread seems to have ended unexpectedly
But I'm not sure if these messages are written after I removed the plugin.

Do you know what the problem is here?

edit: I tried to install another python plugin. sonos. After adding the hardware, domoticz crashes. not able to launch domoticz again (browser cache refresh failed - offline), till I remove the plugins from the /plugins folder. So I assume it is a python related problem in my synology.

Edit: Problem solved. When I install:
http://www.jadahl.com/domoticz_beta_6.1 ... 8875-7.spk
python plugins are okay and function normally. Till now ;)

Re: Python Plugin Beta for Synology

Posted: Monday 23 September 2019 20:01
by jaaap
Gl0ox wrote: Monday 01 May 2017 12:29 Hi guys,

I have Domoticz installed on my Synology DS3615xs with DSM 6.0.2-8451 from http://www.jadahl.com/domoticz_beta/
I am trying to install my Broadlink RM pro following http://www.domoticz.com/wiki/Plugins/BroadlinkRM2.html

I have installed python following Jumbotroll guidelines, however when I type python --version I get "Python 2.7.13".
After opkg install python3-pip, I run "pip3 install broadlink" (as per wiki) but I get:
Traceback (most recent call last):
File "/__init__.py", line 27, in <module>
File "/__init__.py", line 8, in <module>
File "/connectionpool.py", line 33, in <module>
ImportError: cannot import name 'CertificateError'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/opt/bin/pip3", line 7, in <module>
from pip import main
File "/__init__.py", line 21, in <module>
File "/__init__.py", line 62, in <module>
File "/__init__.py", line 29, in <module>
ModuleNotFoundError: No module named 'urllib3'
I tried to cp -R urllib3 from python2.7/site-packages into /volume1/@appstore/py3k/usr/local/lib/python3.5/site-packages (where the SPK from Synology is installed I suppose) and also into Python3.6 and to use pip3.6 but I always have the same error.

So I tried pip install urllib3, went OK but issue remain, so I tried git clone git://github.com/shazow/urllib3.git then python setup.py install: same issue (I think it installs urllib3 into python 2.7).


I have no idea of what I'm doing :shock: ... please help !
Were you ever able to make the broadlink plugin work on a domoticz-synology install? i'm facing the same issues as you did and I was wondering if you could point me in the right direction in order to get it working? Thanks in advance!