Repository navigation
Description
Context
packages/ui-react/tests/browser/hygiene-media.layout.tsx:211 ("stale at apply re-previews with a focused banner; the commit waits for the current preview") failed in hosted CI for an unrelated change. It came to main with #3594 (epic #1777, sub-PR #3592).
Observed: ready-candidate proof for #3653, run 42228513642, job layout (1) (127928485126). The checkout was 491095f1b, with parents main 75ca2730c and head e3b92f202.
light 320andlight 1280failed after about 31.6 s each, so they hit the 30 s test timeout.dark 320anddark 1280passed in under 0.8 s in the same run, as did the other 33 tests in the file.- The log has no failure-detail block for the two tests. The run reported an unhandled rejection,
TypeError: fetch failedcaused byHeadersTimeoutError(UND_ERR_HEADERS_TIMEOUT). Undici's default headers timeout is 300 s, so some Node-side request apparently got no response for minutes. The test's fixture calls (set,packages/ui-react/tests/browser/hygiene-media.layout.tsx:47) are one candidate, not established. - refactor: land epic #2539 batch 2 — policy proposals split frontmatter with the shared helper (#2507) #3653 changes only
packages/ui-server/src/brain/policy-proposal.tsand the frontmatter lint gate. The hygiene fixture uses neither.
Passing runs of the same test:
- the CONTRACT: feat: land epic #1777 batch — review media findings with previews and the five actions (#2782) #3594 ready proof (run 42184487477), and main CI on
75ca2730c(run 42187644941); - two local runs of the whole file on
e3b92f202(37/37 each), on the pinned Chromium 1243 host recipe.
The test turns on holdPlans with applyMode: "stale" (packages/ui-react/tests/fixtures/hygiene-browser-server.ts:226-230, released at :526). It then waits for the banner, focus and checking, and releases the held plans.
It blocks the epic batches landing on main. #3653 is waiting on this fix and was not rerun.
Scope
- Find why this test can hang until the test timeout.
- Make it deterministic, in the test, the fixture or the component, whichever is wrong.
Out of scope
- Changing what the card does on a stale apply, unless the hang is a product bug.
- Other tests in the file.
- Raising the 30 s test timeout to hide a hang.
Acceptance criteria
- The cause of the hang is named, with evidence: the step that waited and the request that never answered.
- The fix removes the cause. A timeout increase alone does not count.
- A failing-first or mutation receipt shows the test can still fail on the stale-banner and commit-waits assertions.
-
hygiene-media.layout.tsxpasses in a hostedlayoutjob on the fix's head.
Verification
Run the file repeatedly with the pinned Chromium host recipe, and in the hosted layout shard that holds it.
Contract impact
None.
Activity
schlessera commentedon Nov 6, 2026
Claimed (claim token
c3657-t3-510f). Branchtest/3657-stale-apply-hangfrom main75ca2730c. No path collisions with open PRs on the test file or its fixture.fix(ui-react): focus the stale-apply banner after it renders (#3659)
schlessera commentedon Nov 6, 2026
Fixed by #3659, squash-merged as
501e93e21(milestone 0.45.0).bannerRefwas null and focus stayed on the destination input. The banner-focus poll failed in about 1 s.holdPlans).afterEach→stopdrains every forwarded route before it sends SIGTERM, and only SIGTERM releases the holds. The drain therefore waited on that request until Node's 300 sHeadersTimeoutError, and the test was reported as a 30 s timeout with no detail.stop.layout (1)in candidate run 42242569817 passed all fourstale at applyvariants.