Move imports in frontend component (#27988)
parent
bb381d6060
commit
a13f8a1781
|
@ -6,23 +6,23 @@ import os
|
||||||
import pathlib
|
import pathlib
|
||||||
from typing import Any, Dict, Optional, Set, Tuple
|
from typing import Any, Dict, Optional, Set, Tuple
|
||||||
|
|
||||||
from aiohttp import web, web_urldispatcher, hdrs
|
from aiohttp import hdrs, web, web_urldispatcher
|
||||||
import voluptuous as vol
|
import hass_frontend
|
||||||
import jinja2
|
import jinja2
|
||||||
|
import voluptuous as vol
|
||||||
from yarl import URL
|
from yarl import URL
|
||||||
|
|
||||||
import homeassistant.helpers.config_validation as cv
|
|
||||||
from homeassistant.components.http.view import HomeAssistantView
|
|
||||||
from homeassistant.components import websocket_api
|
from homeassistant.components import websocket_api
|
||||||
|
from homeassistant.components.http.view import HomeAssistantView
|
||||||
from homeassistant.config import find_config_file, load_yaml_config_file
|
from homeassistant.config import find_config_file, load_yaml_config_file
|
||||||
from homeassistant.const import CONF_NAME, EVENT_THEMES_UPDATED
|
from homeassistant.const import CONF_NAME, EVENT_THEMES_UPDATED
|
||||||
from homeassistant.core import callback
|
from homeassistant.core import callback
|
||||||
|
import homeassistant.helpers.config_validation as cv
|
||||||
from homeassistant.helpers.translation import async_get_translations
|
from homeassistant.helpers.translation import async_get_translations
|
||||||
from homeassistant.loader import bind_hass
|
from homeassistant.loader import bind_hass
|
||||||
|
|
||||||
from .storage import async_setup_frontend_storage
|
from .storage import async_setup_frontend_storage
|
||||||
|
|
||||||
|
|
||||||
# mypy: allow-untyped-defs, no-check-untyped-defs
|
# mypy: allow-untyped-defs, no-check-untyped-defs
|
||||||
|
|
||||||
# Fix mimetypes for borked Windows machines
|
# Fix mimetypes for borked Windows machines
|
||||||
|
@ -242,8 +242,6 @@ def _frontend_root(dev_repo_path):
|
||||||
if dev_repo_path is not None:
|
if dev_repo_path is not None:
|
||||||
return pathlib.Path(dev_repo_path) / "hass_frontend"
|
return pathlib.Path(dev_repo_path) / "hass_frontend"
|
||||||
|
|
||||||
import hass_frontend
|
|
||||||
|
|
||||||
return hass_frontend.where()
|
return hass_frontend.where()
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue