Fix missing exception handling from upstream lib in Fritz (#62617)
* Fix missing exception handling from upstream lib * isort
This commit is contained in:
parent
d1c0e60bf1
commit
51a49f3d39
1 changed files with 2 additions and 1 deletions
|
@ -3,6 +3,7 @@ import logging
|
|||
|
||||
from fritzconnection.core.exceptions import FritzConnectionException, FritzSecurityError
|
||||
from fritzconnection.core.logger import fritzlogger
|
||||
from requests import exceptions
|
||||
|
||||
from homeassistant.config_entries import ConfigEntry
|
||||
from homeassistant.const import CONF_HOST, CONF_PASSWORD, CONF_PORT, CONF_USERNAME
|
||||
|
@ -38,7 +39,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
|||
await fritz_tools.async_setup(entry.options)
|
||||
except FritzSecurityError as ex:
|
||||
raise ConfigEntryAuthFailed from ex
|
||||
except FritzConnectionException as ex:
|
||||
except (FritzConnectionException, exceptions.ConnectionError) as ex:
|
||||
raise ConfigEntryNotReady from ex
|
||||
|
||||
hass.data.setdefault(DOMAIN, {})
|
||||
|
|
Loading…
Add table
Reference in a new issue