summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLemon Shi <shir@vmware.com>2022-01-22 11:40:38 +0000
committerAsif Saif Uddin <auvipy@gmail.com>2022-01-22 18:10:19 +0600
commit5bed2a8f983a3bf61c12443e7704ffd89991ef9a (patch)
tree5116b107c78152634b15358dff0967c04e5a8cee
parenta7355ac4424ae0c90f8bd828705e0fea5d24629a (diff)
downloadkombu-master.tar.gz
The times of retrying is not correctmaster
The times of retrying was 'max_retries' plus 1 which is fixed now.
-rw-r--r--kombu/connection.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/kombu/connection.py b/kombu/connection.py
index 4b2cbd62..3ad84645 100644
--- a/kombu/connection.py
+++ b/kombu/connection.py
@@ -529,7 +529,7 @@ class Connection:
# the error if it persists after a new connection
# was successfully established.
raise
- if max_retries is not None and retries > max_retries:
+ if max_retries is not None and retries >= max_retries:
raise
self._debug('ensure connection error: %r',
exc, exc_info=1)