More pylint 2 fixes (#15565)

## Description:

More fixes flagged by pylint 2 that don't hurt to have before the actual pylint 2 upgrade (which I'll submit soon).

## Checklist:
  - [ ] The code change is tested and works locally.
  - [x] Local tests pass with `tox`. **Your PR cannot be merged unless tests pass**
This commit is contained in:
Ville Skyttä authored and Andrey committed 2018-07-20 11:45:20 +03:00
1 parent ea18e06b08
commit 2f7b79764a
242 files changed
+284 -284

No files matched your search

@@ -107,7 +107,7 @@ class PwrCtrlSwitch(SwitchDevice):
self._port.off()
class PwrCtrlDevice(object):
class PwrCtrlDevice:
"""Device representation for per device throttling."""
def __init__(self, device):
+1 -1
View File
@@ -348,7 +348,7 @@ class BroadlinkMP1Slot(BroadlinkRMSwitch):
self._state = self._parent_device.get_outlet_status(self._slot)
class BroadlinkMP1Switch(object):
class BroadlinkMP1Switch:
"""Representation of a Broadlink switch - To fetch states of all slots."""
def __init__(self, device):
@@ -122,7 +122,7 @@ class DINRelay(SwitchDevice):
self._state = outlet_status[2] == 'ON'
class DINRelayDevice(object):
class DINRelayDevice:
"""Device representation for per device throttling."""
def __init__(self, power_switch):
+1 -1
View File
@@ -125,7 +125,7 @@ class SmartPlugSwitch(SwitchDevice):
self.data.update()
class SmartPlugData(object):
class SmartPlugData:
"""Get the latest data from smart plug."""
def __init__(self, smartplug):
+1 -1
View File
@@ -163,7 +163,7 @@ class FritzDectSwitch(SwitchDevice):
self.data.is_online = False
class FritzDectSwitchData(object):
class FritzDectSwitchData:
"""Get the latest data from the fritz box."""
def __init__(self, fritz, ain):
+1 -1
View File
@@ -80,7 +80,7 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
add_devices(devices)
class _ReceiveHandle(object):
class _ReceiveHandle:
def __init__(self, config, echo):
"""Initialize the handle."""
self.config_items = config.items()
+1 -1
View File
@@ -152,7 +152,7 @@ class SCSGateSwitch(SwitchDevice):
)
class SCSGateScenarioSwitch(object):
class SCSGateScenarioSwitch:
"""Provides a SCSGate scenario switch.
This switch is always in an 'off" state, when toggled it's used to trigger
+1 -1
View File
@@ -8,7 +8,7 @@ import logging
import time
from homeassistant.components.switch import DOMAIN, SwitchDevice
from homeassistant.components import zwave
from homeassistant.components.zwave import workaround, async_setup_platform # noqa # pylint: disable=unused-import
from homeassistant.components.zwave import workaround, async_setup_platform # noqa pylint: disable=unused-import
_LOGGER = logging.getLogger(__name__)