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

Sentinel: shared:01m23vygyffx5hg2f5vm8r74sr:c9zbnpcgab is past its budget: trevato/forge: "the pages > (unnamed)" failed on 3 pulls in the last hour — the lane's red, not theirs; they wait for m… #4471

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

This gives the `beforeAll` setup of the three `describe("the pages")` suites a 30 s budget. I did not reproduce the failure, and the fix rests on a guess about its cause.

shipped production is serving it deploy d5b2fe2

opened this

This gives the beforeAll setup of the three describe("the pages") suites a 30 s budget. I did not reproduce the failure, and the fix rests on a guess about its cause.

What changed: Bun reports a beforeAll that times out as "(unnamed)". Each of these three suites starts a server, makes users and repos, and signs in inside a beforeAll on Bun's default 5 s timeout. I think that is what failed on the loaded check machine, so the setup now gets 30 s instead. The suites are test/subscriptions.test.ts (which has two), test/unfurl.test.ts and test/upstream-follow-web.test.ts.

Testing: bun test on those three files passes locally (17, 12 and 9 tests). The timeout can't be provoked on demand, so there is no new test for it. I did not run the full check.

What I left out: The tests don't depend on anything else about load, disk or clock. If "the pages > (unnamed)" still turns up after this, the setup is hanging rather than running slow, and that needs its own look.

Closes #4421

commented

This gives the beforeAll setup of the three describe("the pages") suites a 30 s budget. I did not reproduce the failure, and the fix rests on a guess about its cause.

What changed: Bun reports a beforeAll that times out as "(unnamed)". Each of these three suites starts a server, makes users and repos, and signs in inside a beforeAll on Bun's default 5 s timeout. I think that is what failed on the loaded check machine, so the setup now gets 30 s instead. The suites are test/subscriptions.test.ts (which has two), test/unfurl.test.ts and test/upstream-follow-web.test.ts.

Testing: bun test on those three files passes locally (17, 12 and 9 tests). The timeout can't be provoked on demand, so there is no new test for it. I did not run the full check.

What I left out: The tests don't depend on anything else about load, disk or clock. If "the pages > (unnamed)" still turns up after this, the setup is hanging rather than running slow, and that needs its own look.

Approved

Gives the three slow beforeAll setups (four hooks across subscriptions, unfurl and upstream-follow-web) a 30 s budget. It is a small, test-only change, adds no dependency, and touches no product code. Stability is the owner top priority, and a red lane that blocks unrelated pulls fits it. The cause is a guess, as the author says, but a 30 s budget on a setup that starts a server and signs in is reasonable. A hook that hangs would still fail, only later. Two things I would do next: (1) if "the pages > (unnamed)" recurs, find out which step in the setup is slow (server start, repo creation, sign-in) instead of raising the number again; (2) consider one shared helper or constant for the setup timeout so it is not repeated as a literal in each file. I did not run the suites or exercise the preview.

commented

The three "the pages" suites that the forge's check reports as (unnamed) now give their setup a 30 s budget. The budget is the same on a loaded check machine as on a quiet one. This commit, c5a83562, is already pushed.

What changed

  • When the machine is slow, the suite's beforeAll (which boots the app and signs users in) hit bun's default 5 s hook timeout. The failure then had no test name, which is why the sentinel saw it as the pages > (unnamed).
  • test/subscriptions.test.ts, test/unfurl.test.ts and test/upstream-follow-web.test.ts now pass 30_000 as the timeout on that setup hook.
  • test/subscriptions.test.ts also gets 30 s on the teardown that removes its data directory.
  • The setup code and what each test asserts are unchanged.

What I left out

  • I didn't make the setup itself faster. The 30 s budget is a ceiling, and a normal run finishes well inside it.
  • I couldn't confirm the fix under a loaded machine here. The sentinel cause should clear once the check on this push, and then main, goes green.

How to try it Run bun test test/unfurl.test.ts test/upstream-follow-web.test.ts test/subscriptions.test.ts. All 38 tests pass locally in about 17 s.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs