fix(ci): cap the ratchet's vitest worker count to 2

#4307: Test Suite (ubuntu-latest) intermittently crashes with tinypool's
ERR_IPC_CHANNEL_CLOSED at three different, unrelated points across 7 runs
on this PR, after ruling out any specific file as the cause (one
candidate, pod-tick.test.mjs, was fixed separately for an unrelated
reason and the crash still recurred at a different file). The pattern
(crash location varies, happens ~60-90s into a ~9500-test run) is more
consistent with cumulative memory pressure across the default fork
pool (one fork per CPU, ~4 on a standard runner) than a single bad
test. Capping workers at 2 trades some wall-clock time for headroom
while the real cause is still open in #4307.

Co-Authored-By: RuFlo <ruv@ruv.net>
This commit is contained in:
randRuFlo committed 2026-10-20 00:42:37 -04:00
1 parent b09e68c752
commit 3739f3a99c
1 file changed
+8
+8
View File
@@ -128,6 +128,14 @@ function main() {
const run = spawnSync(process.execPath, [
vitestBin,
'run',
// #4307: the default fork pool (one fork per CPU, ~4 on a standard
// GitHub-hosted runner) intermittently crashes with tinypool's
// ERR_IPC_CHANNEL_CLOSED partway through this ~9500-test suite — observed
// at three different, unrelated points across repeated runs, consistent
// with cumulative memory pressure rather than one bad file. Capping forks
// trades wall-clock time for headroom; raise this back (or drop it) if a
// future profiling pass finds the real cause and fixes it properly.
'--maxWorkers=2',
// The new guidance file uses Claude Code's native test kit, not
// Vitest. Do not enlarge the historical known-failure baseline.
'--exclude=plugins/ruflo-mods/tests/guidance.test.ts',