mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 20:57:21 +00:00
Pydeconz raise ResponseError when deCONZ Rest API Plugin is not yet ready (#71078)
This commit is contained in:
parent
b657a7d68b
commit
cc174022e4
@ -289,6 +289,6 @@ async def get_deconz_session(
|
||||
LOGGER.warning("Invalid key for deCONZ at %s", config[CONF_HOST])
|
||||
raise AuthenticationRequired from err
|
||||
|
||||
except (asyncio.TimeoutError, errors.RequestError) as err:
|
||||
except (asyncio.TimeoutError, errors.RequestError, errors.ResponseError) as err:
|
||||
LOGGER.error("Error connecting to deCONZ gateway at %s", config[CONF_HOST])
|
||||
raise CannotConnect from err
|
||||
|
@ -286,6 +286,7 @@ async def test_get_deconz_session(hass):
|
||||
[
|
||||
(asyncio.TimeoutError, CannotConnect),
|
||||
(pydeconz.RequestError, CannotConnect),
|
||||
(pydeconz.ResponseError, CannotConnect),
|
||||
(pydeconz.Unauthorized, AuthenticationRequired),
|
||||
],
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user