More isort preparations (#16633)
* Adjust config closer to currently established style conventions * Adjust some imports for better outcome with their comments
This commit is contained in:
parent
0121e3cb04
commit
227a1b919b
5 changed files with 14 additions and 10 deletions
|
@ -9,8 +9,8 @@ import datetime
|
|||
import homeassistant.util.dt as dt_util
|
||||
from homeassistant.helpers.event import track_point_in_time
|
||||
from homeassistant.components import zwave
|
||||
from homeassistant.components.zwave import workaround
|
||||
from homeassistant.components.zwave import async_setup_platform # noqa pylint: disable=unused-import
|
||||
from homeassistant.components.zwave import ( # noqa pylint: disable=unused-import
|
||||
async_setup_platform, workaround)
|
||||
from homeassistant.components.binary_sensor import (
|
||||
DOMAIN,
|
||||
BinarySensorDevice)
|
||||
|
|
|
@ -10,8 +10,8 @@ from homeassistant.components.climate import (
|
|||
DOMAIN, ClimateDevice, STATE_AUTO, STATE_COOL, STATE_HEAT,
|
||||
SUPPORT_TARGET_TEMPERATURE, SUPPORT_FAN_MODE,
|
||||
SUPPORT_OPERATION_MODE, SUPPORT_SWING_MODE)
|
||||
from homeassistant.components.zwave import ZWaveDeviceEntity
|
||||
from homeassistant.components.zwave import async_setup_platform # noqa pylint: disable=unused-import
|
||||
from homeassistant.components.zwave import ( # noqa pylint: disable=unused-import
|
||||
ZWaveDeviceEntity, async_setup_platform)
|
||||
from homeassistant.const import (
|
||||
STATE_OFF, TEMP_CELSIUS, TEMP_FAHRENHEIT, ATTR_TEMPERATURE)
|
||||
|
||||
|
|
|
@ -9,10 +9,9 @@ https://home-assistant.io/components/cover.zwave/
|
|||
import logging
|
||||
from homeassistant.components.cover import (
|
||||
DOMAIN, SUPPORT_OPEN, SUPPORT_CLOSE, ATTR_POSITION)
|
||||
from homeassistant.components.zwave import ZWaveDeviceEntity
|
||||
from homeassistant.components import zwave
|
||||
from homeassistant.components.zwave import async_setup_platform # noqa pylint: disable=unused-import
|
||||
from homeassistant.components.zwave import workaround
|
||||
from homeassistant.components.zwave import ( # noqa pylint: disable=unused-import
|
||||
ZWaveDeviceEntity, async_setup_platform, workaround)
|
||||
from homeassistant.components.cover import CoverDevice
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
|
|
@ -9,7 +9,6 @@ import logging
|
|||
import datetime
|
||||
|
||||
import voluptuous as vol
|
||||
# from voluptuous.humanize import humanize_error
|
||||
|
||||
from homeassistant import config_entries
|
||||
from homeassistant.components.http import HomeAssistantView
|
||||
|
@ -274,8 +273,9 @@ class iOSIdentifyDeviceView(HomeAssistantView):
|
|||
# try:
|
||||
# data = IDENTIFY_SCHEMA(req_data)
|
||||
# except vol.Invalid as ex:
|
||||
# return self.json_message(humanize_error(request.json, ex),
|
||||
# HTTP_BAD_REQUEST)
|
||||
# return self.json_message(
|
||||
# vol.humanize.humanize_error(request.json, ex),
|
||||
# HTTP_BAD_REQUEST)
|
||||
|
||||
data[ATTR_LAST_SEEN_AT] = datetime.datetime.now().isoformat()
|
||||
|
||||
|
|
|
@ -33,3 +33,8 @@ not_skip = __init__.py
|
|||
# will group `import x` and `from x import` of the same module.
|
||||
force_sort_within_sections = true
|
||||
sections = FUTURE,STDLIB,INBETWEENS,THIRDPARTY,FIRSTPARTY,LOCALFOLDER
|
||||
default_section = THIRDPARTY
|
||||
known_first_party = homeassistant,tests
|
||||
forced_separate = tests
|
||||
combine_as_imports = true
|
||||
use_parentheses = true
|
||||
|
|
Loading…
Add table
Reference in a new issue