Public: anyone can read this; the crew can change it.

Flaky: test/reviews-states.test.ts #2133

opened this

Merged 48d 11h ago, live in production

test/reviews-states.test.ts is now green in any order, and it moves from EXCLUDED to the gate in this pull. Cause: the outbox test, "every verdict and resolution reaches the event outbox", read events that earlier tests had left in the shared app.

Notes

opened this

test/reviews-states.test.ts is now green in any order, and it moves from EXCLUDED to the gate in this pull.

Cause: the outbox test, "every verdict and resolution reaches the event outbox", read events that earlier tests had left in the shared app. It needs a pull.thread_resolved event, and only the thread test produces one. Under random order the outbox test could run before the thread test, so the event wasn't there yet.

Change: the outbox test now makes its own events. It opens a pull, approves it, comments on a line, and resolves that thread, checking each step's status. It then runs the same outbox assertions as before, none weakened and no retries.

Gate: I removed the test/reviews-states.test.ts row from EXCLUDED in scripts/gate.ts. I didn't touch the other tests in the file, because none of them failed.

Evidence:

  • The five red seeds from the issue (394420590, 1239803461, 486729819, 158412525, 4160762648) all pass, 9 of 9.
  • Admission record from bun scripts/flake-hunt.ts admit test/reviews-states.test.ts: 10/10 green, random order, under load. Seeds: 579915252, 1805854522, 1204594843, 714569402, 1930814759, 3369439776, 2114665323, 1503441916, 97139693, 3231865244.
  • tsc --noEmit is clean and the gate tests (bun test test/gate) pass. I did not run the whole check; the forge runs it on this push.

To try it: bun test --randomize --seed=394420590 ./test/reviews-states.test.ts.

🤖 Generated with Claude Code

Closes #2107

commented

I merged main into this branch and pushed it. The only conflict was the exclusion list in scripts/gate.ts. The type check passes, as do test/reviews-states.test.ts and test/gate-summary.test.ts. I did not run the full suite; the forge's check does that on the push.

How I resolved the list:

  • test/reviews-states.test.ts: left off the list, because this pull fixes its flakiness and it no longer needs an exemption. main still had it listed under #2107.
  • test/reviews.test.ts: kept main's entry, with its #2106 reason ("a posted review comment appears inline, anchored to its line"). It replaces the older "not yet admitted" entry.
  • test/read-api.test.ts: dropped, since main removed it from the list.
Sign in to join this conversation.

Search
↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs