Import Generator from typing_extensions (1) (#118986)

This commit is contained in:
Marc Mueller 2024-06-06 17:02:13 +02:00 committed by GitHub
parent 69708db8e0
commit fe21e2b8ba
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
34 changed files with 134 additions and 118 deletions

View file

@ -2,13 +2,14 @@
from __future__ import annotations
from collections.abc import Callable, Generator
from collections.abc import Callable
from typing import TYPE_CHECKING, Any
from aiohomekit.model.characteristics import CharacteristicsTypes
from aiohomekit.model.characteristics.const import InputEventValues
from aiohomekit.model.services import Service, ServicesTypes
from aiohomekit.utils import clamp_enum_to_char
from typing_extensions import Generator
import voluptuous as vol
from homeassistant.components.device_automation import DEVICE_TRIGGER_BASE_SCHEMA
@ -88,7 +89,7 @@ class TriggerSource:
for event_handler in self._callbacks.get(trigger_key, []):
event_handler(ev)
def async_get_triggers(self) -> Generator[tuple[str, str], None, None]:
def async_get_triggers(self) -> Generator[tuple[str, str]]:
"""List device triggers for HomeKit devices."""
yield from self._triggers