Can't update devices since updating ESPHome to 2024.2.0

My small number of Athom Smart Plugs seem to be working OK - but as soon as v2024.2.0 was installed I am advised an update is available for each device, but the system throws an error if I actually try to update any of them.

For Example…

INFO ESPHome 2024.2.0
INFO Reading configuration /config/esphome/athom-smart-plug-v2-a7f9f0.yaml...
INFO Updating https://github.com/athom-tech/athom-configs.git@None
INFO Detected timezone 'Australia/Adelaide'
Failed config

sensor.cse7766: [source /data/packages/43f53298/athom-smart-plug-v2.yaml:86]
  platform: cse7766
  
  [update_interval] is an invalid option for [sensor.cse7766]. Please check the indentation.
  update_interval: 10s
  current: 
    name: Current
    filters: 
      - lambda: if (x < 0.060) return 0.0; else return x;
  voltage: 
    name: Voltage
  power: 
    name: Power
    id: power_sensor
    filters: 
      - lambda: if (x < 3.0) return 0.0; else return x;
  energy: 
    name: Energy
    id: energy
    unit_of_measurement: kWh
    filters: 
      - multiply: 0.001
    on_value: 
      then: 
        - lambda: |-
            static float previous_energy_value = 0.0;
            float current_energy_value = id(energy).state;
            id(total_energy) += current_energy_value - previous_energy_value;
            previous_energy_value = current_energy_value;

Everything is default in the settings. Wouldn’t have any idea how to change anything if I wanted to - just click the update button when requested.

Have I inadvertently broken something? The devices have been through about 3 update cycles previously so I know how to start one but just trust that HA will be doing the right thing with the update because I have no idea…

@pcal hello. This has been covered in two other threads

File “/esphome/esphome/yaml_util.py”, line 425, in _load_yaml_internal
return _load_yaml_internal_with_type(ESPHomeLoader, fname, f_handle)
61 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 447, in _load_yaml_internal_with_type
return loader.get_single_data() or OrderedDict()
24 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 51, in get_single_data
return self.construct_document(node)
29 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 55, in construct_document
data = self.construct_object(node)
27 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 100, in construct_object
data = constructor(self, node)
23 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 86, in wrapped
res = fn(loader, node)
16 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 156, in construct_yaml_map
value = self.construct_object(value_node)
33 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 100, in construct_object
data = constructor(self, node)
23 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 86, in wrapped
res = fn(loader, node)
16 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 255, in construct_secret
secrets = _load_yaml_internal(self._rel_path(SECRET_YAML))
48 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 425, in _load_yaml_internal
return _load_yaml_internal_with_type(ESPHomeLoader, fname, f_handle)
61 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 447, in _load_yaml_internal_with_type
return loader.get_single_data() or OrderedDict()
24 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 51, in get_single_data
return self.construct_document(node)
29 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 55, in construct_document
data = self.construct_object(node)
27 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 100, in construct_object
data = constructor(self, node)
23 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 86, in wrapped
res = fn(loader, node)
16 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 156, in construct_yaml_map
value = self.construct_object(value_node)
33 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 100, in construct_object
data = constructor(self, node)
23 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 86, in wrapped
res = fn(loader, node)
16 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 255, in construct_secret
secrets = _load_yaml_internal(self._rel_path(SECRET_YAML))
48 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 425, in _load_yaml_internal
return _load_yaml_internal_with_type(ESPHomeLoader, fname, f_handle)
61 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 447, in _load_yaml_internal_with_type
return loader.get_single_data() or OrderedDict()
24 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 51, in get_single_data
return self.construct_document(node)
29 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 55, in construct_document
data = self.construct_object(node)
27 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 100, in construct_object
data = constructor(self, node)
23 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 86, in wrapped
res = fn(loader, node)
16 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 155, in construct_yaml_map
key = self.construct_object(key_node)
31 Caret/chevron
File “/usr/local/lib/python3.11/dist-packages/yaml/constructor.py”, line 100, in construct_object
data = constructor(self, node)
23 Caret/chevron
File “/esphome/esphome/yaml_util.py”, line 96, in wrapped
res.from_node(node)
File “/esphome/esphome/yaml_util.py”, line 57, in from_node
self._esp_range = DocumentRange.from_marks(node.start_mark, node.end_mark)
56 Caret/chevron
File “/esphome/esphome/core/init.py”, line 403, in from_marks
DocumentLocation.from_mark(start_mark), DocumentLocation.from_mark(end_mark)
38 Caret/chevron
File “/esphome/esphome/core/init.py”, line 384, in from_mark
return cls(mark.name, mark.line, mark.column)
38 Caret/chevron
RecursionError: maximum recursion depth exceeded
2024-02-23 10:57:44,534 ERROR 500 GET /secret_keys (0.0.0.0) 109.07ms
2024-02-23 10:57:46,391 INFO 304 GET /devices (0.0.0.0) 1.63ms
2024-02-23 10:57:51,402 INFO 304 GET /devices (0.0.0.0) 2.56ms
2024-02-23 10:57:57,316 INFO 304 GET /devices (0.0.0.0) 1.48ms

1 Like