mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-21 08:06:30 +00:00
Explicitly log when API requests timeout (#4861)
Currently a timeout leads to a log entry which simply states: "Error on call http://172.30.32.1:8123/api/core/state: ". From this, it is not immeaditly clear what the problem is. This commit adds a log entry which explicitly states that the request timed out.
This commit is contained in:
parent
7e20502379
commit
765265723c
@ -107,7 +107,10 @@ class HomeAssistantAPI(CoreSysAttributes):
|
||||
continue
|
||||
yield resp
|
||||
return
|
||||
except (TimeoutError, aiohttp.ClientError) as err:
|
||||
except TimeoutError:
|
||||
_LOGGER.error("Timeout on call %s.", url)
|
||||
break
|
||||
except aiohttp.ClientError as err:
|
||||
_LOGGER.error("Error on call %s: %s", url, err)
|
||||
break
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user