mirror of
https://github.com/home-assistant/core.git
synced 2025-07-15 09:17:10 +00:00
Improve type hints in cloud (#87263)
This commit is contained in:
parent
ad039b5ffc
commit
b03f4fa1d3
@ -2,6 +2,7 @@
|
|||||||
import asyncio
|
import asyncio
|
||||||
from http import HTTPStatus
|
from http import HTTPStatus
|
||||||
import logging
|
import logging
|
||||||
|
from typing import Any
|
||||||
|
|
||||||
from hass_nabucasa import Cloud, cloud_api
|
from hass_nabucasa import Cloud, cloud_api
|
||||||
from hass_nabucasa.google_report_state import ErrorResponse
|
from hass_nabucasa.google_report_state import ErrorResponse
|
||||||
@ -9,7 +10,13 @@ from hass_nabucasa.google_report_state import ErrorResponse
|
|||||||
from homeassistant.components.google_assistant import DOMAIN as GOOGLE_DOMAIN
|
from homeassistant.components.google_assistant import DOMAIN as GOOGLE_DOMAIN
|
||||||
from homeassistant.components.google_assistant.helpers import AbstractConfig
|
from homeassistant.components.google_assistant.helpers import AbstractConfig
|
||||||
from homeassistant.const import CLOUD_NEVER_EXPOSED_ENTITIES
|
from homeassistant.const import CLOUD_NEVER_EXPOSED_ENTITIES
|
||||||
from homeassistant.core import CoreState, Event, callback, split_entity_id
|
from homeassistant.core import (
|
||||||
|
CoreState,
|
||||||
|
Event,
|
||||||
|
HomeAssistant,
|
||||||
|
callback,
|
||||||
|
split_entity_id,
|
||||||
|
)
|
||||||
from homeassistant.helpers import device_registry as dr, entity_registry as er, start
|
from homeassistant.helpers import device_registry as dr, entity_registry as er, start
|
||||||
from homeassistant.setup import async_setup_component
|
from homeassistant.setup import async_setup_component
|
||||||
|
|
||||||
@ -28,8 +35,13 @@ class CloudGoogleConfig(AbstractConfig):
|
|||||||
"""HA Cloud Configuration for Google Assistant."""
|
"""HA Cloud Configuration for Google Assistant."""
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
self, hass, config, cloud_user: str, prefs: CloudPreferences, cloud: Cloud
|
self,
|
||||||
):
|
hass: HomeAssistant,
|
||||||
|
config: dict[str, Any],
|
||||||
|
cloud_user: str,
|
||||||
|
prefs: CloudPreferences,
|
||||||
|
cloud: Cloud,
|
||||||
|
) -> None:
|
||||||
"""Initialize the Google config."""
|
"""Initialize the Google config."""
|
||||||
super().__init__(hass)
|
super().__init__(hass)
|
||||||
self._config = config
|
self._config = config
|
||||||
|
Loading…
x
Reference in New Issue
Block a user