You’re a genius!!! I’ll give that a crack and report back.
Hold on - this card currently only exists on my laptop…
I just pushed the code on a new home-assistant-polymer branch - feel free to test this if you like.
Unknown card type encountered geo-location-map
Sorry, please see above - this card is not yet in the released version…
No idea how to test that branch so just a matter of waiting I guess. (I’d be happy to test if I knew how to) The iFrame worked but on my iPad it did not like it. It shown on the map from the side panel though.
Good to see it’s coming though. Thanks.
Yeah, it is a bit of work to set up a dev environment, and I would not recommend testing this in your production system straight away.
I just opened a PR Extended map to support geo location entities by exxamalte · Pull Request #2337 · home-assistant/frontend · GitHub
So it seems to have been merged and I see it…
Small problem though. I’m using thomaslovens fold entity row with the group.all_geolocation_events
- type: entities
title: NSW Warnings & Events
show_header_toggle: false
entities:
- type: custom:fold-entity-row
open: true
head: group.all_geolocation_events
- type: map
show_header_toggle: false
geo_location_sources:
- nsw_rural_fire_service_feed
entities:
- zone.home
What is happening is an entity drops out but the group isn’t updated so the group still has it and then I get a yellow error here:
Seems if the alert/warning is not there it shouldn’t be leaving it in the group.
Good to see that the map is working for you.
At the time when the “Entity not available” message appears, could you please check which entries are actually left in the group group.all_geolocation_events
? In the dev tools you should be able to find that group and its entity_id
attribute is a list of all current entities in that group.
I just had a look at mine, and it still shows the entity id of a geolocation entity that was removed from HA 3 days ago.
So, it could be a bug in how the geo_location
component manages its group.
Yes I agree. It is still showing the entities in the group when they are no longer available. It seems to ‘fix’ the group when a new incident is added. I have 100 set as the radius so I generally don’t see 3 day old events!
OK, a quick look into the source code shows me that this type of “catch all” group is only updated when a new entity is added, but not when an entity is removed from HA. That correlates with your observation.
I’ll see if I can reproduce this behaviour in a unit test and then try to find a fix…
I tried running homeassistant.update_entity against the group in dev tools but no dice
Cheers! Thanks for that.
I wouldn’t expect this to fix the issue. That service makes the group to update its state (“on” or “off”), and it does that by going through all tracked entities, but it doesn’t check if they still exist.
@DavidFW1960:
Quick update on the issue with entities not being removed correctly. After a bit of discussions with other developers it turned out that now that the Lovelace UI is default, the need for default groups such as the one managed by the geolocation component would not be there anymore. Hence a decision was made to remove this default group. The preferred view (card) for geolocation entities is the map.
Unfortunately that means that the list view of geolocation entities cannot be generated anymore in the future.
Do you think that there is still a need for such a list view, now that the map view is working? Or, do you have any suggestions on how to improve the map view if there is something missing in there that you were hoping to get from the list view?
Thanks for responding.
Sometimes incidents are on top of each other and you can’t tap on one as it won’t zoom in enough. The group is still showing in dev-tools and I think the group still is needed otherwise how do you add entities to the map? (So it should update as entities are added/removed no?)
Just one other thing as well… This morning the group itself was empty and the group had disappeared altogether from Home Assistant (when I upgraded to 0.86.1 and HA restarted) so the whole geo_location was gone until there was an incident.
This then gave me a nasty red entity error in Lovelace… if the platform is loaded that group [group.all_geolocation_events] should always exist I think so that won’t happen…
That’s great.
As an alternative I was thinking about an entity card that supports the geolocation source parameter - similar to how the map card is configured.
It’s a good solution I think. Would be nice if it was in the core though as it could always break or otherwise become unavailable in the future.