diff --git a/homeassistant/components/apcupsd/config_flow.py b/homeassistant/components/apcupsd/config_flow.py index 57002d7a2b2..99c78fd5d33 100644 --- a/homeassistant/components/apcupsd/config_flow.py +++ b/homeassistant/components/apcupsd/config_flow.py @@ -52,9 +52,8 @@ class ConfigFlowHandler(ConfigFlow, domain=DOMAIN): # Test the connection to the host and get the current status for serial number. coordinator = APCUPSdCoordinator(self.hass, host, port) - await coordinator.async_request_refresh() - await self.hass.async_block_till_done() + if isinstance(coordinator.last_exception, (UpdateFailed, asyncio.TimeoutError)): errors = {"base": "cannot_connect"} return self.async_show_form(