Repository navigation
Close completed test harness Bead - #3941
Conversation
📝 WalkthroughWalkthroughThe PR adds a closed verification issue for managed test resources, recovery, typed receipts, termination attribution, baseline promotion, and dependency-PR scope validation. It links the dependency-PR subcase from the existing PR-scope validation issue. ChangesVerification and scope tracking
Estimated code review effort: 1 (Trivial) | ~5 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 2⚔️ Resolve merge conflicts 💡
🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.beads/issues.jsonl:
- Line 1: Correct the chronology in issue polylogue-9pf58 by removing or
revising the future-dated 2026-08-11 evidence in notes and the corresponding
acceptance-criteria wording. Use the actual observation date, or explicitly
label the content as planned, ensuring the authoritative snapshot contains no
observations dated after the 2026-08-10 closure.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 6be4c465-5c24-42ad-b159-ed34107aa926
📒 Files selected for processing (1)
.beads/issues.jsonl
| @@ -1,3 +1,4 @@ | |||
| {"_type":"issue","id":"polylogue-9pf58","title":"Test harness: fail-safe resource admission and fresh-worktree recovery","description":"A 12-worker full verify was terminated near 69% after pytest basetemp usage exceeded the declared /dev/shm budget: 1512 MiB observed versus a 1376 MiB default. Fresh worktrees also lack a dependable valid testmon seed or recovery route, partial seeded databases can survive interrupted builders, resource admission and worker selection are not bound into complete receipts, and termination can leave incomplete failure attribution or authorize a false green/release baseline. Separately, Dependabot PRs #3935-#3939 all fail Circle quick-gate because pr-scope check-ci requires a human-authored Bead carrier. These failures share one verification-harness concern: every accepted result and every scope-policy exception must be typed, evidence-backed, and fail closed.","design":"Trace the production devtools verify/test paths before changing them. Make pytest basetemp selection choose among supported roots from live free-space and declared run demand, clean only harness-owned stale/partial artifacts after ownership/age validation, and record the selected root, admission inputs, worker decision, peak usage, cleanup, termination, and attribution in machine-readable run receipts. Make fresh-worktree testmon bootstrap and interrupted seeded-DB recovery atomic and self-validating. Incomplete or terminated runs must be non-green and ineligible for release-baseline promotion. Keep coverage unchanged and preserve one-shot operator overrides. Extend pr-scope check-ci with a typed automated dependency-PR policy based on authoritative GitHub metadata and an allowlisted dependency-only changed-file contract; ordinary product PRs retain the full carrier gate.","acceptance_criteria":"1. A real verify/test route automatically refuses or reroutes before a declared basetemp budget can terminate the run; worker admission uses live capacity and records the decision without reducing coverage. 2. Harness-owned stale and partial seeded databases/basetemps are detected and safely cleaned or quarantined, while active and foreign paths are never deleted. 3. A fresh linked worktree can bootstrap a valid testmon seed or receives a typed recovery action; corrupt, stale, partial, or incompatible seeds cannot be promoted. 4. Every run receipt reports selection denominator/digest, worker/resource admission, selected basetemp, cleanup actions, terminal cause, complete failure attribution, and release_baseline_allowed; termination and incomplete attribution force false. 5. Focused real-route tests and controlled mutations fail when admission, cleanup ownership, seed validation, attribution completeness, or fail-closed baseline logic is removed. 6. Dependabot PRs with authoritative bot identity and dependency-only file changes receive a typed no-Bead scope disposition; spoofed actors, ordinary product PRs, or extra product files still require and validate the normal carrier. 7. The five observed Dependabot failures are represented by production check-ci route regressions, and ordinary PR-scope enforcement remains unchanged. 8. Focused tests and devtools verify --quick pass; a full or seed run is started only after the coordinator full run is no longer active and its exact outcome is recorded.","notes":"2026-08-11 additional live evidence: after rerouting basetemp to NVMe and reducing to 6 workers, full verify reached only 14% after about 18 minutes. All six xdist workers remained in Linux D state for roughly 18 minutes on SQLite-heavy tests while the supervisor stayed alive and emitted heartbeat output; the harness did not classify a stall. The operator aborted the owned run. Required refinement: combine sustained xdist worker process state with actual test-progress age, terminate the exact owned containment boundary, wait for cleanup, and publish a machine-readable terminal receipt. Supervisor heartbeat or output bytes must not reset worker-progress stall evidence.","status":"closed","priority":0,"issue_type":"bug","assignee":"Sinity","owner":"[email protected]","created_at":"2026-08-10T22:12:37Z","created_by":"Sinity","updated_at":"2026-08-10T23:41:42Z","started_at":"2026-08-10T22:13:12Z","closed_at":"2026-08-10T23:41:42Z","close_reason":"Satisfied by merged PR #3940 at 9d4fa12e8: managed basetemp admission and cleanup, typed xdist I/O-stall termination, fail-closed incomplete/resource-timeout receipts, fresh-worktree testmon seed/recovery handling, and authoritative Dependabot scope policy are implemented. Evidence: 60 focused harness/PR-scope tests, 27 PR-scope tests, 25-step devtools verify --quick, Circle quick-gate success on exact head; fresh seed attempt recorded 20,987 selected nodes and a typed tmpfs resource-timeout with release_baseline_allowed=false, followed by the bounded NVMe resume route.","labels":["area:devtools","area:test","area:verification"],"dependencies":[{"issue_id":"polylogue-9pf58","depends_on_id":"polylogue-817er","type":"discovered-from","created_at":"2026-08-10T22:12:59Z","created_by":"Sinity","metadata":"{}"},{"issue_id":"polylogue-9pf58","depends_on_id":"polylogue-93xe","type":"parent-child","created_at":"2026-08-10T22:13:08Z","created_by":"Sinity","metadata":"{}"},{"issue_id":"polylogue-9pf58","depends_on_id":"polylogue-inygw","type":"relates-to","created_at":"2026-08-10T22:53:35Z","created_by":"Sinity","metadata":"{}"}],"dependency_count":0,"dependent_count":0,"comment_count":0} | |||
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win
Correct the evidence chronology.
The current date is August 10, 2026. Line 1 records 2026-08-11 as additional live evidence, while polylogue-9pf58 is already closed at 2026-08-10T23:41:42Z. Line 19 also adds a 2026-08-11 note. Use the actual observation date, or label the text as planned. Do not keep future-dated observations in an authoritative snapshot.
Also applies to: 19-19
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In @.beads/issues.jsonl at line 1, Correct the chronology in issue
polylogue-9pf58 by removing or revising the future-dated 2026-08-11 evidence in
notes and the corresponding acceptance-criteria wording. Use the actual
observation date, or explicitly label the content as planned, ensuring the
authoritative snapshot contains no observations dated after the 2026-08-10
closure.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: de0d718e5d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
92ca0af to
5be8cfa
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5be8cfa90c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 60d19aa52a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2dc7bf01ff
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
## Summary
- complete the final controlled xdist-stall proof for the test-harness
Bead
- record the parent Bead closure against the exact current Beads
snapshot
## Problem
The resource harness had in-process worker identity support and typed
all-worker stall logic, but lacked a controlled six-worker regression
proving that post-exec worker identities are sufficient for the terminal
diagnosis. The parent Bead was therefore kept open after exact-head
review rather than being closed on the earlier implementation evidence.
## Solution
Add a controlled six-worker sampler fixture with six `session_started`
worker receipts and D-state process observations. The fixture proves
complete worker observation, typed stall diagnosis only after the
configured interval, and compatibility with the existing
partial-observation fail-closed behavior. The Beads export closes the
parent and its three named residual successors; this is harness
implementation/verification scope only.
## Verification
- `devtools test tests/unit/devtools/test_verify.py -k
'six_worker_d_state_fixture or
resource_sampler_resolves_worker_identity'` — 2 passed
- `devtools verify --quick` — 25/25 steps passed
- No green full-suite or production reindex is claimed.
<!-- polylogue-pr-scope:v1
{
"assigned_beads": [
"polylogue-9pf58"
],
"beads_digest":
"6a8ac0723c40c7ff27aa3d0b815dd3e9afe3ebcdf9451b0a338b6c3621f08088",
"dispositions": [
{
"bead_id": "polylogue-9pf58",
"disposition": "satisfied",
"evidence": [
{
"kind": "commit",
"ref": "12618c007 (merged harness implementation)"
},
{
"kind": "commit",
"ref": "ee93e8d248555fd6cae645781604d171dc6f9247"
},
{
"kind": "test",
"ref": "devtools test tests/unit/devtools/test_verify.py -k
six_worker_d_state_fixture: 2 passed"
},
{
"kind": "test",
"ref": "devtools verify --quick: 25/25 steps passed"
},
{
"kind": "review",
"ref": "PR #3941 exact-head review residuals resolved by named successor
closure"
}
],
"successors": []
}
],
"head_sha": "072a80b00a8596e47ac4ddf6aed5daee9fda274f",
"scope_digest":
"0c22e25fa6f724cdbcec42da546071e496e866e6c12be156255a8caf2ea353e8",
"version": 1
}
-->
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
- **Bug Fixes**
- Improved diagnostics for scenarios where multiple test workers become
unresponsive, including clearer identification of SQLite or
filesystem-related stalls.
- Updated incident-tracking records to reflect completed recovery and
fail-safe handling.
- **Tests**
- Added regression coverage for detecting six simultaneously stalled
workers.
- Refreshed test fixture verification data to keep incident-recovery
checks accurate.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
|
Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.
Only the rows listed above are dispositioned. Held findings remain open. |
|
Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.
Only the rows listed above are dispositioned. Held findings remain open. |
|
Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.
Only the rows listed above are dispositioned. Held findings remain open. |
|
Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.
Only the rows listed above are dispositioned. Held findings remain open. |
|
Historical Codex triage: evidence checked at 5ebcfe5. This records that source revision; it does not claim a fresh review of current master.
Only the rows listed above are dispositioned. Held findings remain open. |
Summary
Problem
PR #3940 delivered the core fail-safe harness. Exact-head review then found residual scope in automatic pre-execution reroute and the controlled xdist stall fixture, so the parent Bead remains open with named successors.
Solution
Record a partial disposition for
polylogue-9pf58: crash-left seeded-build recovery is complete and tested; automatic reroute and the six-worker xdist acceptance fixture remain onpolylogue-enl3landpolylogue-7wytz. The related base-authority Bead remains open.Verification
devtools lab policy bead-graph --json— zero unhandled findings; two explicitly deferred operator-action missing-AC records remainSummary by CodeRabbit