Closed markruys closed 3 years ago
Hi Mark, I just took a quick look... and will investigate later more in detail. I installed your version already on a Domoticz test version. However when renaming a device (I changed the Temp/Hum), an error shows up:
2020-11-07 10:48:31.550 Error: (TestNest) Device creation failed, Hardware/Unit combination (2:8) already exists in Domoticz.
Hi Mark, I just took a quick look... and will investigate later more in detail. I installed your version already on a Domoticz test version. However when renaming a device (I changed the Temp/Hum), an error shows up:
2020-11-07 10:48:31.550 Error: (TestNest) Device creation failed, Hardware/Unit combination (2:8) already exists in Domoticz.
Hi Mark, sorry, just saw that Domoticz was not restarted when having updated the plugin.py. Renaming works fine... However I saw that new devices are created at the startup meaning that all historical data is lost? Wouldn't it be possible to re-use the same units by default if they already exist?
However I saw that new devices are created at the startup meaning that all historical data is lost? Wouldn't it be possible to re-use the same units by default if they already exist?
That's doable. Basically it means populating the description field with the name when description is empty (or missing the [...] tag).
I've just committed a repair for a fix which wasn't working properly.
However I saw that new devices are created at the startup meaning that all historical data is lost? Wouldn't it be possible to re-use the same units by default if they already exist?
I've just commited a change to convert the legacy mapping in the name field to the description field. In your case, please remove the newly created devices first (if you did not do this already).
Seems to work... Just one error... Seems you changed the name "Eco mode" to "Eco Mode", this one is still recreated. Could you make the (small) change to avoid this one also? And some recommendations before I start merging:
pass
)Thanks for your contribution Mark. Let me know if the above if done (or if you wouldn't do it) before I merge...
Sure, I've implemented the changes you suggested. Thanks, Mark
Guys, thanks for the good work. Maybe a noob question, but if I try to pull the new version, it says "error: Your local changes to the following files would be overwritten by merge: plugin.py" Is there way to update the new version without loosing my current devices/eg historical data in Domoticz? Many thanks!
Mark contributed and made it happen that the historical information is not lost when updating the plugin. And I confirm that it does. So if you update from a previous version to this latest version, the data will be kept.
Okay, this got a bit out of hand. Yes, I did implement a work around for #6. But actually I completely rewrote the Python scripts. So @FilipDem, you might not like this and refuse the PR.
Hopefully I did not introduce too many bugs, but I did fix a few:
Also: