Add 0.05s to connection timeout

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.
This commit is contained in:
Joshua Boniface 2021-11-08 03:11:41 -05:00
parent e7d7378bae
commit 135d28e60b
1 changed files with 1 additions and 1 deletions

View File

@ -125,7 +125,7 @@ def call_api(
files=None, files=None,
): ):
# Set the connect timeout to 3 seconds but extremely long (48 hour) data timeout # Set the connect timeout to 3 seconds but extremely long (48 hour) data timeout
timeout = (3, 172800) timeout = (3.05, 172800)
# Craft the URI # Craft the URI
uri = "{}://{}{}{}".format( uri = "{}://{}{}{}".format(