Update black to 23.1.0 (#87188)

This commit is contained in:
Franck Nijhof 2023-02-02 18:35:24 +01:00 committed by GitHub
parent f7666239ff
commit 5e81d28116
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
312 changed files with 299 additions and 475 deletions

View file

@ -79,10 +79,12 @@ async def async_setup_platform(
)
def catch_request_errors() -> Callable[
[Callable[Concatenate[_OpenhomeDeviceT, _P], Awaitable[_R]]],
Callable[Concatenate[_OpenhomeDeviceT, _P], Coroutine[Any, Any, _R | None]],
]:
def catch_request_errors() -> (
Callable[
[Callable[Concatenate[_OpenhomeDeviceT, _P], Awaitable[_R]]],
Callable[Concatenate[_OpenhomeDeviceT, _P], Coroutine[Any, Any, _R | None]],
]
):
"""Catch asyncio.TimeoutError, aiohttp.ClientError, UpnpError errors."""
def call_wrapper(
@ -265,7 +267,7 @@ class OpenhomeDevice(MediaPlayerEntity):
await self._device.invoke_pin(pin)
else:
_LOGGER.error("Pins service not supported")
except (UpnpError):
except UpnpError:
_LOGGER.error("Error invoking pin %s", pin)
@property