Disable too-many-* (#4107)

* Disable too-many-* and too-few-public-methods

* Remove globally disabled pylint warnings
This commit is contained in:
Fabian Affolter authored and GitHub committed 2016-10-30 22:18:53 +01:00
1 parent b910a9917d
commit be272ac64a
298 files changed
+271 -570

No files matched your search

@@ -124,7 +124,6 @@ def is_on(hass, entity_id=None):
return hass.states.is_state(entity_id, STATE_ON)
# pylint: disable=too-many-arguments
def turn_on(hass, entity_id=None, transition=None, brightness=None,
rgb_color=None, xy_color=None, color_temp=None, white_value=None,
profile=None, flash=None, effect=None, color_name=None):
@@ -172,7 +171,6 @@ def toggle(hass, entity_id=None, transition=None):
hass.services.call(DOMAIN, SERVICE_TOGGLE, data)
# pylint: disable=too-many-branches, too-many-locals, too-many-statements
def setup(hass, config):
"""Expose light control via statemachine and services."""
component = EntityComponent(
-1
View File
@@ -34,7 +34,6 @@ def setup_platform(hass, config, add_devices_callback, discovery_info=None):
class DemoLight(Light):
"""Represenation of a demo light."""
# pylint: disable=too-many-arguments
def __init__(
self, name, state, rgb=None, ct=None, brightness=180,
xy_color=(.5, .5), white=200):
@@ -76,7 +76,6 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
class FluxLight(Light):
"""Representation of a Flux light."""
# pylint: disable=too-many-arguments
def __init__(self, device):
"""Initialize the light."""
import flux_led
-1
View File
@@ -199,7 +199,6 @@ def request_configuration(host, hass, add_devices, filename,
class HueLight(Light):
"""Representation of a Hue light."""
# pylint: disable=too-many-arguments
def __init__(self, light_id, info, bridge, update_lights,
bridge_type, allow_unreachable):
"""Initialize the light."""
-4
View File
@@ -80,7 +80,6 @@ class LIFX(object):
break
return bulb
# pylint: disable=too-many-arguments
def on_device(self, ipaddr, name, power, hue, sat, bri, kel):
"""Initialize the light."""
bulb = self.find_bulb(ipaddr)
@@ -99,7 +98,6 @@ class LIFX(object):
bulb.set_color(hue, sat, bri, kel)
bulb.update_ha_state()
# pylint: disable=too-many-arguments
def on_color(self, ipaddr, hue, sat, bri, kel):
"""Initialize the light."""
bulb = self.find_bulb(ipaddr)
@@ -137,11 +135,9 @@ def convert_rgb_to_hsv(rgb):
int(brightness * SHORT_MAX)]
# pylint: disable=too-many-instance-attributes
class LIFXLight(Light):
"""Representation of a LIFX light."""
# pylint: disable=too-many-arguments
def __init__(self, liffy, ipaddr, name, power, hue, saturation, brightness,
kelvin):
"""Initialize the light."""
-2
View File
@@ -101,8 +101,6 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
class MqttLight(Light):
"""MQTT light."""
# pylint: disable=too-many-arguments,too-many-instance-attributes
# pylint: disable=too-many-locals,too-many-branches
def __init__(self, hass, name, topic, templates, qos, retain, payload,
optimistic, brightness_scale):
"""Initialize MQTT light."""
@@ -85,7 +85,6 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
class MqttJson(Light):
"""Representation of a MQTT JSON light."""
# pylint: disable=too-many-arguments,too-many-instance-attributes
def __init__(self, hass, name, topic, qos, retain,
optimistic, brightness, rgb, flash_times):
"""Initialize MQTT JSON light."""
-1
View File
@@ -78,7 +78,6 @@ class WinkLight(WinkDevice, Light):
"""Flag supported features."""
return SUPPORT_WINK
# pylint: disable=too-few-public-methods
def turn_on(self, **kwargs):
"""Turn the switch on."""
brightness = kwargs.get(ATTR_BRIGHTNESS)
@@ -43,7 +43,6 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
class YeelightLight(Light):
"""Representation of a Yeelight light."""
# pylint: disable=too-many-arguments
def __init__(self, device):
"""Initialize the light."""
import pyyeelight
-2
View File
@@ -105,7 +105,6 @@ def brightness_state(value):
class ZwaveDimmer(zwave.ZWaveDeviceEntity, Light):
"""Representation of a Z-Wave dimmer."""
# pylint: disable=too-many-arguments
def __init__(self, value):
"""Initialize the light."""
from openzwave.network import ZWaveNetwork
@@ -263,7 +262,6 @@ class ZwaveColorLight(ZwaveDimmer):
# Check for the missing color values
self._get_color_values()
# pylint: disable=too-many-branches
def update_properties(self):
"""Update internal properties based on zwave values."""
super().update_properties()