9d848731d903a8ee2296bbfc6746f4eb5143a446,homeassistant/components/sensor/nest.py,,setup_platform,#Any#Any#Any#Any#,38

Before Change


                                                     device,
                                                     variable)])
                    elif variable in SENSOR_TEMP_TYPES:
                        add_devices([NestTempSensor(structure,
                                                    device,
                                                    variable)])
                    elif variable in WEATHER_VARIABLES:
                        json_variable = JSON_VARIABLE_NAMES.get(variable, None)
                        add_devices([NestWeatherSensor(structure,
                                                       device,

After Change


    Setup the Nest Sensor.
    for structure, device in nest.devices():
        sensors = [NestBasicSensor(structure, device, variable)
                   for variable in config[CONF_MONITORED_CONDITIONS]
                   if variable in SENSOR_TYPES]
        sensors += [NestTempSensor(structure, device, variable)
                    for variable in config[CONF_MONITORED_CONDITIONS]
                    if variable in SENSOR_TEMP_TYPES]
        sensors += [NestWeatherSensor(structure, device,
                                      WEATHER_VARS[variable])
                    for variable in config[CONF_MONITORED_CONDITIONS]
                    if variable in WEATHER_VARS]
        add_devices(sensors)


class NestSensor(Entity):
    Representation of a Nest sensor.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: home-assistant/home-assistant
Commit Name: 9d848731d903a8ee2296bbfc6746f4eb5143a446
Time: 2016-04-11
Author: jaharkes@cs.cmu.edu
File Name: homeassistant/components/sensor/nest.py
Class Name:
Method Name: setup_platform


Project Name: home-assistant/home-assistant
Commit Name: 50a9b3a7c0bf65df2565cc403079404209d1e483
Time: 2016-02-04
Author: saturlight@gmail.com
File Name: homeassistant/components/sensor/tellduslive.py
Class Name:
Method Name: setup_platform


Project Name: home-assistant/home-assistant
Commit Name: fdd19577503574a65f1e534de1d5b890db3a458d
Time: 2017-03-07
Author: colinodell@gmail.com
File Name: homeassistant/components/sensor/pi_hole.py
Class Name:
Method Name: setup_platform