Open nlfva1 opened 2 weeks ago
Hi, that is the same issue as #126. I don’t have a clue yet what is causing the error. What OS are you running on the RPI?
I'm running Raspbian GNU/Linux 10 (buster) Linux 5.10.103-v7l+
I've added dump.json as I guess that this wil be your next question😉 dump.json
I added the path of the tinytuya module to your script and found that it's actually still pointing to version 3.7, so looks like it's related to the python version. Although I have installed python 3.8.1.
Now trying to figure out how to fix this. so far not successful. Will try to update to python 3.8.5 instead.
Normally you can set the default python by running:
update-alternatives --config python
Unfortunately the command did not help.
Domoticz is still loading 3.7.3 and not libpython3.8.5. Looks like something with the pythonpath in Domoticz. I'll keep looking, but open for suggestions..
Error: Tuya cloud: (tinytuya) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Domoticz-TinyTUYA-Plugin/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/
Even tried installing 3.9.7, but did not help either. Still pointing to 3.7.
Did you try running it with sudo? Domoticz runs under the su (superuser) account.
Yes. Here is the result: sudo update-alternatives --config python There is only one alternative in link group python (providing /usr/bin/python): /usr/local/bin/python3.8 Nothing to configure.
Still showing python version 3.7.3 in Domoticz. Also tried it with an empty new domoticz database, but same result. I have no clue where it getting the 3.7.3 from.
That is strange, python3 -V give 3.8?
Yes. I will try a deinstall and reinstall of domoticz to see if that works.
And sudo python3 -V How did you insta?ll python 3.8?
Same result. Let me try the reinstall of domoticz first. Thanks so far.
Was the reinstall the fix?
No the re-install with a fresh domoticz.db still gave the same 3.7.3 versionin the domoticz log. Although sudo python --version and sudo python3 -- version both give version 3.8.1. Even tried a PYTHONPATH in domoticz.sh and point to 3.8.1, but is not picking up. Copied my backed up domoticz.db back to this new installation and after start up still pointing to 3.7.3.
I'm out of option other then a complete reinstall of raspbian and domoticz, but is not something I'm looking forward to. Will first by a new 32gb memory card, so that it's easier to go back if it isn't working. To be continued, but open for other idea's. Thanks so far.
I have Domoticz 2024.7 and Python 3.8.1 and installed the TinyTUYA plugin 2.0.4. I did all the steps in Tuya developer platform and can receive the data in my raspberry using "python -m tinytuya scan" see below, but it does not create the devices in Domoticz when activating the plugin.
In the domoticz log I get two messages:
Let me know if you need more info.