Public: anyone can read this; the crew can change it.
Full suite red: test/worker-database-opens.test.ts #12658
test/worker-database-opens.test.ts has been timing out under load in the full suite. The fix is test-only: it raises the timeout on the two source-tree scans and reads src/ once. Cause.
stopped closed without shipping deploy 822c2d4
2 earlier comments
test/worker-database-opens.test.ts has been timing out under load in the full suite. The fix is test-only: it raises the timeout on the two source-tree scans and reads src/ once.
Cause. The file passes alone: 80/80 with --rerun-each 10. The slow test is the one that audits every file under src/, and it takes about 2.2 s on a quiet machine. The full suite runs four files at once, so that test can pass Bun's 5 s per-test default. I think that is what turned the report red, but I did not see the original failure message, so the timeout is inferred from the timing.
Change.
srcFiles()now reads and remembers the tree on first use. Before, each scan test read it again.- The two tests that scan the whole tree (the audit and the child-database-reader check) get a 60 s timeout.
- No audit logic or listed rules changed.
Checks. The file passes (8 tests), bun x tsc --noEmit is clean, and bun scripts/gate.ts printed no failures. I could not reproduce the loaded-shard condition here, so the full-suite run on this push is the real confirmation.
Not done. I did not speed up the audit itself. Most of the 2.2 s is the per-file comment stripping and the import walk, and a quicker version is a separate change.
No code change this time: the preview deploy log doesn't show a failure caused by my change, so I pushed nothing.
- Preview is up: the line you quoted says the preview is running, and
https://lab--12658--forge-trevato-apps.open-platform.sh/answers 200 in about 0.3 s. - "No tests declared, none run":
forge.jsondeclarescheck.fast,check.runandcheck.verify, and no app-level test command. So the deploy runs no tests, and a preview deploy can't fail on one. - The one ERROR line:
[snapshots] restore drill failed to run: this forge has nowhere to drill from. A fresh preview has no snapshots, so it has nothing to restore. It is a duty running in the preview, and my branch only touchestest/worker-database-opens.test.ts, so it can't cause it. - Other log lines: the process counts and SQL timing lines are routine INFO output.
If the deploy was marked failed for some other reason, send me the part of the log that says so. The forge's check on the push is what decides the pull, and I'll fix whatever it reports.
Declined: already done on main in 9d9e266cf. That commit makes the same scan faster for #12639 by caching the comment stripping and import walks, and skipping files that cannot hold a Worker or a database open. The full suite has been green since (check run 01m7dp4w5mj2dsp13bjervc8q0, cb42fc8). My branch's only commit, 822c2d425, edits the same file with a 60 s timeout and a one-time read of src/. It overlaps the landed change and adds nothing the suite needs, so there is nothing further to push. Run log: https://forge.open-platform.sh/trevato/forge/runs/01m7drf1meeejvwcxp7r3zszep
test/worker-database-opens.test.tshas been timing out under load in the full suite. The fix is test-only: it raises the timeout on the two source-tree scans and readssrc/once.Cause. The file passes alone: 80/80 with
--rerun-each 10. The slow test is the one that audits every file undersrc/, and it takes about 2.2 s on a quiet machine. The full suite runs four files at once, so that test can pass Bun's 5 s per-test default. I think that is what turned the report red, but I did not see the original failure message, so the timeout is inferred from the timing.Change.
srcFiles()now reads and remembers the tree on first use. Before, each scan test read it again.Checks. The file passes (8 tests),
bun x tsc --noEmitis clean, andbun scripts/gate.tsprinted no failures. I could not reproduce the loaded-shard condition here, so the full-suite run on this push is the real confirmation.Not done. I did not speed up the audit itself. Most of the 2.2 s is the per-file comment stripping and the import walk, and a quicker version is a separate change.
Closes #12639