Skip to content

[WRONG BRANCH] test(ci): reap the cold-spawn descendant before the test ends - #17

Merged
vadymhimself merged 2 commits into
release/2.65.0-vadymhimself.15from
devops-r/ocx-b4-reap
Nov 10, 2026
Merged

vadymhimself merged 2 commits into
release/2.65.0-vadymhimself.15from
devops-r/ocx-b4-reap

Conversation

@vadymhimself

Copy link
Copy Markdown
Owner

What

tests/ci-workflows/cold-spawn-warmup.test.ts: the "descendant holding the child's pipes" test now kills the detached grandchild it spawns and asserts it is gone before the test ends.

Why

Run 42898913860, test 1/4: shard 1/4 batch 4/40 hit the 120 s batch timeout (exit 124) on both attempts with 0 test failures. In both attempts the hang was in build-release-changelog.test.ts ("parses actual NUL-delimited git-log output", a Bun.spawnSync git call), about 0.45 s after the cold-spawn descendant test ended.

That test's grandchild runs setTimeout(() => process.exit(0), 8_000) detached with inherited stdio. The test settles after about 5 s, so the grandchild stayed alive about 3 s into the next file of the same Bun process. That is the only cross-file state this batch leaves behind.

Honest limits

  • The hang did not reproduce in 11+ runs: Mac with bun 1.4.0 and 1.3.14, GitHub ubuntu runners with 2-file variants, the 12-file batch x3 and x5 at the exact merge commit eeabe70, and the full shard 1 at eeabe70. The post-merge push run 42920887596 passed test 1/4.
  • The likely trigger is a Bun Linux runtime race (ci.yml already notes a Bun isolate/epoll race) exposed by the live grandchild. This PR removes the leaked state. It does not prove the race.

Check

The new expect(alive()).toBe(false) fails on today's code. Lane run devops-r-ocxb4-check (bun 1.4.0):

  • fixed: 1 pass 0 fail
  • mutant with the kill line removed: 0 pass 1 fail (Expected: false, Received: true)

Eval added/updated: N/A deterministic (unit/integration test: tests/ci-workflows/cold-spawn-warmup.test.ts)

🤖 Generated with Claude Code

The descendant-holding-pipes test left a detached grandchild alive for
about 3 s into the next file of the same Bun process. In run 42898913860
shard 1/4 batch 4 hung in that next file's Bun.spawnSync git call on both
attempts until the 120 s batch timeout. The test now parses the
grandchild pid, kills it, and asserts it is gone before the test ends.

Co-Authored-By: Claude Code <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

✅ Deterministic PR hygiene checks passed.

@github-actions github-actions Bot added the chore label Nov 10, 2026
@github-actions github-actions Bot changed the title test(ci): reap the cold-spawn descendant before the test ends [WRONG BRANCH] test(ci): reap the cold-spawn descendant before the test ends Nov 10, 2026
@github-actions

github-actions Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

⏳ DRAFT

  • wrong target branch (release/2.65.0-vadymhimself.15); retarget to dev.

What to do

  • Retarget this PR to dev — all contributions go to dev.

Its title has been prefixed with [WRONG BRANCH].
Automatic draft conversion failed (token cannot change draft status). Please convert this pull request to a draft manually. The required enforce-target check will keep failing until every issue above is resolved.

@github-actions
github-actions Bot marked this pull request as draft November 10, 2026 23:28
@vadymhimself

Copy link
Copy Markdown
Owner Author

QA (qa-low-6e) code-read GREEN at cba399e. Pid parse is safe: it reads the child's own stdout line, NaN or 0 never reaches process.kill (guarded by > 0) and the test asserts pid > 0, so it fails loudly. SIGKILL targets the detached descendant only, within about 5 s of its spawn (8 s lifetime). Assertion discriminates: owner mutant log shows fixed 1 pass 0 fail, mutant 0 pass 1 fail. The PR body states the honest limit (the 120 s hang did not reproduce in 11+ runs; this removes the leaked state, it does not prove the Bun race). Nit: the mutant fails only while the 2 s wait is shorter than the descendant's remaining life, so on a very slow box the guard weakens (never the fixed run). Receipt: ~/.agentradar/qa-low-6e/review-ocx17-cba399e24.json

Co-Authored-By: Claude Code <noreply@anthropic.com>
@vadymhimself

Copy link
Copy Markdown
Owner Author

QA (qa-low-6e) re-stamp GREEN at 023c62d. Delta from the reviewed cba399e is one commit touching 4 files, one line each: package.json, desktop/src-tauri/Cargo.toml, Cargo.lock, tauri.conf.json, 2.65.0-vadymhimself.18 to .19 (base is on .18; same four files as #15's bump). The test change is unchanged. Receipt: ~/.agentradar/qa-low-6e/review-ocx17-023c62da6.json

@vadymhimself
vadymhimself marked this pull request as ready for review November 10, 2026 23:52
@vadymhimself
vadymhimself merged commit aef6e32 into release/2.65.0-vadymhimself.15 Nov 10, 2026
32 of 33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant