Skip to content

fix(nx): test-plans fails a sample whose gate explain failed - #987

Merged
m-dwyer merged 1 commit into
mainfrom
fix/test-plans-strict
Dec 5, 2026
Merged

m-dwyer merged 1 commit into
mainfrom
fix/test-plans-strict

Conversation

@m-dwyer

@m-dwyer m-dwyer commented Dec 5, 2026

Copy link
Copy Markdown
Collaborator

Two bugs in the plan replay (tools/nx/test-plans.mjs), reported by digitakt2-e1: two replays of an unchanged tree differed in 2 of 8 plans under load, and one plan lost all its test:subset lines.

  • The gate's --explain run's exit status was never checked: under load it could print its affected line and then fail in the ownership step, and the plan was written without that step's lines. A sample whose gate explain fails now writes no plan, is listed as FAILED, and the run exits 1 after finishing the other samples (a later --diff shows it as missing, not as a short plan).
  • The nx affected --explain file lived in the shared out/test-ledger/scratch, so two lanes replaying the same sample overwrote each other's; it now goes to the worktree's dist/test-ledger/scratch.

mise run test; host-level gate. Known limit, unchanged: a replay spawns an Nx process per target per sample (about 2 h for 8 samples on a loaded machine).

🤖 Generated with Claude Code

Under load the gate's --explain run could exit nonzero after printing its affected line; the
plan was written without the ownership step's test:subset lines, so two replays of an
unchanged tree differed (reported by digitakt2-e1). A failed sample now writes no plan, is
listed as FAILED, and the run exits 1 after finishing the other samples. The nx affected
--explain file moves to the worktree's dist/, so lanes replaying the same sample no longer
overwrite each other's.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@m-dwyer
m-dwyer merged commit 687ce4e into main Dec 5, 2026
2 checks passed
@m-dwyer
m-dwyer deleted the fix/test-plans-strict branch December 5, 2026 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant