Spelling fixes (#12041)
* Spelling fixes *Lots* of them. * Spelling breaking changes * Fix lint errors
This commit is contained in:
1 parent
38fd9b65bf
commit
8dcfd35b8b
138 files changed
+285
-286
No files matched your search
@@ -103,13 +103,13 @@ class AcerSwitch(SwitchDevice):
|
||||
# need to wait for timeout
|
||||
ret = self.ser.read_until(size=20).decode('utf-8')
|
||||
except serial.SerialException:
|
||||
_LOGGER.error('Problem comunicating with %s', self._serial_port)
|
||||
_LOGGER.error('Problem communicating with %s', self._serial_port)
|
||||
self.ser.close()
|
||||
return ret
|
||||
|
||||
def _write_read_format(self, msg):
|
||||
"""Write msg, obtain awnser and format output."""
|
||||
# awnsers are formatted as ***\rawnser\r***
|
||||
"""Write msg, obtain answer and format output."""
|
||||
# answers are formatted as ***\answer\r***
|
||||
awns = self._write_read(msg)
|
||||
match = re.search(r'\r(.+)\r', awns)
|
||||
if match:
|
||||
|
||||
@@ -33,7 +33,7 @@ CONF_START_CT = 'start_colortemp'
|
||||
CONF_SUNSET_CT = 'sunset_colortemp'
|
||||
CONF_STOP_CT = 'stop_colortemp'
|
||||
CONF_BRIGHTNESS = 'brightness'
|
||||
CONF_DISABLE_BRIGTNESS_ADJUST = 'disable_brightness_adjust'
|
||||
CONF_DISABLE_BRIGHTNESS_ADJUST = 'disable_brightness_adjust'
|
||||
CONF_INTERVAL = 'interval'
|
||||
|
||||
MODE_XY = 'xy'
|
||||
@@ -57,7 +57,7 @@ PLATFORM_SCHEMA = vol.Schema({
|
||||
vol.All(vol.Coerce(int), vol.Range(min=1000, max=40000)),
|
||||
vol.Optional(CONF_BRIGHTNESS):
|
||||
vol.All(vol.Coerce(int), vol.Range(min=0, max=255)),
|
||||
vol.Optional(CONF_DISABLE_BRIGTNESS_ADJUST): cv.boolean,
|
||||
vol.Optional(CONF_DISABLE_BRIGHTNESS_ADJUST): cv.boolean,
|
||||
vol.Optional(CONF_MODE, default=DEFAULT_MODE):
|
||||
vol.Any(MODE_XY, MODE_MIRED, MODE_RGB),
|
||||
vol.Optional(CONF_INTERVAL, default=30): cv.positive_int,
|
||||
@@ -105,7 +105,7 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
|
||||
sunset_colortemp = config.get(CONF_SUNSET_CT)
|
||||
stop_colortemp = config.get(CONF_STOP_CT)
|
||||
brightness = config.get(CONF_BRIGHTNESS)
|
||||
disable_brightness_adjust = config.get(CONF_DISABLE_BRIGTNESS_ADJUST)
|
||||
disable_brightness_adjust = config.get(CONF_DISABLE_BRIGHTNESS_ADJUST)
|
||||
mode = config.get(CONF_MODE)
|
||||
interval = config.get(CONF_INTERVAL)
|
||||
transition = config.get(ATTR_TRANSITION)
|
||||
|
||||
@@ -51,7 +51,7 @@ def async_add_devices_discovery(hass, discovery_info, async_add_devices):
|
||||
|
||||
@callback
|
||||
def async_add_devices_config(hass, config, async_add_devices):
|
||||
"""Set up switch for KNX platform configured within plattform."""
|
||||
"""Set up switch for KNX platform configured within platform."""
|
||||
import xknx
|
||||
switch = xknx.devices.Switch(
|
||||
hass.data[DATA_KNX].xknx,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
"""
|
||||
Support for Neato Connected Vaccums switches.
|
||||
Support for Neato Connected Vacuums switches.
|
||||
|
||||
For more details about this platform, please refer to the documentation at
|
||||
https://home-assistant.io/components/switch.neato/
|
||||
@@ -68,7 +68,7 @@ class NeatoConnectedSwitch(ToggleEntity):
|
||||
self._schedule_state = STATE_ON
|
||||
else:
|
||||
self._schedule_state = STATE_OFF
|
||||
_LOGGER.debug("Shedule state: %s", self._schedule_state)
|
||||
_LOGGER.debug("Schedule state: %s", self._schedule_state)
|
||||
|
||||
@property
|
||||
def name(self):
|
||||
|
||||
@@ -19,9 +19,9 @@ from homeassistant.helpers.restore_state import async_get_last_state
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
CONF_OFF_CODE = 'off_code'
|
||||
CONF_OFF_CODE_RECIEVE = 'off_code_receive'
|
||||
CONF_OFF_CODE_RECEIVE = 'off_code_receive'
|
||||
CONF_ON_CODE = 'on_code'
|
||||
CONF_ON_CODE_RECIEVE = 'on_code_receive'
|
||||
CONF_ON_CODE_RECEIVE = 'on_code_receive'
|
||||
CONF_SYSTEMCODE = 'systemcode'
|
||||
CONF_UNIT = 'unit'
|
||||
CONF_UNITCODE = 'unitcode'
|
||||
@@ -48,9 +48,9 @@ SWITCHES_SCHEMA = vol.Schema({
|
||||
vol.Required(CONF_ON_CODE): COMMAND_SCHEMA,
|
||||
vol.Required(CONF_OFF_CODE): COMMAND_SCHEMA,
|
||||
vol.Optional(CONF_NAME): cv.string,
|
||||
vol.Optional(CONF_OFF_CODE_RECIEVE, default=[]): vol.All(cv.ensure_list,
|
||||
vol.Optional(CONF_OFF_CODE_RECEIVE, default=[]): vol.All(cv.ensure_list,
|
||||
[COMMAND_SCHEMA]),
|
||||
vol.Optional(CONF_ON_CODE_RECIEVE, default=[]): vol.All(cv.ensure_list,
|
||||
vol.Optional(CONF_ON_CODE_RECEIVE, default=[]): vol.All(cv.ensure_list,
|
||||
[COMMAND_SCHEMA])
|
||||
})
|
||||
|
||||
@@ -72,8 +72,8 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
|
||||
properties.get(CONF_NAME, dev_name),
|
||||
properties.get(CONF_ON_CODE),
|
||||
properties.get(CONF_OFF_CODE),
|
||||
properties.get(CONF_ON_CODE_RECIEVE),
|
||||
properties.get(CONF_OFF_CODE_RECIEVE)
|
||||
properties.get(CONF_ON_CODE_RECEIVE),
|
||||
properties.get(CONF_OFF_CODE_RECEIVE)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
@@ -134,7 +134,7 @@ class RachioIro(object):
|
||||
return self._running
|
||||
|
||||
def list_zones(self, include_disabled=False):
|
||||
"""Return alist of the zones connected to the device, incl. data."""
|
||||
"""Return a list of the zones connected to the device, incl. data."""
|
||||
if not self._zones:
|
||||
self._zones = [RachioZone(self.rachio, self, zone['id'],
|
||||
self.manual_run_mins)
|
||||
|
||||
@@ -52,7 +52,7 @@ class RainBirdSwitch(SwitchDevice):
|
||||
self._devid = dev_id
|
||||
self._zone = int(dev.get(CONF_ZONE))
|
||||
self._name = dev.get(CONF_FRIENDLY_NAME,
|
||||
"Sprinker {}".format(self._zone))
|
||||
"Sprinkler {}".format(self._zone))
|
||||
self._state = None
|
||||
self._duration = dev.get(CONF_TRIGGER_TIME)
|
||||
self._attributes = {
|
||||
|
||||
Reference in new issue
Block a user