From 692af245daced9798aa178393ade4108011520f9 Mon Sep 17 00:00:00 2001 From: starkillerOG Date: Mon, 9 Dec 2024 16:22:05 +0100 Subject: [PATCH] Also set connect and sock_connect timeouts --- reolink_aio/api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/reolink_aio/api.py b/reolink_aio/api.py index 07a42bb..954570e 100644 --- a/reolink_aio/api.py +++ b/reolink_aio/api.py @@ -170,7 +170,7 @@ def __init__( self._token: Optional[str] = None self._lease_time: Optional[datetime] = None # Connection session - self._timeout: aiohttp.ClientTimeout = aiohttp.ClientTimeout(total=timeout) + self._timeout: aiohttp.ClientTimeout = aiohttp.ClientTimeout(total=timeout, connect=timeout, sock_connect=timeout) self._aiohttp_session_internall: bool = True if aiohttp_get_session_callback is not None: self._get_aiohttp_session = aiohttp_get_session_callback