davidrapan / ha-solarman

⚡ Solarman Stick Logger integration for 🏠 Home Assistant
MIT License
58 stars 16 forks source link

Measurement and device class mismatch in config file #152

Open Islanad opened 1 week ago

Islanad commented 1 week ago

The config file sofar_g3hyd.yaml causes 3 warning in the home assistant logs.

Logger: homeassistant.components.sensor Source: components/sensor/init.py:731 integration: Sensor (documentation, issues) First occurred: September 12, 2024 at 21:33:57 (2 occurrences) Last logged: September 12, 2024 at 21:33:57

Entity sensor.solarman_grid_frequency (<class 'custom_components.solarman.sensor.SolarmanSensor'>) is using native unit of measurement 'Hz' which is not a valid unit for the device class ('current') it is using; expected one of ['A', 'mA']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/davidrapan/ha-solarman/issues Entity sensor.solarman_frequency_output_eps (<class 'custom_components.solarman.sensor.SolarmanSensor'>) is using native unit of measurement 'Hz' which is not a valid unit for the device class ('current') it is using; expected one of ['A', 'mA']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/davidrapan/ha-solarman/issues

and

Logger: homeassistant.components.sensor Source: components/sensor/init.py:569 integration: Sensor (documentation, issues) First occurred: September 12, 2024 at 21:33:57 (1 occurrences) Last logged: September 12, 2024 at 21:33:57

Entity sensor.solarman_inverter_status (<class 'custom_components.solarman.sensor.SolarmanSensor'>) is using state class 'measurement' which is impossible considering device class ('enum') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/davidrapan/ha-solarman/issues

davidrapan commented 6 days ago

fix: sofar_g3hyd entities /w incorrect classes