dolezsa / thermal_comfort

Thermal Comfort sensor for HA (absolute humidity, heat index, dew point, thermal perception)
Other
543 stars 106 forks source link

Error while setting up thermal_comfort platform for sensor on 2024.1.0.dev #350

Closed enkama closed 6 months ago

enkama commented 6 months ago

On dev version on homeassistant the custom component isnt starting anymore.

Here is the startup log.

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 360, in _async_setup_platform
    await asyncio.shield(task)
  File "/config/custom_components/thermal_comfort/sensor.py", line 435, in async_setup_entry
    entities: list[SensorThermalComfort] = [
                                           ^
  File "/config/custom_components/thermal_comfort/sensor.py", line 436, in <listcomp>
    SensorThermalComfort(
  File "/config/custom_components/thermal_comfort/sensor.py", line 480, in __init__
    self.entity_description.translation_key = sensor_type
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<string>", line 4, in __setattr__
dataclasses.FrozenInstanceError: cannot assign to field 'translation_key'
rautesamtr commented 6 months ago

Already fixed in master 45b06080f935ed5ea10f30474e02c2f8fcd163b3