From b0387efee3a84ae9677370fe1f84f3caf9303f6f Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Fri, 14 Jan 2022 14:32:07 -0800 Subject: [PATCH] Guard for timeout errors during wled discovery (#64130) --- homeassistant/components/wled/config_flow.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/homeassistant/components/wled/config_flow.py b/homeassistant/components/wled/config_flow.py index 5542e8d0848b..3665a6304cf5 100644 --- a/homeassistant/components/wled/config_flow.py +++ b/homeassistant/components/wled/config_flow.py @@ -1,6 +1,7 @@ """Config flow to configure the WLED integration.""" from __future__ import annotations +import asyncio from typing import Any import voluptuous as vol @@ -74,7 +75,7 @@ async def async_step_zeroconf( self.discovered_host = discovery_info.host try: self.discovered_device = await self._async_get_device(discovery_info.host) - except WLEDConnectionError: + except (WLEDConnectionError, asyncio.TimeoutError): return self.async_abort(reason="cannot_connect") await self.async_set_unique_id(self.discovered_device.info.mac_address)