From fe3c86cb55dfafa06839d9a97a466d0360f84f18 Mon Sep 17 00:00:00 2001 From: diegocjorge <58111081+diegocjorge@users.noreply.github.com> Date: Mon, 6 Jan 2025 11:23:19 -0300 Subject: [PATCH] Remove humidity sensor for V2 AC devices with humidity=0 The AC model CST_570004_WW-CST is a V2 device, but also lacks a humidity sensor and reports a value of 0. Since a fix was previously implemented for V1 devices, I have removed the exception for V2 devices. --- custom_components/smartthinq_sensors/wideq/devices/ac.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/custom_components/smartthinq_sensors/wideq/devices/ac.py b/custom_components/smartthinq_sensors/wideq/devices/ac.py index 8f3ad828..a6d3d567 100644 --- a/custom_components/smartthinq_sensors/wideq/devices/ac.py +++ b/custom_components/smartthinq_sensors/wideq/devices/ac.py @@ -1169,9 +1169,9 @@ def humidity(self): key = self._get_state_key(STATE_HUMIDITY) if (value := self.to_int_or_none(self.lookup_range(key))) is None: return None - # some V1 device return humidity with value = 0 + # some V1 and V2 devices return humidity with value = 0 # when humidity sensor is not available - if not self.is_info_v2 and value == 0: + if value == 0: return None if value >= 100: value = value / 10