1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-27 14:31:13 +00:00

Various type hint improvements (#46144)

This commit is contained in:
Ville Skyttä
2021-02-08 12:59:46 +02:00
committed by GitHub
parent 54dce1c505
commit 82607977ef
8 changed files with 34 additions and 16 deletions

View File

@@ -2,7 +2,7 @@
import asyncio
import logging
from typing import Any, Dict, Iterable, List, Optional
from typing import Dict, Iterable, List, Optional
from homeassistant import config as conf_util
from homeassistant.const import SERVICE_RELOAD
@@ -10,7 +10,7 @@ from homeassistant.core import Event, callback
from homeassistant.exceptions import HomeAssistantError
from homeassistant.helpers import config_per_platform
from homeassistant.helpers.entity_platform import EntityPlatform, async_get_platforms
from homeassistant.helpers.typing import HomeAssistantType
from homeassistant.helpers.typing import ConfigType, HomeAssistantType
from homeassistant.loader import async_get_integration
from homeassistant.setup import async_setup_component
@@ -49,7 +49,7 @@ async def _resetup_platform(
hass: HomeAssistantType,
integration_name: str,
integration_platform: str,
unprocessed_conf: Dict,
unprocessed_conf: ConfigType,
) -> None:
"""Resetup a platform."""
integration = await async_get_integration(hass, integration_platform)
@@ -129,7 +129,7 @@ async def _async_reconfig_platform(
async def async_integration_yaml_config(
hass: HomeAssistantType, integration_name: str
) -> Optional[Dict[Any, Any]]:
) -> Optional[ConfigType]:
"""Fetch the latest yaml configuration for an integration."""
integration = await async_get_integration(hass, integration_name)