Repository navigation
fix(engine): asset downloads stay on HTTP/1.1 under undici 8, as they do on undici 7 - #9084
Open
miguel-heygen wants to merge 1 commit into
Open
miguel-heygen wants to merge 1 commit into
miguel-heygen wants to merge 1 commit into
Conversation
jrusso1020
approved these changes
Nov 29, 2026
jrusso1020
left a comment
Collaborator
There was a problem hiding this comment.
Reviewed at dab3b57. Both files read; urlDownloader.ts around the two dispatchers read whole, the test file as hunks plus the surrounding describe block. Nothing was run.
What I checked:
- The change is one option on each of the two download dispatchers (the direct
Agentand the capture proxy'sProxyAgent). A search ofpackages/finds no other dispatcher construction outside tests, so no download path is left offering HTTP/2. - The proxy's
Poolfactory still spreads the options it is given and only wrapsconnect, so the dropped-tunnel handling is unchanged. - The new test stands up an origin that accepts both protocols behind the same tunnel proxy, adds its name to the test certificate, and asserts the origin saw exactly one request on 1.1. Teardown closes the new server.
- Body has the
fails without the fix:line and says plainly that the test only goes red on undici 8; on the 7.30.1 pinned here it passes either way.
Notes, not blocking:
- Until this repo moves to undici 8, CI here does not prove the two lines are needed. The test becomes the guard on the day of that upgrade, which is the stated purpose.
- The direct (no proxy) path is not driven by a test, as the body says. Same one-word change.
Need: yes · Size: +27 −4, minimal · Reuse: extends the existing proxy test fixture · Simpler: no · Structure: fine
Risk: low; no wire change on the pinned undici.
— Rames
miguel-heygen
enabled auto-merge
November 29, 2026 10:31
Contributor
Edit accuracy: accurate 275 (base branch 273), smooth 72 of thoseThe gate passes. Newly passing (2)
Not banked yet, reported and not gated (bank a full-grid run's baseline.json) (2)
Quarantined, measured but not gated (0) |
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Nov 29, 2026
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Nov 29, 2026
2 of 4 tasks
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes for people
Asset downloads keep speaking HTTP/1.1, through a tunnel when a capture proxy is set, even when the engine runs with undici 8. undici 8 offers HTTP/2 by default; undici 7, which this repo pins, does not. Today nothing changes on the wire. An app that runs the engine with undici 8 (HyperFrames Desktop's render server does, for undici 8's fix of a crash on slowly read downloads) no longer needs to patch the engine to keep the same protocol, and a later undici 8 upgrade here cannot move downloads to HTTP/2 without anyone noticing.
How
allowH2: falseon the two download dispatchers inpackages/engine/src/utils/urlDownloader.ts: the directAgentand the capture proxy'sProxyAgent.Tests
urlDownloader.restrictedNetwork.test.ts: through the capture proxy, against an origin that speaks both HTTP/2 and HTTP/1.1, the download completes and the origin sees HTTP/1.1.urlDownloader.restrictedNetwork.test.ts"stays on HTTP/1.1 through the proxy when the origin also speaks HTTP/2", when the engine runs on undici 8.13.0. On this repo's undici 7.30.1 it passes with or without the change, since undici 7 never offers HTTP/2. Run on a Linux machine with undici 8.13.0 swapped into the install: fails on main's downloader, passes here.tsc --noEmitis clean.