Move imports to top for websocket_api (#29556)
* Move imports to top for websocket_api * Move back an import because of circular dependency, add annotations
This commit is contained in:
parent
21cf6777bb
commit
6de8072e8a
10 changed files with 23 additions and 28 deletions
|
@ -4,28 +4,27 @@ from contextlib import suppress
|
|||
import logging
|
||||
from typing import Optional
|
||||
|
||||
from aiohttp import web, WSMsgType
|
||||
from aiohttp import WSMsgType, web
|
||||
import async_timeout
|
||||
|
||||
from homeassistant.components.http import HomeAssistantView
|
||||
from homeassistant.const import EVENT_HOMEASSISTANT_STOP
|
||||
from homeassistant.core import callback
|
||||
from homeassistant.components.http import HomeAssistantView
|
||||
|
||||
from .auth import AuthPhase, auth_required_message
|
||||
from .const import (
|
||||
MAX_PENDING_MSG,
|
||||
CANCELLATION_ERRORS,
|
||||
URL,
|
||||
DATA_CONNECTIONS,
|
||||
ERR_UNKNOWN_ERROR,
|
||||
JSON_DUMP,
|
||||
MAX_PENDING_MSG,
|
||||
SIGNAL_WEBSOCKET_CONNECTED,
|
||||
SIGNAL_WEBSOCKET_DISCONNECTED,
|
||||
DATA_CONNECTIONS,
|
||||
JSON_DUMP,
|
||||
URL,
|
||||
)
|
||||
from .auth import AuthPhase, auth_required_message
|
||||
from .error import Disconnect
|
||||
from .messages import error_message
|
||||
|
||||
|
||||
# mypy: allow-untyped-calls, allow-untyped-defs, no-check-untyped-defs
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue