13cb16b9edbb868505c41401dc951a8c8accb396,services/core/MasterDriverAgent/master_driver/interfaces/ecobee.py,Interface,_set_point,#Interface#Any#Any#,378
Before Change
register = self.get_register_by_name(point_name)
if register.read_only:
raise IOError("Trying to write to a point configured read only: {}".format(point_name))
if register.register_type not in ["setting", "hold", "vacation", "programs"]:
raise RuntimeError("Register {} type {} does not support set_point".format(register.point_name,
register.register_type))
try:
if register.register_type == "setting" or register.register_type == "hold":
register.set_state(value)
elif register.register_type in ["vacation", "programs"]:
After Change
register = self.get_register_by_name(point_name)
if register.read_only:
raise IOError("Trying to write to a point configured read only: {}".format(point_name))
if register.register_type == "status":
raise RuntimeError("Status register does not support set_point")
try:
if register.register_type == "setting" or register.register_type == "hold":
register.set_state(value)
elif register.register_type in ["vacation", "programs"]:
register.set_state(value, **kwargs)
except (RemoteError, ConnectionError) as err:
_log.error("Error setting Ecobee point: {}. Refreshing tokens and sending again".format(err))
self.authorization_stage = "REFRESH_TOKENS"
self.refresh_tokens()
if register.register_type == "setting" or register.register_type == "hold":
register.set_state(value)
elif register.register_type in ["vacation", "programs"]:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: VOLTTRON/volttron
Commit Name: 13cb16b9edbb868505c41401dc951a8c8accb396
Time: 2020-06-22
Author: james.larson@pnnl.gov
File Name: services/core/MasterDriverAgent/master_driver/interfaces/ecobee.py
Class Name: Interface
Method Name: _set_point
Project Name: home-assistant/home-assistant
Commit Name: 81e5a852f0d243f8e7d526fd9ab8e7c1e3e261f4
Time: 2016-03-10
Author: per.j.sandstrom@gmail.com
File Name: homeassistant/helpers/service.py
Class Name:
Method Name: call_from_config
Project Name: VOLTTRON/volttron
Commit Name: 694383ee05139068146f021d19f80143f98011f6
Time: 2020-06-01
Author: james.larson@pnnl.gov
File Name: services/core/MasterDriverAgent/master_driver/interfaces/ecobee.py
Class Name: Interface
Method Name: _set_point