Closed ferni7 closed 3 years ago
Thanks @Ferni7 ! You are right, there was a breaking update to the pytuya library. It was changed to use __version__
instead of version
.
I have updated the tuyapower to version 0.0.20 and will be pushing the new module to PyPi. Please git pull
the latest version and try again.
jason@home$ docker run -e PLUGID='xxx' -e PLUGIP="x" -e PLUGKEY="xxx" tuyapower
TuyaPower (Tuya Power Stats) [0.0.20]
Device 03200160dc4f2216f984 at 10.0.1.187 key 0123456789abcdef protocol 3.1:
Switch On: True
Power (W): 54.700000
Current (mA): 477.000000
Voltage (V): 120.300000
Projected usage (kWh): Day: 1.312800 Week: 9.189600 Month: 39.821600
{ "datetime": "2020-07-22T03:20:11Z", "switch": "True", "power": "54.7", "current": "477.0", "voltage": "120.3" }
Thanks for the report!
Thanks Jason - will give it a go :)
Also FYI - in your readme.md in the docker example down the bottom you have 'PLUGINVERS' as a parameter, that one cost me an hour of so until I realized it was meant to be PLUGVER :)
Doh!! Sorry about that but thanks for sharing! It should be PLUGVERS
- I updated the readme.
All good - just tested latest and working great now :) Thanks!
Awesome! Thanks for the confirmation.
So trying to run this and I'm getting the below error. I can run the powermonitor version of this fine....