bbqkees / ems-esp-domoticz-plugin

Domoticz plugin for the EMS Wi-Fi Gateway with Proddy's EMS-ESP firmware
MIT License
7 stars 8 forks source link

With domoticz 2020.1, device list is empty #13

Closed jefft4 closed 3 years ago

jefft4 commented 4 years ago

Since upgrading domoticz to 2020.1, I have had a problem with this plugin. at first, my EMS devices weren't updating. I removed the plugin, restarted dz, re-installed the plugin from git, restarted dz. Now I can add the hardware and see the EMS devices; however, as soon as I make any of those EMS devices active in domoticz, the domoticz UI devices list becomes completely empty! This error comes up in the dz log when trying to refresh the devices page: Error: WebServer PO exception occurred : 'stoull'

Also, the ems plugin seems to be logging to domoticz.log quite heavily and not usefully - e.g.: 2020-04-01 12:04:36.096 (Boiler EMS) onMessage called with: PUBLISH 2020-04-01 12:04:36.101 (Boiler EMS) onMessage called with: PUBLISH 2020-04-01 12:04:36.106 (Boiler EMS) onMessage called with: PUBLISH 2020-04-01 12:04:36.409 (Boiler EMS) onMessage called with: PINGRESP 2020-04-01 12:04:36.439 OpenZWave: Value_Added: Node: 12 (0x0c), CommandClass: METER, Label: Instance 1: Electric - kWh, Instance: 1, Index: 0 2020-04-01 12:04:36.439 OpenZWave: Value_Added: Node: 12 (0x0c), CommandClass: METER, Label: Instance 1: Electric - W, Instance: 1, Index: 2 2020-04-01 12:04:36.439 OpenZWave: Value_Added: Node: 12 (0x0c), CommandClass: METER, Label: Instance 1: Exporting, Instance: 1, Index: 256 2020-04-01 12:04:36.460 (Boiler EMS) onMessage called with: PUBLISH 2020-04-01 12:04:36.466 (Boiler EMS) onMessage called with: PUBLISH 2020-04-01 12:04:36.471 (Boiler EMS) onMessage called with: PUBLISH 2020-04-01 12:04:36.477 OpenZWave: Value_Added: Node: 12 (0x0c), CommandClass: METER, Label: Instance 2: Electric - kWh, Instance: 2, Index: 0 2020-04-01 12:04:36.477 OpenZWave: Value_Added: Node: 12 (0x0c), CommandClass: METER, Label: Instance 2: Electric - W, Instance: 2, Index: 2

bbqkees commented 4 years ago

Did you remove the cache in the browser after updating to 2020.1?

jefft4 commented 4 years ago

Yes. The situation has moved on a bit; I've been able to replicate the UI error after removing the plug-in.  It feels more like residual corruption caused by a problem with the plug-in than just the presence of the EMS devices.  I've noticed that some of the EMS devices were not fully removed from tables in the database; waiting on the domoticz developers to confirm that's a problem. Shall I update you later?

On Wed, Apr 1, 2020 at 6:26 PM +0100, "Kees" notifications@github.com wrote:

Did you remove the cache in the browser after updating to 2020.1?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

jefft4 commented 4 years ago

Hi Kees,

So, it appears that when I updated the plugin, the git command cloned it into a differently-named directory and having two copies of the "same" plugin confused either domoticz, the plugin or both., causing the initial UI problem. I noticed that issue because the config attributes on the hardware page were duplicated. When I removed the plugin to try to resolve the first problem, an omission in domoticz's code meant that some items (data push) related to the plugin's devices were not removed. That in turn caused the service to crash when anything tried to add devices.

Not sure that there's anything that can be done here with the plugin in relation to the first problem, though perhaps a warning to check folder names if updating could help? I should have spotted that folder was different from the already-installed one and moved the files across, but I missed it. D'oh!

FYI, domoticz forum thread here: https://www.domoticz.com/forum/viewtopic.php?f=6&t=31983&p=241917#p241917

bbqkees commented 4 years ago

Ok. At least its solved now. Did you use git pull in the right directory?

jefft4 commented 4 years ago

For some reason, the pull failed,so I did a full clone; maybe doing that without removing the old files first was part of the problem. As you say, at least it’s solved now!

Thanks 😊

From: Kees notifications@github.com Sent: 03 April 2020 07:59 To: bbqkees/ems-esp-domoticz-plugin ems-esp-domoticz-plugin@noreply.github.com Cc: jefft4 jeff@jcrt.co.uk; Author author@noreply.github.com Subject: Re: [bbqkees/ems-esp-domoticz-plugin] With domoticz 2020.1, device list is empty (#13)

Ok. At least its solved now. Did you use git pull in the right directory?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/bbqkees/ems-esp-domoticz-plugin/issues/13#issuecomment-608265259 , or unsubscribe https://github.com/notifications/unsubscribe-auth/ADMXUUIGEMVPERBEM6BX553RKWCMTANCNFSM4LYZBGJQ . https://github.com/notifications/beacon/ADMXUUK5JIIBFP7NQSZPSLLRKWCMTA5CNFSM4LYZBGJ2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOERAWIKY.gif