adaptive-lighting
adaptive-lighting copied to clipboard
Unable to remove old/removed light from AL
If you remove a light entity from HA that was previously a part of Adaptive Lighting group, you can't remove it from the group, nor can you do any changes to the group (a "device" in HA implementation). Any change to the the group leads to User input malformed: light.[MISSING_ENTITY] is not a valid option for dictionary value @ data['lights']
. You then have to delete the AL group/device and set it up again without the missing light entity.
Same, subscribing
Yep, been a thing for a while I've noticed.
Same here, I have repaired my Zigbee lights and renamed entities and now I can't remove the old ones
+1
To workaround the issue I joined a spare light to the group with the old entity_id and removed it from the configuration. That saved me a lot of tweaking to the new configuration.
Most friendly solution (IMHO) would be to populate the dropdown with all entries already in the configuration regardless of them being present. Optionally they could be highlighted in red or something to attract attention.
If you navigate to the integrations page, there is an "Adaptive Lighting" integration where it will list all groups. You can select the old ones and delete it from there.
If you navigate to the integrations page, there is an "Adaptive Lighting" integration where it will list all groups. You can select the old ones and delete it from there.
The configuration page for the doesn't list the old groups if the entity is gone from HA, that's the crux of this issue. You can't save the configuration if an entity is no longer valid, but you can't remove the entity from the configuration because it doesn't show up to be unchecked.
I left the following comment in #287 (since it seems to have received more attention): This is the same as https://github.com/basnijholt/adaptive-lighting/issues/278 (which gives a much better description), https://github.com/basnijholt/adaptive-lighting/issues/236, https://github.com/basnijholt/adaptive-lighting/issues/220 and seems to have started with 2021.11's dropdown list (see https://github.com/basnijholt/adaptive-lighting/issues/213), which is addressed in https://github.com/home-assistant/frontend/issues/10608 - unfortunately without any obvious reaction for almost one year. At least https://github.com/home-assistant/frontend/issues/10608#issuecomment-1114340713 pointed me to editing /config/.storage/core.config_entries.
I've posted a PR to fix this issue.
https://github.com/basnijholt/adaptive-lighting/pull/350
Closed by #350 thanks to @danaues :tada: