Invalid entity id encountered: light.. Format should be <domain>.<object_id>

I have hass.io on my raspberry pi, i tough this error was blocking my update to 0.85.1 but that with many retries has finally worked out. however i have now quite a lot of errors on my dashboard.

in my log i see the following error:
Error doing job: Task exception was never retrieved

Traceback (most recent call last): File “/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity.py”, line 310, in async_update_ha_state self.entity_id, state, attr, self.force_update, self._context) File “/usr/local/lib/python3.6/site-packages/homeassistant/core.py”, line 903, in async_set context) File “/usr/local/lib/python3.6/site-packages/homeassistant/core.py”, line 668, in init “Format should be <domain>.<object_id>”).format(entity_id)) homeassistant.exceptions.InvalidEntityFormatError: Invalid entity id encountered: light… Format should be <domain>.<object_id>

I had emoticons in my hue lights which i tought where the cause of this, so i’ve changed the names in the hue app without emoticons. just standard text.

How can i troubleshoot this?

I had this exact same error on a hue light after doing an update tonight and found your post.

I ended up tracking the problem down to the core.restore_state file.

I found the entity id it was complaining about and deleted that entire section from the file. This seemed to force it to rebuild that bit again when I restarted the docker container.

Unfortunately I’m no developer, so I really couldn’t tell you why it happened or if this was the most appropriate way to fix it. It worked for me though :slight_smile:

1 Like

Hey @mindabsence

thanks for sharing your experience and responding to my problem. I have the feeling that i’m a real newbie here so please stick with me.

How can i delete the mentioned file? I tried to navigate to it via SSH but the mentioned folder doesn’t exist in de root user folder structure. I’ve the Hass.io SSH server add on. Also via the IDE (cloud9) add on i cant seem to navigate to it remotely.

Can you share how you removed the file?

Unfortunately I only have very little familiarity with the Docker version of Home Assistant, and even at that, we’re only talking a couple of weeks familiarity. So in the Docker version, this file was in the /config/.storage/ folder, but that path may not necessarily be representative of where you’ll find it hass.io since Docker tends to group these types of folders and files all together into the persistent volume.

Disclosure that I’m not a dev or very familiar with the command line either. It was a night of trial and error for me to figure this out and hunt down the file after seeing some mentions in my docker logs and just starting to grep a variety of folders for where a specific string showed up.

Well, even with your great help @mindabsence i didnt find out how to delete the file. So as my home assistant install is still quite fresh, i did a reinstall. Still feels as a loss not knowing how i could have fixed this.

A well, everything is working as a charm again :slight_smile: