From c33d31996d55adbeb6f951ef20ec77c7c5e7212b Mon Sep 17 00:00:00 2001 From: Pascal Vizeli Date: Thu, 13 Feb 2020 17:25:37 +0100 Subject: [PATCH] Set timeout of 10min for download OTA (#1505) --- hassio/hassos.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hassio/hassos.py b/hassio/hassos.py index f2401450e..1e3b110c5 100644 --- a/hassio/hassos.py +++ b/hassio/hassos.py @@ -84,9 +84,10 @@ class HassOS(CoreSysAttributes): url = URL_HASSOS_OTA.format(version=version, board=self.board) raucb = Path(self.sys_config.path_tmp, f"hassos-{version}.raucb") + _LOGGER.info("Fetch OTA update from %s", url) try: - _LOGGER.info("Fetch OTA update from %s", url) - async with self.sys_websession.get(url) as request: + timeout = aiohttp.ClientTimeout(total=600) + async with self.sys_websession.get(url, timeout=timeout) as request: if request.status != 200: raise HassOSUpdateError()