zwave-js / zwave-js-ui

Full featured Z-Wave Control Panel UI and MQTT gateway. Built using Nodejs, and Vue/Vuetify
https://zwave-js.github.io/zwave-js-ui
MIT License
988 stars 206 forks source link

After switching controllers, the node names and locations are attributed to the wrong devices #3817

Open AlCalzone opened 4 months ago

AlCalzone commented 4 months ago

grafik

I previously had another stick connected with 3 nodes, using different IDs 2, 3 and 4, which had these names and locations set. After switching sticks, the names and locations persist in the UI, but they belong to the wrong devices.

robertsLando commented 4 months ago

yeah this is expected, on init I load nodes.json and apply it to the existing devices, this is useful in case you restore your backup on a different controller to keep nodes names in sync. The alternative would be to store nodes along with the homeID. I accept suggestions here as this is not a very common use case and we should consider pro-cons of changing the actual behaviour

AlCalzone commented 4 months ago

I think the node names should be stored separately for each home ID. Or you could use the properties from the node instance to have the driver handle it?

robertsLando commented 4 months ago

Or you could use the properties from the node instance to have the driver handle it?

I actually pass down to the driver the name/location if I see them are different to the ones stored on nodes.json

That file exist for very old reasons as with OZW node name and location was not working everytime so I decided to keep them stored there. We could also decide to simply drop name/loc from that file as it is alsready stored on your json backup.

I also store home assistant custom devices on that file and that will remain

AlCalzone commented 4 months ago

In any case, nodes belonging to a different home ID are very likely not the same devices. Especially if the Node ID also changed.

github-actions[bot] commented 1 month ago

This issue is stale because it has been open 90 days with no activity. Remove the stale label or comment or this will be closed in 5 days. To ignore this issue entirely you can add the no-stale label

github-actions[bot] commented 1 month ago

This issue is now closed due to inactivity, you can of course reopen or reference this issue if you see fit.