Use relative imports inside integrations (#22235)

* Use relative imports inside integrations

* Lint

* Fix automation tests

* Fix scene imports
This commit is contained in:
Paulus Schoutsen authored and GitHub committed 2019-03-20 22:56:46 -07:00
1 parent ab17b22239
commit 4b1de61110
522 files changed
+1834 -1725

No files matched your search

@@ -4,7 +4,8 @@ import logging
import requests
from homeassistant.components.binary_sensor import BinarySensorDevice
from homeassistant.components.fritzbox import DOMAIN as FRITZBOX_DOMAIN
from . import DOMAIN as FRITZBOX_DOMAIN
DEPENDENCIES = ['fritzbox']
+9 -9
View File
@@ -3,19 +3,19 @@ import logging
import requests
from homeassistant.components.fritzbox import DOMAIN as FRITZBOX_DOMAIN
from homeassistant.components.fritzbox import (
ATTR_STATE_DEVICE_LOCKED, ATTR_STATE_BATTERY_LOW, ATTR_STATE_HOLIDAY_MODE,
ATTR_STATE_LOCKED, ATTR_STATE_SUMMER_MODE,
ATTR_STATE_WINDOW_OPEN)
from homeassistant.components.climate import ClimateDevice
from homeassistant.components.climate.const import (
ATTR_OPERATION_MODE, STATE_ECO, STATE_HEAT, STATE_MANUAL,
SUPPORT_OPERATION_MODE,
SUPPORT_TARGET_TEMPERATURE)
SUPPORT_OPERATION_MODE, SUPPORT_TARGET_TEMPERATURE)
from homeassistant.const import (
ATTR_BATTERY_LEVEL, ATTR_TEMPERATURE, PRECISION_HALVES, TEMP_CELSIUS,
STATE_OFF, STATE_ON)
ATTR_BATTERY_LEVEL, ATTR_TEMPERATURE, PRECISION_HALVES, STATE_OFF,
STATE_ON, TEMP_CELSIUS)
from . import (
ATTR_STATE_BATTERY_LOW, ATTR_STATE_DEVICE_LOCKED, ATTR_STATE_HOLIDAY_MODE,
ATTR_STATE_LOCKED, ATTR_STATE_SUMMER_MODE, ATTR_STATE_WINDOW_OPEN,
DOMAIN as FRITZBOX_DOMAIN)
DEPENDENCIES = ['fritzbox']
_LOGGER = logging.getLogger(__name__)
+4 -4
View File
@@ -3,11 +3,11 @@ import logging
import requests
from homeassistant.components.fritzbox import DOMAIN as FRITZBOX_DOMAIN
from homeassistant.components.fritzbox import (
ATTR_STATE_DEVICE_LOCKED, ATTR_STATE_LOCKED)
from homeassistant.helpers.entity import Entity
from homeassistant.const import TEMP_CELSIUS
from homeassistant.helpers.entity import Entity
from . import (
ATTR_STATE_DEVICE_LOCKED, ATTR_STATE_LOCKED, DOMAIN as FRITZBOX_DOMAIN)
DEPENDENCIES = ['fritzbox']
+5 -5
View File
@@ -3,12 +3,12 @@ import logging
import requests
from homeassistant.components.fritzbox import DOMAIN as FRITZBOX_DOMAIN
from homeassistant.components.fritzbox import (
ATTR_STATE_DEVICE_LOCKED, ATTR_STATE_LOCKED)
from homeassistant.components.switch import SwitchDevice
from homeassistant.const import (ATTR_TEMPERATURE, TEMP_CELSIUS,
ENERGY_KILO_WATT_HOUR)
from homeassistant.const import (
ATTR_TEMPERATURE, ENERGY_KILO_WATT_HOUR, TEMP_CELSIUS)
from . import (
ATTR_STATE_DEVICE_LOCKED, ATTR_STATE_LOCKED, DOMAIN as FRITZBOX_DOMAIN)
DEPENDENCIES = ['fritzbox']