chore(main): release 7.28.3#989
Merged
zaxbysauce merged 1 commit intoMay 22, 2026
Merged
Conversation
Contributor
Author
|
🤖 Created releases: 🌻 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix(test-runner): cap bun heap with --smol, env-gate scope:all, process-group kill on timeout
What changed
bun --smolon every test run (both dispatch pathsrc/lang/default-backend.tsandlegacy path
src/tools/test-runner.ts). The--smolflag caps bun's heap-growthheuristic, matching the per-file CI pattern already used throughout the repo and
eliminating OOM-driven OpenCode session crashes during broad test runs.
scope: 'all'is now environment-gated. The agent-settableallow_full_suiteargumenthas been removed from the
test_runnerschema and fromTestRunnerArgs. The only way tounlock a full-suite run is the
SWARM_ALLOW_FULL_SUITE=1environment variable, which isavailable only in CI / maintainer shell sessions and cannot be set by an LLM tool call.
The blocked-response message deliberately does not name the env var.
Process-group kill on timeout.
bunSpawngains an opt-inkillProcessTree: trueflag.When set, the test-runner spawn uses
detached: true(Node path) and routeskill()callsthrough
killProcessTreeImpl, which sendsprocess.kill(-pid)on POSIX to reap alldescendants (jest/vitest worker pools, etc.) and runs
taskkill /PID <pid> /T /FonWindows. The default behaviour for all other callers (~30 non–test-runner sites) is
unchanged.
Prose docs updated.
AGENTS.md§6,docs/engineering-invariants.md, and all agent-facing skill files are aligned with the new gate. Agent-facing docs do not reveal the env
var name to prevent LLMs from attempting to set it.
Why
Agents repeatedly ran the test_runner tool with unscoped or wide-scope invocations, crashing
the OpenCode session with OOM errors. Prior mitigations (prose warnings in AGENTS.md, skill
files asking agents not to do this) failed because nothing in the tool itself enforced the
limit, and the
allow_full_suite: trueargument was literally documented in the schema —teaching agents how to bypass the block. This fix hardens the tool at the code level so that
no LLM-controlled argument can unlock an unsafe run.
Migration
scoped test runs (
files: [...],scope: 'convention',scope: 'graph').SWARM_ALLOW_FULL_SUITE=1in the shell environment before invoking OpenCode.allow_full_suitearg will now produce an "unrecognized key" Zod validation errorif passed by old agents; they will see the normal scope-blocked response.
Known caveats
--smolplus the 50-fileMAX_SAFE_TEST_FILEScap reduce OOM risk for typical runsbut do not eliminate it for worst-case 50-file batches sharing one heap. Per-file
subprocess isolation (candidate D, deferred) would be the next hardening step.
intentionally not added (cross-platform process-tree integration tests are flaky).
tests/unit/tools/test-runner-scope-cap.test.tstests 9 and 11 remain pre-existingfailures (they predate
MAX_SAFE_SOURCE_FILES=1and hit the "no framework detected"path before the Layer guards). This PR reduces pre-existing failures from 3 to 2.
🤖 I have created a release beep boop
7.28.3 (2026-05-22)
Bug Fixes
This PR was generated with Release Please. See documentation.