diff --git a/custom_components/hacs/base.py b/custom_components/hacs/base.py index 05de8bb5d41..9959c21f030 100644 --- a/custom_components/hacs/base.py +++ b/custom_components/hacs/base.py @@ -592,10 +592,18 @@ async def async_download_file(self, url: str) -> bytes | None: raise HacsException( f"Got status code {request.status} when trying to download {url}" ) + except asyncio.TimeoutError: + self.log.error( + "A timeout of 60! seconds was encountered while downloading %s, " + "check the network on the host running Home Assistant", + url, + ) + return None except BaseException as exception: # lgtm [py/catch-base-exception] pylint: disable=broad-except self.log.debug("Download failed - %s", exception) tries_left -= 1 await asyncio.sleep(1) continue + self.log.error("Download from %s failed", url) return None diff --git a/custom_components/hacs/system_health.py b/custom_components/hacs/system_health.py index 4a85d6cfee2..af970467760 100644 --- a/custom_components/hacs/system_health.py +++ b/custom_components/hacs/system_health.py @@ -23,7 +23,13 @@ async def system_health_info(hass): data = { "GitHub API": system_health.async_check_can_reach_url(hass, BASE_API_URL, GITHUB_STATUS), - "Github API Calls Remaining": response.data.resources.core.remaining, + "GitHub Content": system_health.async_check_can_reach_url( + hass, "https://raw.githubusercontent.com/hacs/integration/main/hacs.json" + ), + "GitHub Web": system_health.async_check_can_reach_url( + hass, "https://github.com/", GITHUB_STATUS + ), + "GitHub API Calls Remaining": response.data.resources.core.remaining, "Installed Version": hacs.version, "Stage": hacs.stage, "Available Repositories": len(hacs.repositories.list_all),