1 """Typing Helpers for Home Assistant."""
3 from collections.abc
import Mapping
5 from functools
import partial
6 from typing
import Any, Never
8 import voluptuous
as vol
10 from .deprecation
import (
11 DeferredDeprecatedAlias,
12 all_with_deprecated_constants,
13 check_if_deprecated_constant,
14 dir_with_deprecated_constants,
17 type GPSType = tuple[float, float]
18 type ConfigType = dict[str, Any]
19 type DiscoveryInfoType = dict[str, Any]
20 type ServiceDataType = dict[str, Any]
21 type StateType = str | int | float |
None
22 type TemplateVarsType = Mapping[str, Any] |
None
23 type NoEventData = Mapping[str, Never]
24 type VolSchemaType = vol.Schema | vol.All | vol.Any
25 type VolDictType = dict[str | vol.Marker, Any]
32 """Singleton type for use with not set sentinel values."""
37 UNDEFINED = UndefinedType._singleton
41 """Help to make a DeferredDeprecatedAlias."""
63 __getattr__ = partial(check_if_deprecated_constant, module_globals=globals())
65 dir_with_deprecated_constants, module_globals_keys=[*globals().keys()]
list[str] all_with_deprecated_constants(dict[str, Any] module_globals)
DeferredDeprecatedAlias _deprecated_typing_helper(str attr)