From 5376e4c042029450a93234bef4e9ef6d9bff043f Mon Sep 17 00:00:00 2001 From: rlaphoenix Date: Tue, 12 Mar 2024 00:59:30 +0000 Subject: [PATCH] refactor(Service): Go back to the default pool_maxsize in Session The pool_maxsize value here isn't actually doing much. It should have also been applied to pool_connections. What we realistically needed was just pool_block to prevent opening too much connections (causing a warning). The default pool_connections=10 and pool_maxsize=10 is fine. The downloader doesn't currently use this value. --- devine/core/service.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/devine/core/service.py b/devine/core/service.py index 40480d5..3619fae 100644 --- a/devine/core/service.py +++ b/devine/core/service.py @@ -98,9 +98,6 @@ class Service(metaclass=ABCMeta): backoff_factor=0.2, status_forcelist=[429, 500, 502, 503, 504] ), - # 16 connections is used for byte-ranged downloads - # double it to allow for 16 non-related connections - pool_maxsize=16 * 2, pool_block=True )) session.mount("http://", session.adapters["https://"])