2023.2: ESPHome deprecated API password: how to update to encryption key

How many times should we expect to “reconfigure” ESPHome devices? Since updating the API keys two days ago, the same devices have generated notifications three and four times. :frowning:

One. I know it’s not helpful, but my eleven devices haven’t had any problems since I updated. What’s your setup?

Sorry to say I had problems with my ESPHOME telling me no key, that is solved, but aceindy I have not that menu you show with “show API key” do you run a different esphome or???Schermafbeelding 2023-02-03 135728

The longer I look at ACEINDY’s esphome the more I think wow, do I run an ancient version or so, it looks so dated in my setup, no yaml, no rename???

It seems for now in releases there is s screen with the esphome version displayed and it says 2022-12-8 or so I am with 2022-3-1 or so, can someone tell me how that is possible seen the fact that auto update is switched on in my esphome configuration that i run an ancient version, and not able to get a newer one, I know is off topic here but, help is appreciated. I got this esphome from the add-on store!

When ESPHome shifted from an “add-on” to an actual HA core integration, there was no automatic update that shifted you off the add-on and over to the core version. I found out the hard way several weeks ago. The solution (then) was to remove the add-on (which was possible) and add the core integration.

My setup is:

Debian 11 Bullseye on an Intel NUC i3
Home Assistant Supervised running in Docker
Home Assistant 2023.2.0 
Supervisor 2023.01.1 
Frontend 20230201.0 - latest 

And looking in the logs, I believe I’ve found my answer. Apparently, ESPHome and HA have cached a bunch of MAC addresses:

Logger: homeassistant.components.update
Source: helpers/entity_platform.py:540
Integration: Update (documentation, issues)
First occurred: February 2, 2023 at 7:32:19 AM (558 occurrences)
Last logged: 8:09:49 AM

Platform esphome does not generate unique IDs. ID D8:F1:5B:10:2B:6D already exists - ignoring update.dryer_firmware
Platform esphome does not generate unique IDs. ID 48:3F:DA:75:43:47 already exists - ignoring update.washer_firmware
Platform esphome does not generate unique IDs. ID EC:FA:BC:40:61:7D already exists - ignoring update.frontyard_lights_firmware
Platform esphome does not generate unique IDs. ID E8:DB:84:99:5C:71 already exists - ignoring update.daylight_sensor_firmware
Platform esphome does not generate unique IDs. ID BC:FF:4D:F9:5D:F1 already exists - ignoring update.computer_rack_fans_firmware

also on a raspi 4, it is not a docker or anything, and deleting is pretty scary for I have so many esphome nodes, my whole setup will falter. And how to get the core version running??

I was getting this a lot with one of my devices too. I had to remove it from the Core integration and re-add it to make it stop.

1 Like

Lost 2 of my sonoff basics updating these. Other items update OK.

Don’t want to do my last 2 as they are my most important.

Anyone successfully updated a sonoff basic as a switch with new encrypted API ?

Also, I have 1 esphome device that’s not in the esphome left side but in the integration that needs updating. Is there any way ?

Thanks in advance

Martyn

The only downside when you use HA secrets and keep your ESP secrets in HA secrets, you can’t edit it from the UI in ESPHome.

I use a mix, I include the HA secrets file as you do in the beginning and then still configure my ESP secrets there. That way, I can edit the ESP secrets from the UI and still access your HA secrets in the ESP yaml files.

You know you don’t have to change to encyption key. “If its working, don’t fix it” is an option.

yeah, i have 2 of them, updated without any issue…

I think that is right and am using the add on. I just replaced the password by the key, saved, installed and that did it (compiled, uploaded, restarted and works). Was a bit confused as it still says something about password in the log. The warning I had in my settings menu has disappeared so I think I’m ok now. .

Thank you for startig this thread.

Maybe i did read over it, but why is this change needed, like what is the advantage of making people switch to that API key and drop usage of uid/pwd?

My main ‘problem’ is i don’t flash ESPhome frequently enough, so i have to again find out how to do that for my devices (‘All you need to do is write YAML configuration files’) and hope everything stays working (seeing others having problems with size and all). And hope i don’t forget devices we for instance only use during christmas so in dec i have to again find out how to solve it.

It is not compulsory to change to encryption.

Repair messages in the dashboard like 5 devices reporting “API password deprecated” did give me that idea. What is the alternative? Since i assume i will keep seeing those repair messages if i do nothing. Can i just remove the password-section in configuration-yaml api: feels a bit strange?

(also, “Remove the API password and add an encryption key to your ESPHome device to resolve this issue.” as advice doesn’t give me the idea i should ignore)

I don’t see anything saying password will be removed, so you can just click the ignore button for now.

Same here it looks kinda ugly all those repair messages. Is why I tried to fix them and run in trouble with the encryption key, the tip look in the esphome dashboard well did not work for me for my esphome even though on auto update seems terribly ancient.
And I would like to use the core version as said here, but no clue how to get that running on a raspi 5, not found anything about it either in the forum, might have missed that.
So howto go about deleting the add on esphome and reinstall esphome core on a raspi 4 without losing all my nodes, yaml and settings.

My problem is i can’t find the yaml files for/of the devices currently running esphome and now reporting they use passwords which are deprecated. Those devices now do not show in my esphome panel. So if i have to flash a new firmware i have to find out how to get those devices show up on the ESPhome panel and flash them…

Yes is what I had to do too, it worked but was labor intensive. But I had them in the ESPhome add on page.
You can find your yaml files in config/esphome directory if that helps.

Ty. Over the years i have moved and reinstalled my HA config a couple of times, in the times before HA had easy backups, and seems those yaml files have gone lost. Wondering how much time people will have to spend to get this working again and still don’t know why pwd’s are deprecated.