From e3381d949d4283d3e13169bce1da08295413ad18 Mon Sep 17 00:00:00 2001 From: snaky69 <108159253+snaky69@users.noreply.github.com> Date: Sun, 19 Feb 2023 11:28:56 -0500 Subject: [PATCH] SensorStateClass pour Energy sensors Fix pour issue #221 --- custom_components/hilo/sensor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom_components/hilo/sensor.py b/custom_components/hilo/sensor.py index c582873..e4ce692 100644 --- a/custom_components/hilo/sensor.py +++ b/custom_components/hilo/sensor.py @@ -237,7 +237,7 @@ class EnergySensor(IntegrationSensor): _attr_device_class = SensorDeviceClass.ENERGY _attr_native_unit_of_measurement = ENERGY_WATT_HOUR - _attr_state_class = SensorStateClass.MEASUREMENT + _attr_state_class = SensorStateClass.TOTAL_INCREASING _attr_icon = "mdi:lightning-bolt" def __init__(self, device):