Update docstrings (#7361)

* Update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* Update docstrings

* Update tomato.py

* Update isy994.py

* Lint + fix tests

* Lint
This commit is contained in:
Fabian Affolter 2017-04-30 07:04:49 +02:00 committed by Paulus Schoutsen
parent e22e70a01a
commit 3ee4d1060f
264 changed files with 1686 additions and 1768 deletions

View file

@ -37,8 +37,8 @@ class Host(object):
self.ip_address = ip_address
self.dev_id = dev_id
self._count = config[CONF_PING_COUNT]
if sys.platform == "win32":
self._ping_cmd = ['ping', '-n 1', '-w 1000', self.ip_address]
if sys.platform == 'win32':
self._ping_cmd = ['ping', '-n 1', '-w', '1000', self.ip_address]
else:
self._ping_cmd = ['ping', '-n', '-q', '-c1', '-W1',
self.ip_address]
@ -67,7 +67,7 @@ class Host(object):
def setup_scanner(hass, config, see, discovery_info=None):
"""Setup the Host objects and return the update function."""
"""Set up the Host objects and return the update function."""
hosts = [Host(ip, dev_id, hass, config) for (dev_id, ip) in
config[const.CONF_HOSTS].items()]
interval = timedelta(seconds=len(hosts) * config[CONF_PING_COUNT]) + \