Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Seeing a load of exceptions in the logs such as "could not convert string to float" #97

Open
oleg-d opened this issue Nov 8, 2023 · 2 comments

Comments

@oleg-d
Copy link

oleg-d commented Nov 8, 2023

The add-on seems to be working great otherwise, just that I am seeing a bunch of exceptions in the logs.

ps_type_name ValueError: could not convert string to float: 'Residential PV'
ps_location ValueError: could not convert string to float: 'Finland'
ps_holder ValueError: invalid literal for int() with base 10: 'B2290923829'
ps_short_name ValueError: invalid literal for int() with base 10: 'B2290923829'
ps_name ValueError: could not convert string to float: 'Finland'
timezone ValueError: invalid literal for int() with base 10: 'GMT+2'

For example here's the full stack trace for the timezone from the log:

2023-11-08 08:08:15.968 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised when updating state of sensor.gosungrow_getpsdetail_5182053_timezone, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5182053-timezone/state' with payload: b'{"value":"GMT+2"}'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 616, in state
    numerical_value = int(value)
                      ^^^^^^^^^^
ValueError: invalid literal for int() with base 10: 'GMT+2'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 619, in state
    numerical_value = float(value)
                      ^^^^^^^^^^^^
ValueError: could not convert string to float: 'GMT+2'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 305, in process_write_state_requests
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 743, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 843, in _async_write_ha_state
    state, attr = self._async_generate_attributes()
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 784, in _async_generate_attributes
    state = self._stringify_state(available)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 749, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 623, in state
    raise ValueError(
ValueError: Sensor sensor.gosungrow_getpsdetail_5182053_timezone has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'GMT+2' (<class 'str'>)

@GitPat2
Copy link

GitPat2 commented May 25, 2024

same here, did you find a solution?

@jsanchezdelvillar
Copy link

Same here. When I start the integration I get many warnings and one error. I have an SG0.4RS inverter, the comunication module and I have pending the installation of the general meter:

2025-01-17 12:17:27.746 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_safe_start_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.765 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_9 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.796 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_0 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.804 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_7 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.810 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_5 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.831 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_9 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.875 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_11 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.930 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_data_last_update_time (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.945 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_1 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:27.995 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_record_create_time (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.057 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_zfzy_map (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.102 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_6 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.111 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_8 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.132 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_expect_install_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.144 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_4 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.171 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_3 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.197 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_design_capacity_battery (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.240 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_11 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.266 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_2 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.273 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_4 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.280 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_install_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.330 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_5 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.390 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_8 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.424 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_7 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.441 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_1 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.488 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_10 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.521 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_2 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.528 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_build_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.544 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_5694969_zfzy_map (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.551 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_3 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.557 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_10 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.583 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_plan_energy_0 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.595 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_actual_energy_6 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.628 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_5694969_1_1_2_p1 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.703 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_total_capacity (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'total' which is impossible considering device class ('power') it is using; expected None or one of 'measurement'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.728 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_devices_5694969_p83022 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.771 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_safe_start_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.905 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_expect_install_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.964 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_record_create_time (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:28.998 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_build_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:29.247 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_p83022 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('energy') it is using; expected None or one of 'total_increasing', 'total'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:29.394 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_devices_5694969_total_capacity (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'total' which is impossible considering device class ('power') it is using; expected None or one of 'measurement'; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:29.467 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_install_date (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using state class 'measurement' which is impossible considering device class ('timestamp') it is using; expected None; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:30.781 ERROR (MainThread) [homeassistant.components.mqtt.select] Invalid option for select.gosungrow_option_mqtt_loglevel: 'info' (valid options: ['Enabled', 'Disabled'])
2025-01-17 12:17:30.829 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_5694969_p83013 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Wh/㎡' which is not a valid unit for the device class ('irradiance') it is using; expected one of ['BTU/(h⋅ft²)', 'W/m²']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:30.959 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_5694969_p83202 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'kWp' which is not a valid unit for the device class ('power') it is using; expected one of ['TW', 'MW', 'W', 'GW', 'kW']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:30.976 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_p83202 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'kWp' which is not a valid unit for the device class ('power') it is using; expected one of ['TW', 'MW', 'W', 'GW', 'kW']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22

And then I get several errors and warnings when it tries to populate the sensors, these ones are repeated every time the data refreshes:

2025-01-17 12:17:31.005 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpsdetail_5694969_ps_location, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5694969-ps_location/state' with payload: b'{"value":"Street, street no, Zipcode City, Province, Espa\xc3\xb1a"}'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 640, in state
    numerical_value = float(value)  # type:ignore[arg-type]
ValueError: could not convert string to float: 'Street, street no, Zipcode City, Province, España'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/mqtt/models.py", line 366, in process_write_state_requests
    entity.async_write_ha_state()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1023, in async_write_ha_state
    self._async_write_ha_state()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1148, in _async_write_ha_state
    self.__async_calculate_state()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1085, in __async_calculate_state
    state = self._stringify_state(available)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1029, in _stringify_state
    if (state := self.state) is None:
                 ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 642, in state
    raise ValueError(
    ...<5 lines>...
    ) from err
ValueError: Sensor sensor.gosungrow_getpsdetail_5694969_ps_location has device class 'None', state class 'measurement' unit 'None' and suggested precision 'None' thus indicating it has a numeric value; however, it has the non-numeric value: 'Street, street no, Zipcode City, Province, España' (<class 'str'>)

(I remove several lines from now on, they were similar to the previous error)

2025-01-17 12:17:31.038 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_p83012 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'W/㎡' which is not a valid unit for the device class ('irradiance') it is using; expected one of ['BTU/(h⋅ft²)', 'W/m²']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:31.055 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpsdetail_5694969_ps_type_name, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5694969-ps_type_name/state' with payload: b'{"value":"Residential PV"}'
2025-01-17 12:17:31.074 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpsdetail_5694969_timezone, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5694969-timezone/state' with payload: b'{"value":"GMT+1"}'
2025-01-17 12:17:31.086 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_p83013 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'Wh/㎡' which is not a valid unit for the device class ('irradiance') it is using; expected one of ['BTU/(h⋅ft²)', 'W/m²']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:31.101 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpsdetail_5694969_design_capacity (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'kWp' which is not a valid unit for the device class ('power') it is using; expected one of ['TW', 'MW', 'W', 'GW', 'kW']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:31.164 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpsdetail_5694969_ps_name, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5694969-ps_name/state' with payload: b'{"value":"IDXXXX - MY SHORT NAME - STREET"}'
2025-01-17 12:17:31.191 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpsdetail_5694969_ps_short_name, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5694969-ps_short_name/state' with payload: b'{"value":"street number and town"}'
2025-01-17 12:17:31.202 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_5694969_p83012 (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'W/㎡' which is not a valid unit for the device class ('irradiance') it is using; expected one of ['BTU/(h⋅ft²)', 'W/m²']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:31.228 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpsdetail_5694969_ps_holder, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsDetail-5694969-ps_holder/state' with payload: b'{"value":"username"}'
2025-01-17 12:17:31.346 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_getpslist_devices_5694969_total_capacity (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'kWp' which is not a valid unit for the device class ('power') it is using; expected one of ['TW', 'MW', 'W', 'GW', 'kW']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:31.387 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpslist_devices_5694969_ps_short_name, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsList-devices-5694969-ps_short_name/state' with payload: b'{"value":"text with my address"}'
2025-01-17 12:17:31.413 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpslist_devices_5694969_ps_holder, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsList-devices-5694969-ps_holder/state' with payload: b'{"value":"shortname"}'
2025-01-17 12:17:31.534 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpslist_devices_5694969_ps_timezone, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsList-devices-5694969-ps_timezone/state' with payload: b'{"value":"GMT+1"}'
2025-01-17 12:17:31.605 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpslist_devices_5694969_ps_name, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsList-devices-5694969-ps_name/state' with payload: b'{"value":"ID name and address"}'
2025-01-17 12:17:31.728 WARNING (MainThread) [homeassistant.components.sensor] Entity sensor.gosungrow_virtual_devices_5694969_total_capacity (<class 'homeassistant.components.mqtt.sensor.MqttSensor'>) is using native unit of measurement 'kWp' which is not a valid unit for the device class ('power') it is using; expected one of ['TW', 'MW', 'W', 'GW', 'kW']; Please update your configuration if your entity is manually configured, otherwise create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue+label%3A%22integration%3A+mqtt%22
2025-01-17 12:17:31.746 ERROR (MainThread) [homeassistant.components.mqtt.models] Exception raised while updating state of sensor.gosungrow_getpslist_devices_5694969_location, topic: 'homeassistant/sensor/GoSungrow/GoSungrow-getPsList-devices-5694969-location/state' with payload: b'{"value":"full address"}'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants