From a082ffca1dbc1a7509f0b034d422a189c8371559 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Sat, 24 Jun 2017 18:11:34 -0700 Subject: [PATCH] Fix MySensors climate (#8193) --- homeassistant/components/climate/mysensors.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/homeassistant/components/climate/mysensors.py b/homeassistant/components/climate/mysensors.py index 9fd6059acbe..82ed8a94e2b 100755 --- a/homeassistant/components/climate/mysensors.py +++ b/homeassistant/components/climate/mysensors.py @@ -67,7 +67,12 @@ class MySensorsHVAC(mysensors.MySensorsDeviceEntity, ClimateDevice): @property def current_temperature(self): """Return the current temperature.""" - return float(self._values.get(self.gateway.const.SetReq.V_TEMP)) + value = self._values.get(self.gateway.const.SetReq.V_TEMP) + + if value is not None: + value = float(value) + + return value @property def target_temperature(self):