Retry tibber setup (#81785)
* Handle integration setup retries * Fix black error * Update to falsy check Co-authored-by: Martin Hjelmare <marhje52@gmail.com> * Remove duplicated log * Update exception message Co-authored-by: Martin Hjelmare <marhje52@gmail.com> Co-authored-by: Martin Hjelmare <marhje52@gmail.com>pull/81780/head
parent
59ec829106
commit
7ab2029071
|
@ -53,6 +53,9 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
|||
|
||||
try:
|
||||
await tibber_connection.update_info()
|
||||
if not tibber_connection.name:
|
||||
raise ConfigEntryNotReady("Could not fetch Tibber data.")
|
||||
|
||||
except asyncio.TimeoutError as err:
|
||||
raise ConfigEntryNotReady from err
|
||||
except aiohttp.ClientError as err:
|
||||
|
|
Loading…
Reference in New Issue