Skip to content

RAL-190: the board-ages browser test waits for the board's first draw - #277

Merged
Castor-o7 merged 3 commits into
mainfrom
ral-ages-flake
Nov 14, 2026
Merged

Castor-o7 merged 3 commits into
mainfrom
ral-ages-flake

Conversation

@Castor-o7

Copy link
Copy Markdown
Owner

RAL-190, from the watchman: the one-off hosted failure on #275 (before: []).

Cause: the board draws from the page's own /api/status fetch, which the load event sign-in.mjs waits on does not wait for. The margin on Murph is about 20 ms. Reproduced by holding the page's first /api/status for 600 ms via CDP Fetch (local only).

Product right, test raced: the harness now waits before any probe for the first draw (drawnAt) or the page's warning, and reports firstDraw. The ages test asserts "drawn". It passes with 600 ms and 3 s holds.

🤖 Generated with Claude Code

Castor-o7 and others added 3 commits November 14, 2026 12:54
Hosted `check` on PR #275 failed once at
the_board_keeps_its_ages_current_and_shows_commits_short: its probe read
`before: []`, then five ages 2.5 s later, with "updated 2s ago".

The cause: the board draws from the page's own fetch of /api/status, and
the load event that sign-in.mjs waits on doesn't wait for that fetch. On
Murph the first draw beat the probe by about 20 ms (measured: drawn at
~45 ms, probe at ~65 ms), and on a loaded runner it lost. Holding the
page's first /api/status for 600 ms through CDP's Fetch domain (a local
change, not committed) reproduced the failure exactly; load alone on Murph
didn't in 42 runs.

The product is right: a board can't show ages before it has read any, and
it shows them as soon as it has. The test raced it, so the fix is in the
harness, for every probe: before a probe, wait up to 20 s for the board's
first draw (`drawnAt`, set once `show` has drawn) or the page's own
warning, and report which as `firstDraw`. The ages test asserts "drawn".
With the 600 ms and 3 s holds it now passes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts:
#	tests/browser/sign-in.mjs
@Castor-o7
Castor-o7 merged commit 7266432 into main Nov 14, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant