I am using it, and it is working properly.
I have nothing against this way.
BTW, some people give human names for a furniture, carpets, not to mention cars. So, we can create a āpersonā entity for a lovely carpet with a virtual ādevice_trackerā which is always āhomeā, so warmingā¦
But I think that ālabelsā are much more than just a ālocationā - so it should be reflected in the menu.
I donāt see why you donāt get this.
the id is used as unique_id now, and is not comparable to the entity_id of an entity for example. (which is not tied to the entity_id. change the entity_id, the unique_id remains the same. we can not do that with the Floor/Area/Label without running into trouble with our templates)
I dont want anything to be a problem, just trying to explain the experience we now get when we have second thoughts about a Floor/Area/Label name (and want to use those in our templates)
As it stands, the only real solution is to create a new Floor/Area/Label, move what you had before to the new, and delete the old.
Is there a reason why my Home Assistant VM since an update to the latest version (2024.4.0) suddenly started to ask my DNS for all PTR (local network) records?
Blue color is Home Assistant and they consist mostly of PTR records.
What trouble?
of not being able to use the new/changed name in the templates, see 2024.4: Organize all the things! - #120 by Mariusthvdb
ā¦
label_name(label_id)
exactly like area and device.
Show me a template and Iāll show you what you should do.
precisely.
thats what I did in that linked post.
had a label originally names Alarm
, then reconsidered and renamed to Alarm spelers
.
the templates still required alarm
, and alarm_players
was not recognized.
dont need to repeat all of that post but that would be the bottom line:
once a name is chosen, it is used as id for that label ( and area/floor) for ever
my suggestion would be to decouple those, and have the templates follow the name, not the unique_id (which would need to be added to the architecture)
True , now i can dump/replace many of my āold type groupsā in config.yaml, with Labels ( I hope ) , Wired-Devices / Cameras etc.
Marius, you used slugify
, not label_id
or label_name
. Canāt help it if youāre using the wrong templates.
Understand that I havenāt assigned labels yet to entities, but if you have, this will show you what you can do.
no? I never used that in the templates.
just change one of the names of those labels, and see what happens with these templates
Hereās an example pulling the friendly label name
{{ labels() }}
{{ labels() | map('label_name') | list }}
{{ label_id('Great Room') }}
{{ label_areas(label_id('Great Room')) }}
yes I know that, but that is not my issue at allā¦
As I try to bring across, the issue arises when you change the name of an existing label
Thatās not the āgotchaā you think it is.
Again, treat it like an ID. If you want to use the friendly name, get the id with label_id
.
Thereās no issues if you use label_id
.
label_id()
might be closest to what we are used to see as unique_id on entities probably yes.
My main point however remains, and that is that we need to refer to that, and not to the name, which is way more humane friendly.
Besides that, it also is much easier to rememberā¦
I recall Frenck saying something like the above (need to find the link), and it had been discussed, not finalized yet. Hope it can be improved upon
You donāt need to refer to thatā¦ thatās what you arenāt understanding.
If you want to compare to the friendly name, map the label_ids that come from the functions to the label_names. Then do your comparisons to your friendly names or vise versa.
You can literally do that everywhere. Itās no different than using slugify.
After upgrading to 2024.4 I am seeing an error when I open the Map page:
Error loading the dashboard strategy:
Error: unknown strategy
Any idea what caused this?
I love the ālabelsā!!!
Would be great to get the option to add labels in every integration you create yourself. For example sensors, switches, etcā¦ also with automations. Only what to add:
label: name of the label or labels
label: "system, switches"
Do you mean āadd labels in yamlā?
better:
label: ['system','switches']
or
label:
- system
- switches