diff --git a/kopf/_kits/webhooks.py b/kopf/_kits/webhooks.py index 0884fad0..5c165b52 100644 --- a/kopf/_kits/webhooks.py +++ b/kopf/_kits/webhooks.py @@ -165,7 +165,8 @@ async def _serve_fn(request: aiohttp.web.Request) -> aiohttp.web.Response: # multi-threaded sockets are not really used -- high load is not expected for webhooks. addr = self.addr or None # None is aiohttp's "any interface" port = self.port or self._allocate_free_port() - site = aiohttp.web.TCPSite(runner, addr, port, ssl_context=context, reuse_port=True) + site = aiohttp.web.TCPSite(runner, addr, port, ssl_context=context, reuse_port=True, + shutdown_timeout=0.0001) await site.start() # Log with the actual URL: normalised, with hostname/port set. diff --git a/setup.py b/setup.py index 5533d6b2..245a1299 100644 --- a/setup.py +++ b/setup.py @@ -62,7 +62,7 @@ 'python-json-logger', # 0.05 MB 'iso8601', # 0.07 MB 'click', # 0.60 MB - 'aiohttp<4.0.0', # 7.80 MB + 'aiohttp==3.9.0b0', # 7.80 MB 'pyyaml', # 0.90 MB ], extras_require={