You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
flaky(e2e): prompt-rail:370 re-reads the rail after the poll that settled it #4675
The Desktop E2E test manual transcript scrolling keeps exactly the visible prompt current (apps/desktop/e2e/prompt-rail.spec.ts:370) fails intermittently on CI, at the first expectPromptRailMatchesReadingPosition(page) call, before the scroll it is about has happened.
The helper (prompt-rail.spec.ts:191-207) polls until one current tick maps from the Turn being read, then takes a fresh snapshot and asserts it again without polling:
awaitexpect.poll(async()=>{lastSnapshot=awaitactivePromptRailSnapshot(page);returnlastSnapshot.expectedId!==null&&lastSnapshot.currentIds.length===1&&lastSnapshot.currentIds[0]===lastSnapshot.expectedId;}).toBe(true);constsnapshot=awaitactivePromptRailSnapshot(page);expect(snapshot.expectedId).not.toBeNull();expect(snapshot.currentIds).toEqual([snapshot.expectedId]);// <- fails here
Observed on CI:
Error: expect(received).toEqual(expected) // deep equality
Array [
- "turn-prompt-rail-119",
+ "turn-prompt-rail-120",
]
at apps/desktop/e2e/prompt-rail.spec.ts:206
The poll passes on a frame where the rail and the reading position agree, and the second snapshot, taken a round trip later, sees the rail one tick further along because the transcript is still settling after scrollTranscriptTo(page, 'bottom'). The second read cannot fail on a settled page, so it only adds a way to fail on an unsettled one. Either the poll's own snapshot should be the one asserted, or the poll should require two consecutive identical snapshots.
How to reproduce
Intermittent; only seen under CI load (Desktop E2E, 4 workers on Xvfb).
The test and the helper were both added in #4417 (merged 2026-09-03 08:44 UTC, closing #4415). The first failure is the main run started eight minutes later (afe06f2, 08:52), so this has flaked since it landed: it is in 2 of the 9 red main CI runs among the last 60, plus one PR run, all within nine hours of merging. #4415 is closed and nothing tracks the test itself. #3863 and #4577 settled other timing in this spec; this read is not covered by either.
#4741 removed prompt-rail.spec.ts in full — 22 tests across it and transcript-scroll.spec.ts, which together held four of the five open flake reports. They assert scroll geometry against a compositor that settles on its own schedule: that needs a real layout engine, not Electron, and under four-worker Xvfb load the suite read a scroller mid-settle and blocked changes that never touched scrolling.
Coverage was deleted, not moved. The rebuild belongs one tier down — Storybook + Chromium for geometry — and is being worked out in #4727. retries: 0 is unchanged.
Reopening is the right call if the rebuild lands somewhere this report still applies to.
Activity
Adarsh-Me commentedon Sep 3, 2026
/assign me
Astro-Han commentedon Sep 3, 2026
you can use
takecommand!Adarsh-Me commentedon Sep 3, 2026
/take
Astro-Han commentedon Sep 3, 2026
I've assigned mannually, a vanilla
takecommand would do the trick, no slash is needed~test(desktop): settle the prompt rail across two consecutive reads (a…
test(desktop): settle the prompt rail across painted frames (apache#4675
test(desktop): settle the prompt rail across painted frames (apache#4675
test(desktop): settle the prompt rail across painted frames (apache#4675
test(desktop): gate the prompt rail on painted-frame quiescence (apac…
test(desktop): pass the rail settle loop as a function, not source (a…
test(desktop): remove the layout-tier E2E specs that block main (#4741)
Astro-Han commentedon Sep 4, 2026
Closing: the test this reports no longer exists.
#4741 removed
prompt-rail.spec.tsin full — 22 tests across it andtranscript-scroll.spec.ts, which together held four of the five open flake reports. They assert scroll geometry against a compositor that settles on its own schedule: that needs a real layout engine, not Electron, and under four-worker Xvfb load the suite read a scroller mid-settle and blocked changes that never touched scrolling.Coverage was deleted, not moved. The rebuild belongs one tier down — Storybook + Chromium for geometry — and is being worked out in #4727.
retries: 0is unchanged.Reopening is the right call if the rebuild lands somewhere this report still applies to.