Skip to content

Commit

Permalink
Add note about #63 which will need to be fixed in the future, and onl…
Browse files Browse the repository at this point in the history
…y print error once
  • Loading branch information
jimboca committed Dec 26, 2020
1 parent 437ccfe commit 09ee03c
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions nodes/Thermostat.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ def __init__(self, controller, primary, address, thermostatId, name, revData, fu
self.weather = None
self.forcast = None
self._gcde = {}
self._gcidx = {}
# We track our driver values because we need the value before it's been pushed.
self.driver = dict()
super(Thermostat, self).__init__(controller, primary, address, name)
Expand Down Expand Up @@ -280,8 +281,10 @@ def getClimateIndex(self,name):
if name in climateMap:
climateIndex = climateMap[name]
else:
LOGGER.error("Unknown climateType='{}'".format(name))
climateIndex = climateMap['unknown']
if not name in self._gcidx[name]:
LOGGER.error("Unknown climateType='{}' which is a known issue https://github.com/Einstein42/udi-ecobee-poly/issues/63".format(name))
self._gcidx[name] = True
climateIndex = climateMap['unknown']
return climateIndex

def getCurrentClimateDict(self):
Expand All @@ -295,7 +298,7 @@ def getClimateDict(self,name):
# Only show the error one time.
if not cref in self._gcde:
self._gcde[cref] = True
LOGGER.error('{}:getClimateDict: Unknown climateRef name {} See: https://github.com/Einstein42/udi-ecobee-poly/issues/63'.format(self.address,name),exc_info=True)
LOGGER.error('{}:getClimateDict: Unknown climateRef name {}'.format(self.address,name),exc_info=True)
return None

def getSensorAddressOld(self,sdata):
Expand Down

0 comments on commit 09ee03c

Please sign in to comment.