Logger: homeassistant.components.sensor
Source: components/sensor/__init__.py:597
Integration: Sensor (documentation, issues)
First occurred: 09:29:44 (1 occurrences)
Last logged: 09:29:44
Sensor sensor.duco_status_laatst_verstuurd has device class None, state class measurement and unit Afzuiging thus indicating it has a numeric value; however, it has the non-numeric value: Automatische (<class 'str'>); Please update your configuration if your entity is manually configured, otherwise report it to the custom integration author.
I’m getting this exact error as well. Mine also works fine but I try to go through my errors and correct them, but there’s no option for my template sensor to indicate a string value instead of pre-determined measurements.
Logger: homeassistant.util.logging
Source: util/logging.py:154
First occurred: 11:15:30 (1 occurrences)
Last logged: 11:15:30
Exception in handle_discovery_update when dispatching 'nodered_discovery_updated_nodered-c6b350c5.b8b3c-bf72bbcf.c428': ({'state': 'Automatische', 'attributes': {}, 'type': 'nodered/discovery', 'server_id': 'c6b350c5.b8b3c', 'node_id': 'bf72bbcf.c428', 'config': {'name': 'Duco Status Laatst Verstuurd', 'icon': 'mdi:fan', 'unit_of_measurement': 'Afzuiging', 'state_class': 'measurement'}, 'component': 'sensor', 'id': 23}, <homeassistant.components.websocket_api.connection.ActiveConnection object at 0x7f58e70c76d0>) Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 581, in state numerical_value = float(value) # type:ignore[arg-type] ValueError: could not convert string to float: 'Automatische' The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/config/custom_components/nodered/__init__.py", line 189, in handle_discovery_update self.async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 585, in async_write_ha_state self._async_write_ha_state() File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 649, in _async_write_ha_state state = self._stringify_state(available) File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 591, in _stringify_state if (state := self.state) is None: File "/usr/src/homeassistant/homeassistant/components/sensor/__init__.py", line 583, in state raise ValueError( ValueError: Sensor sensor.duco_status_laatst_verstuurd has device class None, state class measurement unit Afzuiging and suggested precision None thus indicating it has a numeric value; however, it has the non-numeric value: Automatische (<class 'str'>)
Remove the unit of measurement. Like the error message says, your use of a unit_of_measurement implies that the sensor should be a number, but then your state is Automatische which is not a number.