903cda08b153400849409c253cbc8051af53a503,homeassistant/components/switch/insteon_local.py,,setup_platform,#Any#Any#Any#Any#,26
Before Change
Set up the Insteon local switch platform.
insteonhub = hass.data["insteon_local"]
conf_switches = load_json(hass.config.path(INSTEON_LOCAL_SWITCH_CONF))
if conf_switches:
for device_id in conf_switches:
setup_switch(
device_id, conf_switches[device_id], insteonhub, hass,
After Change
def setup_platform(hass, config, add_devices, discovery_info=None):
Set up the Insteon local switch platform.
insteonhub = hass.data["insteon_local"]
if discovery_info is None:
return
linked = discovery_info["linked"]
device_list = []
for device_id in linked:
if linked[device_id]["cat_type"] == "switch":
device = insteonhub.switch(device_id)
device_list.append(
InsteonLocalSwitchDevice(device)
)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 6
Instances Project Name: home-assistant/home-assistant
Commit Name: 903cda08b153400849409c253cbc8051af53a503
Time: 2018-01-08
Author: cameron.b.llewellyn@gmail.com
File Name: homeassistant/components/switch/insteon_local.py
Class Name:
Method Name: setup_platform
Project Name: home-assistant/home-assistant
Commit Name: 903cda08b153400849409c253cbc8051af53a503
Time: 2018-01-08
Author: cameron.b.llewellyn@gmail.com
File Name: homeassistant/components/switch/insteon_local.py
Class Name:
Method Name: setup_platform
Project Name: home-assistant/home-assistant
Commit Name: 903cda08b153400849409c253cbc8051af53a503
Time: 2018-01-08
Author: cameron.b.llewellyn@gmail.com
File Name: homeassistant/components/light/insteon_local.py
Class Name:
Method Name: setup_platform
Project Name: home-assistant/home-assistant
Commit Name: 44abc31057c174968939beb940d48e55b326895c
Time: 2015-11-20
Author: nkgilley@gmail.com
File Name: homeassistant/components/thermostat/ecobee.py
Class Name:
Method Name: setup_platform