From 4c07761271bab89b5e58009223b29c8d27be7c7c Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 26 Jan 2024 21:59:48 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- custom_components/ecotrend_ista/__init__.py | 2 +- custom_components/ecotrend_ista/config_flow.py | 4 ++-- custom_components/ecotrend_ista/const_schema.py | 2 +- custom_components/ecotrend_ista/coordinator.py | 4 ++-- custom_components/ecotrend_ista/sensor.py | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/custom_components/ecotrend_ista/__init__.py b/custom_components/ecotrend_ista/__init__.py index 23d7bec..3228c93 100644 --- a/custom_components/ecotrend_ista/__init__.py +++ b/custom_components/ecotrend_ista/__init__.py @@ -3,12 +3,12 @@ import logging +import voluptuous as vol from homeassistant import config_entries from homeassistant.config_entries import ConfigEntry from homeassistant.const import CONF_EMAIL, CONF_PASSWORD, Platform from homeassistant.core import HomeAssistant from homeassistant.helpers.typing import ConfigType -import voluptuous as vol from .const import DATA_HASS_CONFIG, DOMAIN from .const_schema import DEFAULT_DATA_SCHEMA diff --git a/custom_components/ecotrend_ista/config_flow.py b/custom_components/ecotrend_ista/config_flow.py index 472634b..2af0b25 100644 --- a/custom_components/ecotrend_ista/config_flow.py +++ b/custom_components/ecotrend_ista/config_flow.py @@ -6,6 +6,8 @@ from types import MappingProxyType from typing import Any +import requests +import voluptuous as vol from homeassistant import config_entries, core from homeassistant.const import CONF_EMAIL, CONF_PASSWORD from homeassistant.data_entry_flow import FlowResult @@ -16,8 +18,6 @@ ) from pyecotrend_ista.exception_classes import LoginError from pyecotrend_ista.pyecotrend_ista import PyEcotrendIsta -import requests -import voluptuous as vol from .const import CONF_MFA, CONF_UPDATE_INTERVAL, CONF_URL, DOMAIN, MANUFACTURER from .const_schema import DATA_SCHEMA_EMAIL, URL_SELECTOR diff --git a/custom_components/ecotrend_ista/const_schema.py b/custom_components/ecotrend_ista/const_schema.py index 76fe48c..aec0e9e 100644 --- a/custom_components/ecotrend_ista/const_schema.py +++ b/custom_components/ecotrend_ista/const_schema.py @@ -1,6 +1,7 @@ """Const schema for ista EcoTrend Version 2.""" from __future__ import annotations +import voluptuous as vol from homeassistant.const import CONF_EMAIL, CONF_PASSWORD, CONF_SCAN_INTERVAL from homeassistant.helpers.selector import ( NumberSelector, @@ -14,7 +15,6 @@ TextSelectorConfig, TextSelectorType, ) -import voluptuous as vol from .const import ( CONF_MFA, diff --git a/custom_components/ecotrend_ista/coordinator.py b/custom_components/ecotrend_ista/coordinator.py index 14d127f..78ead83 100644 --- a/custom_components/ecotrend_ista/coordinator.py +++ b/custom_components/ecotrend_ista/coordinator.py @@ -2,18 +2,18 @@ from __future__ import annotations import datetime -from datetime import timedelta import json import logging import os +from datetime import timedelta from typing import Any +import requests from homeassistant.config_entries import ConfigEntry from homeassistant.core import HomeAssistant from homeassistant.helpers.update_coordinator import DataUpdateCoordinator from pyecotrend_ista.helper_object_de import CustomRaw from pyecotrend_ista.pyecotrend_ista import PyEcotrendIsta -import requests from .config_flow import login_account from .const import CONF_UPDATE_INTERVAL, DOMAIN diff --git a/custom_components/ecotrend_ista/sensor.py b/custom_components/ecotrend_ista/sensor.py index 12999af..ba433e2 100644 --- a/custom_components/ecotrend_ista/sensor.py +++ b/custom_components/ecotrend_ista/sensor.py @@ -1,9 +1,9 @@ """Support for reading status from ecotren-ists.""" from __future__ import annotations -from collections.abc import Callable import datetime import logging +from collections.abc import Callable from typing import Any, cast from homeassistant.components.sensor import RestoreSensor, SensorEntity