Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

tornado: Replace deprecated urllib3 method_whitelist.

Anders Kaseorg18aa4f4df44a
diff --git a/zerver/tornado/django_api.py b/zerver/tornado/django_api.py
index ae03a2f9d5f..e0ed3a946c5 100644
--- a/zerver/tornado/django_api.py
+++ b/zerver/tornado/django_api.py
@@ -18,8 +18,8 @@ class TornadoAdapter(HTTPAdapter):
def __init__(self) -> None:
# All of the POST requests we make to Tornado are safe to
# retry; allow retries of them, which is not the default.
- retry_methods = Retry.DEFAULT_METHOD_WHITELIST | {"POST"}
- retry = Retry(total=3, backoff_factor=1, method_whitelist=retry_methods)
+ retry_methods = Retry.DEFAULT_ALLOWED_METHODS | {"POST"}
+ retry = Retry(total=3, backoff_factor=1, allowed_methods=retry_methods)
super().__init__(max_retries=retry)
def send(