diff --git a/homeassistant/components/screenlogic/sensor.py b/homeassistant/components/screenlogic/sensor.py index e2234586625..7b3c9b0c1f8 100644 --- a/homeassistant/components/screenlogic/sensor.py +++ b/homeassistant/components/screenlogic/sensor.py @@ -6,7 +6,11 @@ from screenlogicpy.const import ( EQUIPMENT, ) -from homeassistant.components.sensor import SensorDeviceClass, SensorEntity +from homeassistant.components.sensor import ( + SensorDeviceClass, + SensorEntity, + SensorStateClass, +) from homeassistant.config_entries import ConfigEntry from homeassistant.core import HomeAssistant from homeassistant.helpers.entity_platform import AddEntitiesCallback @@ -122,6 +126,13 @@ class ScreenLogicSensor(ScreenlogicEntity, SensorEntity): device_type = self.sensor.get("device_type") return SL_DEVICE_TYPE_TO_HA_DEVICE_CLASS.get(device_type) + @property + def state_class(self): + """Return the state class of the sensor.""" + if self._data_key == "scg_super_chlor_timer": + return None + return SensorStateClass.MEASUREMENT + @property def native_value(self): """State of the sensor."""