diff --git a/homeassistant/components/ecobee/climate.py b/homeassistant/components/ecobee/climate.py index ed1e95d648c8..5fffb22b9fae 100644 --- a/homeassistant/components/ecobee/climate.py +++ b/homeassistant/components/ecobee/climate.py @@ -4,8 +4,6 @@ import collections from typing import Any, override from homeassistant.components.climate import ( - ATTR_TARGET_TEMP_HIGH, - ATTR_TARGET_TEMP_LOW, FAN_AUTO, FAN_ON, PRESET_AWAY, @@ -14,11 +12,11 @@ from homeassistant.components.climate import ( PRESET_SLEEP, ClimateEntity, ClimateEntityFeature, + ClimateServiceArgument, HVACAction, HVACMode, ) from homeassistant.const import ( - ATTR_TEMPERATURE, PRECISION_HALVES, PRECISION_TENTHS, STATE_OFF, @@ -629,9 +627,9 @@ class Thermostat(ClimateEntity): @override def set_temperature(self, **kwargs: Any) -> None: """Set new target temperature.""" - low_temp = kwargs.get(ATTR_TARGET_TEMP_LOW) - high_temp = kwargs.get(ATTR_TARGET_TEMP_HIGH) - temp = kwargs.get(ATTR_TEMPERATURE) + low_temp = kwargs.get(ClimateServiceArgument.TARGET_TEMP_LOW) + high_temp = kwargs.get(ClimateServiceArgument.TARGET_TEMP_HIGH) + temp = kwargs.get(ClimateServiceArgument.TEMPERATURE) if self.hvac_mode == HVACMode.HEAT_COOL and ( low_temp is not None or high_temp is not None