From e3122ec6dc61c2e854d917f22208e67a983d99ba Mon Sep 17 00:00:00 2001 From: starkillerOG Date: Fri, 13 Oct 2023 10:23:32 +0200 Subject: [PATCH] Uncancel task when swallowing CancelledError (#101884) --- homeassistant/components/reolink/__init__.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/homeassistant/components/reolink/__init__.py b/homeassistant/components/reolink/__init__.py index 5cfb2ceecb7415..fd62f8451fbf90 100644 --- a/homeassistant/components/reolink/__init__.py +++ b/homeassistant/components/reolink/__init__.py @@ -95,6 +95,9 @@ async def async_check_firmware_update() -> str | Literal[False]: try: return await host.api.check_new_firmware() except (ReolinkError, asyncio.exceptions.CancelledError) as err: + task = asyncio.current_task() + if task is not None: + task.uncancel() if starting: _LOGGER.debug( "Error checking Reolink firmware update at startup "