mirror of
https://github.com/home-assistant/core.git
synced 2025-11-16 14:30:22 +00:00
Add sensor setup type hints [g-h] (#63316)
Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
@@ -16,8 +16,11 @@ from homeassistant.const import (
|
||||
CONF_PATH,
|
||||
CONF_URL,
|
||||
)
|
||||
from homeassistant.core import HomeAssistant
|
||||
from homeassistant.helpers.aiohttp_client import async_get_clientsession
|
||||
import homeassistant.helpers.config_validation as cv
|
||||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
@@ -56,7 +59,12 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend(
|
||||
)
|
||||
|
||||
|
||||
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
|
||||
async def async_setup_platform(
|
||||
hass: HomeAssistant,
|
||||
config: ConfigType,
|
||||
async_add_entities: AddEntitiesCallback,
|
||||
discovery_info: DiscoveryInfoType | None = None,
|
||||
) -> None:
|
||||
"""Set up the GitHub sensor platform."""
|
||||
sensors = []
|
||||
session = async_get_clientsession(hass)
|
||||
|
||||
Reference in New Issue
Block a user