cjkrolak / ThermostatSupervisor

supervisor to detect and correct thermostat deviations
MIT License
0 stars 0 forks source link

code updates for pyhtcc 1.44 #618

Closed cjkrolak closed 1 year ago

cjkrolak commented 1 year ago

overridden pyhtcc methods get_zones_info and refresh_zone_info are not compatible with pyhtcc 1.44:

Traceback (most recent call last):
  File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.9/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/supervise.py", line 133, in <module>
    exec_supervise(debug=True, argv_list=argv_inputs)
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/supervise.py", line 113, in exec_supervise
    supervisor(api.uip.get_user_inputs(api.uip.parent_keys[0],
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/supervise.py", line 50, in supervisor
    Thermostat = mod.ThermostatClass(zone_num)
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/honeywell.py", line 56, in __init__
    self.device_id = self.get_target_zone_id(self.zone_name)
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/honeywell.py", line 86, in get_target_zone_id
    zone_id = self._get_zone_device_ids()[zone]
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/honeywell.py", line 72, in _get_zone_device_ids
    for _, zone in enumerate(self.get_zones_info()):
  File "/home/pi/github/ThermostatSupervisor/thermostatsupervisor/honeywell.py", line 223, in get_zones_info
    f"was:\n {result.text}")
AttributeError: 'list' object has no attribute 'text'
cjkrolak commented 1 year ago

pyhtcc code changes: https://github.com/csm10495/pyhtcc/commit/5ac2b23e9b9d4a440142d8f9e0d708fedf43368f pyhtcc original issue: https://github.com/csm10495/pyhtcc/issues/10

I rem'd out two overriden functions with retries and updated requirements for pyhtcc to 1.44, now in testing.