From d04dbdaebb00e32d64210bf2d274f942ae7b6bdf Mon Sep 17 00:00:00 2001 From: Mattwmaster58 Date: Sat, 8 Sep 2018 10:50:56 -0600 Subject: [PATCH] Change ambiguous description of backoff_factor Change from `^` to `**`. Programmers not familiar with python might assume the ^ is the exponent operator, when in fact it is the bitwise XOR operator. This change will remove the ambiguity. --- src/urllib3/util/retry.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/urllib3/util/retry.py b/src/urllib3/util/retry.py index 7ad3dc6608..e7d0abd610 100644 --- a/src/urllib3/util/retry.py +++ b/src/urllib3/util/retry.py @@ -115,7 +115,7 @@ class Retry(object): (most errors are resolved immediately by a second try without a delay). urllib3 will sleep for:: - {backoff factor} * (2 ^ ({number of total retries} - 1)) + {backoff factor} * (2 ** ({number of total retries} - 1)) seconds. If the backoff_factor is 0.1, then :func:`.sleep` will sleep for [0.0s, 0.2s, 0.4s, ...] between retries. It will never be longer