mirror of
https://github.com/home-assistant/core.git
synced 2025-11-12 04:20:17 +00:00
Use PEP 695 for simple type aliases (#117633)
This commit is contained in:
@@ -57,9 +57,9 @@ BLE_AVAILABILITY_CHECK_INTERVAL = 1800 # seconds
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
AddAccessoryCb = Callable[[Accessory], bool]
|
||||
AddServiceCb = Callable[[Service], bool]
|
||||
AddCharacteristicCb = Callable[[Characteristic], bool]
|
||||
type AddAccessoryCb = Callable[[Accessory], bool]
|
||||
type AddServiceCb = Callable[[Service], bool]
|
||||
type AddCharacteristicCb = Callable[[Characteristic], bool]
|
||||
|
||||
|
||||
def valid_serial_number(serial: str) -> bool:
|
||||
|
||||
@@ -12,7 +12,7 @@ from homeassistant.core import Event, HomeAssistant
|
||||
from .const import CONTROLLER
|
||||
from .storage import async_get_entity_storage
|
||||
|
||||
IidTuple = tuple[int, int | None, int | None]
|
||||
type IidTuple = tuple[int, int | None, int | None]
|
||||
|
||||
|
||||
def unique_id_to_iids(unique_id: str) -> IidTuple | None:
|
||||
|
||||
Reference in New Issue
Block a user