Repository navigation
test(e2e): wait for the slot read in spec 22 and fix every spec with that race - #38667
Conversation
First Principles Review (Opus 5.5) — ⏭️ skippedRevision |
UX Review (Opus 5.5) — ✅ PASSUX-level review of UX-Verdict: PASS Nothing to check. The diff only edits two docs files ( [UX-REVIEWED] 653855e Description read[DESCRIPTION-READ] c1f8472dab3b895123264d2a3c9896fd37d83f02916fa23272343e2ffec92c4c That sha256 names everything this verdict read: the PR description, plus the 3 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Docs-only change, nothing in it blocks; the description doesn't match the diff. Notes
[DESIGN-REVIEWED] 653855e Description read[DESCRIPTION-READ] d75537bac353f81c21a801f6ca3eafcccc2913861318bca5d424b7d7e570a93d That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
42923db to
653855e
Compare
Problem / Motivation
Goal: spec 22 of
website/playwright/session-tags-e2e.spec.tspasses on its first attempt, and the next Playwright spec that changes a slot aftergoto('/chat')waits for the page's own slot read before the change, so the race fixed in spec 8 does not come back a third time.The race fixed for spec 8 of
website/playwright/session-tags-e2e.spec.tscame back in spec 22 of the same file. Spec 22 drags a card withDragEvents instead of posting the drop overrequest, and the fix for spec 8 was applied to spec 8 only. Spec 22 then reddened the E2E job on unrelated PRs, for example run 44110067591, job 134138960142 on PR #38405:The page snapshot in that job's artifact still shows the card in ToDo with a ToDo chip, while the server poll just before had read
[done]. Tracked in issue #37561.Why it matters
Spec 22 reds the E2E job on PRs that do not touch the board. The spec change here is byte-for-byte the one in PR #38482, so whichever merges first, the other rebases cleanly. It is carried here because the documentation states the fix and its measurement, and that must stay true of the tree whatever the merge order. The docs then say why the race came back and what the author of the next such fix must do.
Not a goal
fetchSlots.fulfilled), which is product code.What changed (motivation -> approach -> change)
website/playwright/session-tags-e2e.spec.tsspec 22: registerspage.waitForResponsefor the page'sGET /api/chat/slotsbeforepage.gotoand awaits itsfinished()before the drag, the same wait spec 8 has. The drag, both assertions and their timeouts are unchanged.docs/system-specs/common/testing-conventions.md, § A Playwright spec that passed only on a retry, the "state from before an API write" case: says the spec 8 fix covered spec 8 only, that a row on screen is no barrier (the socket's connect snapshot renders it while the read is in flight), and that a fix for this shape fixes every test with it in the same change. It names the search (goto('/chat'), then a slot write, then a page assertion on that slot), gives a WRONG/RIGHT pair for the drag form, and the measured numbers below.website/docs/testing.md, § Rules every test keeps, Playwright: one bullet with the same rule (the file and its sibling specs), pointing at that section.Sibling sweep of
website/playwright/forgoto('/chat')followed by a slot write (/drop,/tags,/folder,DragEvent('drop')): specs 8 and 22 ofsession-tags-e2e.spec.tsassert the page after the write (8 already waits; 22 waits with this change). Specs 21 and 23 andsession-tags-folders.spec.tsF6 assert only overrequest; F5 and F7ui reload before they assert.Backwards compatibility
Compatible: one spec gains a wait on a real response, plus documentation. No product code, config or CI change; no assertion, timeout or step is removed.
Tests
Changed test: spec 22 of
website/playwright/session-tags-e2e.spec.ts. Measurements behind the documented numbers, on Linux (32 cores, aarch64), Chromium, the harness gateway (spawn_feature_gateway, stub ACP backend),--retries=0 --workers=1, spec 22 only (--grep "22\. drag"):b8bd2d33c2--repeat-each=30--repeat-each=10--repeat-each=20Forced means a local-only
page.routeheld the page's firstGET /api/chat/slotsreply (fetched from the gateway at once) until the drop's push had moved the card into the Done column, then fulfilled it. That is the order the CI snapshot shows. The probe is not committed.python scripts/docs_lint.py: all documentation checks passed.python -m pytest -n0 test/test_flake_pattern_ratchet.py: 71 passed.npx tsc --noEmit -p tsconfig.json: clean.