6acaf25b0d81468759c0ebb6a858de860ef21b2b,homeassistant/components/mysensors.py,,setup,#Any#Any#,46

Before Change



def setup(hass, config):  // pylint: disable=too-many-locals
    Setup the MySensors component.
    if not validate_config(config,
                           {DOMAIN: [CONF_GATEWAYS]},
                           _LOGGER):
        return False
    if not all(CONF_DEVICE in gateway
               for gateway in config[DOMAIN][CONF_GATEWAYS]):
        _LOGGER.error("Missing required configuration items "
                      "in %s: %s", DOMAIN, CONF_DEVICE)
        return False

    import mysensors.mysensors as mysensors

    version = str(config[DOMAIN].get(CONF_VERSION, DEFAULT_VERSION))
    is_metric = hass.config.units.is_metric

After Change


    Setup the MySensors component.
    import mysensors.mysensors as mysensors

    version = config[DOMAIN].get(CONF_VERSION)
    persistence = config[DOMAIN].get(CONF_PERSISTENCE)

    def setup_gateway(device, persistence_file, baud_rate, tcp_port, in_prefix,
                      out_prefix):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 9

Instances


Project Name: home-assistant/home-assistant
Commit Name: 6acaf25b0d81468759c0ebb6a858de860ef21b2b
Time: 2016-08-27
Author: marhje52@kth.se
File Name: homeassistant/components/mysensors.py
Class Name:
Method Name: setup


Project Name: onnx/onnx-coreml
Commit Name: bb9c92cf8c6ac6dfe8d95bc7ddc3be6b7d7562ed
Time: 2018-03-28
Author: aseem.elec@gmail.com
File Name: onnx_coreml/_operators.py
Class Name:
Method Name: _convert_pool


Project Name: home-assistant/home-assistant
Commit Name: c000e74d0a5df0f0486796fbbcfe5acbeb9e3120
Time: 2016-09-29
Author: mail@fabian-affolter.ch
File Name: homeassistant/components/binary_sensor/nx584.py
Class Name:
Method Name: setup_platform