core: ESPHome devices Entities Unavailable after Updating to 2021.10

The problem

All the Entities of any ESPHome Device has stop updating and are now Unavailable. After updating ESPHome to 2021.10 HA has start to log an error in the logs and dose not update any data (related to ESPHome devices)

What is version of Home Assistant Core has the issue?

core-2021.10.6

What was the last working version of Home Assistant Core?

core-2021.10.6

What type of installation are you running?

Home Assistant OS

Integration causing the issue

ESPHome

Link to integration documentation on our website

https://www.home-assistant.io/integrations/esphome/

Example YAML snippet

esphome:
  name: NODENAME
  platform: ESP32
  board: nodemcu-32s

wifi:
  ssid: !secret NODENAME _SSID
  password: !secret PLACEHOLDER_PASS_WIFI

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "NODENAME Fallback Hotspot"
    password: "RANDOM_PASS"

captive_portal:

# Enable logging
logger:

# Enable Home Assistant API
api:
  password: !secret PLACEHOLDER_PASS
  encryption:
    key: !secret PLACEHOLDER_KEY

ota:
  password: !secret PLACEHOLDER_PASS_OTA


#BLE Sensor discovery 
esp32_ble_tracker:
  scan_parameters:
    active: false

Anything in the logs that might be useful for us?

Logger: homeassistant
Source: components/esphome/entry_data.py:146
First occurred: 03:33:01 (1 occurrences)
Last logged: 03:33:01

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/esphome/__init__.py", line 294, in complete_setup
    infos, services = await entry_data.async_load_from_store()
  File "/usr/src/homeassistant/homeassistant/components/esphome/entry_data.py", line 146, in async_load_from_store
    self.device_info = DeviceInfo.from_dict(restored.pop("device_info"))
KeyError: 'device_info'

Additional information

In one of the ESPHome devices i also enable the encryption option and HA asked me to reconfigured twice.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 19 (1 by maintainers)

Most upvoted comments

I updated 3 different HA instances to 2021.12.5 recently, and on two of them I’ve had a couple of ESPHome nodes go “unavailable” in HA even though they remain pingable and accessible via their web interface. The only thing that corrected the issue was to reload the integration in HA. I’ve never had to do this before upgrading.

You shouldn’t have to remove them. Just reload the integration.

Untitled