Move imports to top for sense (#29258)

This commit is contained in:
springstan authored and Paulus Schoutsen committed 2019-11-30 21:35:45 -08:00
1 parent 2bdf7fc8f5
commit c4c8a1ba2d
3 files changed
+9 -8

No files matched your search

+6 -6
View File
@@ -1,7 +1,12 @@
"""Support for monitoring a Sense energy sensor."""
import logging
from datetime import timedelta
import logging
from sense_energy import (
ASyncSenseable,
SenseAPITimeoutException,
SenseAuthenticationException,
)
import voluptuous as vol
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD, CONF_TIMEOUT
@@ -36,11 +41,6 @@ CONFIG_SCHEMA = vol.Schema(
async def async_setup(hass, config):
"""Set up the Sense sensor."""
from sense_energy import (
ASyncSenseable,
SenseAuthenticationException,
SenseAPITimeoutException,
)
username = config[DOMAIN][CONF_EMAIL]
password = config[DOMAIN][CONF_PASSWORD]