The Fix
pip install urllib3==1.25.11
Based on closed urllib3/urllib3 issue #1916 · PR/commit linked
Production note: Most teams hit this during upgrades or environment changes. Roll out with a canary and smoke critical endpoints (health, OpenAPI/docs) before 100%.
@@ -14,5 +14,4 @@ but can also be used independently.
.. automodule:: urllib3.util
:members:
- :undoc-members:
:show-inheritance:
diff --git a/src/urllib3/util/retry.py b/src/urllib3/util/retry.py
Option A — Upgrade to fixed release\npip install urllib3==1.25.11\nWhen NOT to use: This fix is not applicable if the existing parameter names are required for backward compatibility.\n\n
Why This Fix Works in Production
- Trigger: I'd already set my mind to doing this before this issue was raised. Unless another collaborator objects we'll be making this change.
- Mechanism: The parameters 'method_whitelist' and 'DEFAULT_REDIRECT_HEADERS_BLACKLIST' in the Retry module had slavery connotations
- Why the fix works: Renamed the parameters 'method_whitelist' and 'DEFAULT_REDIRECT_HEADERS_BLACKLIST' in the Retry module to neutral terms to avoid slavery connotations. (first fixed release: 1.25.11).
- If left unfixed, the same config can fail only in production (env differences), causing startup failures or partial feature outages.
Why This Breaks in Prod
- The parameters 'method_whitelist' and 'DEFAULT_REDIRECT_HEADERS_BLACKLIST' in the Retry module had slavery connotations
- Production symptom (often without a traceback): I'd already set my mind to doing this before this issue was raised. Unless another collaborator objects we'll be making this change.
Proof / Evidence
- GitHub issue: #1916
- Fix PR: https://github.com/urllib3/urllib3/pull/2000
- First fixed release: 1.25.11
- Reproduced locally: No (not executed)
- Last verified: 2026-02-09
- Confidence: 0.95
- Did this fix it?: Yes (upstream fix exists)
- Own content ratio: 0.78
Discussion
High-signal excerpts from the issue thread (symptoms, repros, edge-cases).
“Yep, this is on my to-do list. Gotta jump through a few hoops to make it backwards compatible but also not appear in the documentation.”
“I'd already set my mind to doing this before this issue was raised. Unless another collaborator objects we'll be making this change.”
“Black is associated with evil in many cultures simply because black is the color of darkness, and in the dark you can not see anything,…”
Failure Signature (Search String)
- I'd already set my mind to doing this before this issue was raised. Unless another collaborator objects we'll be making this change.
Copy-friendly signature
Failure Signature
-----------------
I'd already set my mind to doing this before this issue was raised. Unless another collaborator objects we'll be making this change.
Error Message
Signature-only (no traceback captured)
Error Message
-------------
I'd already set my mind to doing this before this issue was raised. Unless another collaborator objects we'll be making this change.
What Broke
No production failures reported; change is for terminology improvement.
Why It Broke
The parameters 'method_whitelist' and 'DEFAULT_REDIRECT_HEADERS_BLACKLIST' in the Retry module had slavery connotations
Fix Options (Details)
Option A — Upgrade to fixed release Safe default (recommended)
pip install urllib3==1.25.11
Use when you can deploy the upstream fix. It is usually lower-risk than long-lived workarounds.
Fix reference: https://github.com/urllib3/urllib3/pull/2000
First fixed release: 1.25.11
Last verified: 2026-02-09. Validate in your environment.
When NOT to Use This Fix
- This fix is not applicable if the existing parameter names are required for backward compatibility.
Did This Fix Work in Your Case?
Quick signal helps us prioritize which fixes to verify and improve.
Prevention
- Add a CI check that diffs key outputs after upgrades (OpenAPI schema snapshots, JSON payload shapes, CLI output).
- Upgrade behind a canary and run integration tests against the canary before 100% rollout.
Version Compatibility Table
| Version | Status |
|---|---|
| 1.25.11 | Fixed |
Related Issues
No related fixes found.
Sources
We don’t republish the full GitHub discussion text. Use the links above for context.