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,11 +2,11 @@
from __future__ import annotations
from collections.abc import Generator
import contextlib
import logging
from pywemo.exceptions import ActionException
from typing_extensions import Generator
from homeassistant.helpers.device_registry import DeviceInfo
from homeassistant.helpers.update_coordinator import CoordinatorEntity
@ -65,7 +65,7 @@ class WemoEntity(CoordinatorEntity[DeviceCoordinator]):
return self._device_info
@contextlib.contextmanager
def _wemo_call_wrapper(self, message: str) -> Generator[None, None, None]:
def _wemo_call_wrapper(self, message: str) -> Generator[None]:
"""Wrap calls to the device that change its state.
1. Takes care of making available=False when communications with the