The Fix
pip install urllib3==2.2.0
Based on closed urllib3/urllib3 issue #2073 · PR/commit linked
Production note: Watch p95/p99 latency and retry volume; timeouts can turn into retry storms and duplicate side-effects.
@@ -0,0 +1,7 @@
@@ -0,0 +1,7 @@
+env:
+ es2020 : true
+ worker: true
import requests
import httpcore
# Use httpcore, for HTTP/2 support.
session = requests.Session(transport=httpcore.HTTPTransport(http2=True))
Re-run the minimal reproduction on your broken version, then apply the fix and re-run.
Option A — Upgrade to fixed release\npip install urllib3==2.2.0\nWhen NOT to use: This fix should not be used in non-Emscripten environments as it may lead to unexpected behavior.\n\n
Why This Fix Works in Production
- Trigger: There's also other areas of the ecosystem that it could impact. For example, a future version of `requests` could potentially add support for the transport…
- Mechanism: This PR adds native Emscripten support to urllib3, enabling streaming HTTP requests in cross-origin isolated environments
- Why the fix works: Adds native Emscripten support to urllib3, enabling streaming HTTP requests in cross-origin isolated environments. (first fixed release: 2.2.0).
- If left unfixed, tail latency can spike under load and surface as timeouts/retries (amplifying incident impact).
Why This Breaks in Prod
- Dependency interaction matters here: httpx v0.18.
- This PR adds native Emscripten support to urllib3, enabling streaming HTTP requests in cross-origin isolated environments
- Production symptom (often without a traceback): There's also other areas of the ecosystem that it could impact. For example, a future version of `requests` could potentially add support for the transport API, without requiring fundamental API changes or large internal refactoring...
Proof / Evidence
- GitHub issue: #2073
- Fix PR: https://github.com/urllib3/urllib3/pull/3195
- First fixed release: 2.2.0
- Reproduced locally: No (not executed)
- Last verified: 2026-02-09
- Confidence: 0.85
- Did this fix it?: Yes (upstream fix exists)
- Own content ratio: 0.71
Discussion
High-signal excerpts from the issue thread (symptoms, repros, edge-cases).
“I think the other thing, to @sethmlarson last point is we need someway of testing transports to ensure consistent behaviour not just consistent APIs. And…”
“> We should be using zope.interface as that can actually verify the contract is upheld Upholding the contract sounds potentially valuable, tho I probably wouldn't…”
“https://glyph.twistedmatrix.com/2009/02/explaining-why-interfaces-are-great.html is also a good post”
“On the one case, there's a way to verify the implementers are implementing the interface (zope.interface) and on the other we have ..”
Failure Signature (Search String)
- There's also other areas of the ecosystem that it could impact. For example, a future version of `requests` could potentially add support for the transport API, without requiring
- * Allow a point of extension for elements that don't fit into the core abstraction - timeout parameters, trailing HTTP headers, raw connections in response to CONNECT/Upgrade
Copy-friendly signature
Failure Signature
-----------------
There's also other areas of the ecosystem that it could impact. For example, a future version of `requests` could potentially add support for the transport API, without requiring fundamental API changes or large internal refactoring...
* Allow a point of extension for elements that don't fit into the core abstraction - timeout parameters, trailing HTTP headers, raw connections in response to CONNECT/Upgrade requests, HTTP/2 server push etc...
Error Message
Signature-only (no traceback captured)
Error Message
-------------
There's also other areas of the ecosystem that it could impact. For example, a future version of `requests` could potentially add support for the transport API, without requiring fundamental API changes or large internal refactoring...
* Allow a point of extension for elements that don't fit into the core abstraction - timeout parameters, trailing HTTP headers, raw connections in response to CONNECT/Upgrade requests, HTTP/2 server push etc...
Minimal Reproduction
import requests
import httpcore
# Use httpcore, for HTTP/2 support.
session = requests.Session(transport=httpcore.HTTPTransport(http2=True))
Environment
- httpx: 0.18
What Broke
Streaming HTTP requests failed in cross-origin isolated environments, causing functionality issues.
Why It Broke
This PR adds native Emscripten support to urllib3, enabling streaming HTTP requests in cross-origin isolated environments
Fix Options (Details)
Option A — Upgrade to fixed release Safe default (recommended)
pip install urllib3==2.2.0
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/3195
First fixed release: 2.2.0
Last verified: 2026-02-09. Validate in your environment.
When NOT to Use This Fix
- This fix should not be used in non-Emscripten environments as it may lead to unexpected behavior.
Verify Fix
Re-run the minimal reproduction on your broken version, then apply the fix and re-run.
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.
- Make timeouts explicit and test them (unit + integration) to avoid silent behavior changes.
- Instrument retries (attempt count + reason) and alert on spikes to catch dependency slowdowns.
Version Compatibility Table
| Version | Status |
|---|---|
| 2.2.0 | Fixed |
Related Issues
No related fixes found.
Sources
We don’t republish the full GitHub discussion text. Use the links above for context.