From 11faf4adcbb0dc48d16e0c1b5916b8a7bc356f9c Mon Sep 17 00:00:00 2001 From: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Date: Sun, 24 Mar 2024 15:20:00 +0100 Subject: [PATCH] Replace if in range check (#114107) --- homeassistant/components/ecobee/climate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homeassistant/components/ecobee/climate.py b/homeassistant/components/ecobee/climate.py index 3f871dd20dd..0df8a42c566 100644 --- a/homeassistant/components/ecobee/climate.py +++ b/homeassistant/components/ecobee/climate.py @@ -717,7 +717,7 @@ class Thermostat(ClimateEntity): def set_humidity(self, humidity: int) -> None: """Set the humidity level.""" - if humidity not in range(101): + if not (0 <= humidity <= 100): raise ValueError( f"Invalid set_humidity value (must be in range 0-100): {humidity}" )