From be6a3992c1f5d0b62a246d4ba765cffa6ce6e307 Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Mon, 8 Nov 2021 03:11:41 -0500 Subject: [PATCH] Add 0.05s to connection timeout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is recommended by the Python Requests documentation: > It’s a good practice to set connect timeouts to slightly larger than a multiple of 3, which is the default TCP packet retransmission window. --- client-cli/pvc/cli_lib/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client-cli/pvc/cli_lib/common.py b/client-cli/pvc/cli_lib/common.py index 94117114..f72762d2 100644 --- a/client-cli/pvc/cli_lib/common.py +++ b/client-cli/pvc/cli_lib/common.py @@ -125,7 +125,7 @@ def call_api( files=None, ): # Set the connect timeout to 3 seconds but extremely long (48 hour) data timeout - timeout = (3, 172800) + timeout = (3.05, 172800) # Craft the URI uri = "{}://{}{}{}".format(