rcasula / kostalpiko-homeassistant

19 stars 15 forks source link

No entities loaded anymore #30

Open tagevm opened 4 months ago

tagevm commented 4 months ago

Log says it all:

2024-02-25 12:52:52.264 WARNING (MainThread) [homeassistant.const] POWER_WATT was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfPower.WATT instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.271 WARNING (MainThread) [homeassistant.const] ENERGY_KILO_WATT_HOUR was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfEnergy.KILO_WATT_HOUR instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.278 WARNING (MainThread) [homeassistant.const] ELECTRIC_POTENTIAL_VOLT was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfElectricPotential.VOLT instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.284 WARNING (MainThread) [homeassistant.const] ELECTRIC_CURRENT_AMPERE was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfElectricCurrent.AMPERE instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.890 WARNING (MainThread) [homeassistant.const] DEVICE_CLASS_ENERGY was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorDeviceClass.ENERGY instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.900 WARNING (MainThread) [homeassistant.const] ENERGY_KILO_WATT_HOUR was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfEnergy.KILO_WATT_HOUR instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.909 WARNING (MainThread) [homeassistant.components.sensor] STATE_CLASS_MEASUREMENT was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorStateClass.MEASUREMENT instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.916 WARNING (MainThread) [homeassistant.components.sensor] STATE_CLASS_MEASUREMENT was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorStateClass.MEASUREMENT instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.922 WARNING (MainThread) [homeassistant.components.sensor] STATE_CLASS_TOTAL_INCREASING was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorStateClass.TOTAL_INCREASING instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:52.929 WARNING (MainThread) [homeassistant.components.sensor] STATE_CLASS_TOTAL_INCREASING was used from kostal, this is a deprecated constant which will be removed in HA Core 2025.1. Use SensorStateClass.TOTAL_INCREASING instead, please report it to the author of the 'kostal' custom integration 2024-02-25 12:52:53.576 ERROR (MainThread) [homeassistant.components.sensor] Error adding entities for domain sensor with platform kostal Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 533, in async_add_entities await asyncio.gather(tasks) File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 782, in _async_add_entity await entity.add_to_platform_finish() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1325, in add_to_platform_finish self.async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 989, in async_write_ha_state self._async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1110, in _async_write_ha_state state, attr, capabilities, shadowed_attr = self.async_calculate_state() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1049, in async_calculate_state attr.update(self.state_attributes or {}) ^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/sensor/init.py", line 453, in state_attributes raise ValueError( ValueError: Entity sensor.kostal_piko_daily_energy (<class 'custom_components.kostal.sensor.PikoSensor'>) with state_class measurement has set last_reset. Setting last_reset for entities with state_class other than 'total' is not supported. Please update your configuration if state_class is manually configured. 2024-02-25 12:52:53.585 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 533, in async_add_entities await asyncio.gather(tasks) File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 782, in _async_add_entity await entity.add_to_platform_finish() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1325, in add_to_platform_finish self.async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 989, in async_write_ha_state self._async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1110, in _async_write_ha_state state, attr, capabilities, shadowed_attr = self.async_calculate_state() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1049, in async_calculate_state attr.update(self.state_attributes or {}) ^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/sensor/init.py", line 453, in state_attributes raise ValueError( ValueError: Entity sensor.kostal_piko_daily_energy (<class 'custom_components.kostal.sensor.PikoSensor'>) with state_class measurement has set last_reset. Setting last_reset for entities with state_class other than 'total' is not supported. Please update your configuration if state_class is manually configured.

tagevm commented 4 months ago

I have fixed the issue locally, but I believe https://github.com/rcasula/kostalpiko-homeassistant/pull/29 will also fix the issue

jeroendw88 commented 4 months ago

hi, can you say how you have fixed it locally? Much appreciated!

mueller-esch commented 2 months ago

Hallo Leute, ich fände die Integration hervorragend, wenn sie funktionieren würde. Ich habe nach der Integration meinen Piko 8.3 aus dem Jahre 2008 (funktioniert tatsächlich noch) einrichten können. Leider werden auch dort keine Daten angezeigt Kostal1 home-assistant_kostal_2024-04-19T08-56-48.715Z.log Bei der LogDatei muss ich passen. Dazu bin ich einfach noch zu "green" Danke für ein Feedback