From faee82fdcad9fd2963a8080573e9b5315697dac7 Mon Sep 17 00:00:00 2001 From: zmax <> Date: Thu, 8 Jun 2023 15:47:02 +0200 Subject: [PATCH] Fix a source of the 'Unknown API error.' Since November 2020 the parameter 'strict' was removed from urllib3 HTTPSConnectionPool and HTTPConnectionPool classes' init in connectionpool.py. Leaving the parameter 'strict' in the call is shifting the next ones and timeout is taken as a boolean leading to the error 'Timeout cannot be a boolean, it must be an...' raising an UnknownConnectionError in api.py and finally the famous UnknowAPIError in the cli_wrapper.py. This explains why so many people have their proton cli not working after updating their packages with urllib3 among them. --- proton/cert_pinning.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/proton/cert_pinning.py b/proton/cert_pinning.py index e39298b..b33b9ec 100644 --- a/proton/cert_pinning.py +++ b/proton/cert_pinning.py @@ -44,7 +44,6 @@ def __init__( super(TLSPinningHTTPSConnectionPool, self).__init__( host, port, - strict, timeout, maxsize, block, @@ -67,7 +66,6 @@ def __init__( super(TLSPinningHTTPSConnectionPool, self).__init__( host, port, - strict, timeout, maxsize, block,