diff --git a/custom_components/fusion_solar/fusion_solar/energy_sensor.py b/custom_components/fusion_solar/fusion_solar/energy_sensor.py index 0dbe8a1..6f0d3ec 100644 --- a/custom_components/fusion_solar/fusion_solar/energy_sensor.py +++ b/custom_components/fusion_solar/fusion_solar/energy_sensor.py @@ -65,7 +65,7 @@ def native_value(self) -> float: return realtime_power = self.coordinator.data[self._data_name][ATTR_REALTIME_POWER] - if math.isclose(realtime_power, 0, abs_tol = 0.001): + if math.isclose(float(realtime_power), 0, abs_tol = 0.001): _LOGGER.info(f'{self.entity_id}: not producing any power, so no energy update to prevent glitches.') return float(current_value)