Add sensor setup type hints [c-d] (#63318)
Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
parent
30a64bd0f2
commit
84221f656a
20 changed files with 206 additions and 27 deletions
|
@ -19,8 +19,11 @@ from homeassistant.const import (
|
|||
CONF_NAME,
|
||||
CONF_TOKEN,
|
||||
)
|
||||
from homeassistant.core import HomeAssistant
|
||||
from homeassistant.helpers.aiohttp_client import SERVER_SOFTWARE
|
||||
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__)
|
||||
|
||||
|
@ -72,7 +75,12 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend(
|
|||
)
|
||||
|
||||
|
||||
def setup_platform(hass, config, add_entities, discovery_info=None):
|
||||
def setup_platform(
|
||||
hass: HomeAssistant,
|
||||
config: ConfigType,
|
||||
add_entities: AddEntitiesCallback,
|
||||
discovery_info: DiscoveryInfoType | None = None,
|
||||
) -> None:
|
||||
"""Set up the Discogs sensor."""
|
||||
token = config[CONF_TOKEN]
|
||||
name = config[CONF_NAME]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue