Skip to content

ci(windows): stream and bound the single-job advisory test steps (#9272) - #9840

Merged
EffortlessSteven merged 7 commits into
mainfrom
claude/project-thread-wn73zi
Oct 25, 2026
Merged

EffortlessSteven merged 7 commits into
mainfrom
claude/project-thread-wn73zi

Conversation

@EffortlessSteven

Copy link
Copy Markdown
Member

Governing issue or accepted claim: #9272 (evidence #9660)
Acceptance delta (one sentence): a hung or leaking test in the single-job Windows advisory lane ends at a runner-enforced deadline with the whole process tree terminated, the job log shows output as it arrives, and a timeout names the tests still running.

Problem

Two full windows-advisory jobs (119992784688, 120026188944) ran for hours past the 75-minute step limit with no output. The steps redirect cargo's output to a file and cat it afterwards, so a step that never ends publishes nothing, and the hosted timeout-minutes did not stop the process tree. (The redirect replaced | tee because a leaked child holds a pipe open; that part stays.)

Change

  • New cargo xtask windows-advisory-run --timeout-minutes <n> --log <path> --status <path> -- <program> [args...]. It spawns the command under the repo's OwnedProcess (a Job Object on Windows) and:
    • streams stdout and stderr to the job log line by line and into --log;
    • ends the whole tree at its own deadline and records status 124 (127 if the command cannot start; otherwise the command's exit code);
    • on a timeout prints every test libtest reported as running for over 60 seconds with no result, or the last output lines when none was reported;
    • waits at most 15 s for output after the command exits, then terminates descendants that hold the pipe;
    • itself exits 0, so test outcomes stay advisory and the summarizer still refuses a missing status.
  • windows-advisory.yml: the three test steps (--no-default-features tests, workspace run 1 and 2) use it with deadlines of 40, 70 and 70 minutes, below their 45/75/75 step limits, which stay as a backstop. A new "Build advisory step runner" step copies xtask.exe to target/advisory-run/ first, because cargo test --workspace rebuilds xtask.exe and Windows will not replace a running image. Job cap sum is still under 270.
  • docs/CI.md, command catalog entry (ci_enforced false: the lane shields it with exit 0), changelog fragment.

Not in this PR

The sharded lane (windows-advisory-shards.yml) and its watchdog belong to the Windows test verdict thread. No test is skipped or disabled. The failing-test clusters (#9659, #9660, #9661) are untouched.

Proof

  • cargo test -p xtask windows_advisory_run: 7 pass on Linux, including a deadline kill that names stuck::forever, a leaked descendant that would otherwise hold the step, a normal exit with streamed output identical to the log file, and a missing program.
  • cargo xtask precommit passes.
  • Not yet shown: the Windows Job Object path and the hosted step wiring. A hosted Windows Advisory dispatch on this branch is the proof and will be posted here.

Generated by Claude Code

…treaming, deadline-enforcing runner (#9272)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PrRRMBXfD85Xo2kQ9La4AV
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@coderabbitai

coderabbitai Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

  • Ask an admin to enable usage-based reviews

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Next included review available in 55 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 161 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Essentials
  • Run ID: e8c91643-7e30-44d4-8993-03db19fa8fd7
Commits

Reviewing files that changed from the base of the PR and between 6212bda and 6eb6958.

Files selected for processing: 8
  • .github/workflows/windows-advisory.yml
  • changelog.d/9272-windows-advisory-run.md
  • docs/CI.md
  • policy/process_allowlist.txt
  • xtask/src/command.rs
  • xtask/src/dispatch.rs
  • xtask/src/main.rs
  • xtask/src/windows_advisory_run.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

…r and bound its edge cases (#9272)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PrRRMBXfD85Xo2kQ9La4AV

Copy link
Copy Markdown
Member Author

Independent review of cc6cbb8 (read-only agent; correctness/edge cases and workflow/contract angles) found one blocker and several smaller points, all addressed in b373ced:

  • Blocking, fixed: stdout and stderr were drained by two threads, so cargo's Running headers (stderr) and libtest's test result: (stdout) could arrive out of order and be attributed to the wrong target by the summarizer. They now share one pipe, like the old > log 2>&1, with a test that alternates the two streams and checks log order.
  • Fixed: a busy spin when the reader had ended but the child was alive; a finished should_panic test staying in the "still running" set; --timeout-minutes overflow; runner errors now fall through to exit 0 as before (the missing status is what the summarizer reports); the banner and docs no longer claim descendants were killed on every platform (the Job Object guarantees that on Windows).
  • Left as is: a line is buffered until its newline (cargo output is line oriented); the post-grace drain can lose bytes still in the OS pipe, which is bounded and only happens on a held pipe.

Not yet shown: the Windows behavior. I cancelled the hosted run on the old head and dispatched Windows Advisory on b373ced; the result goes here. Gemini and CodeRabbit are quota-limited, so provider review is missing, not clean.


Generated by Claude Code

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirmed findings

  • Duplicate runner options silently overwrite earlier values rather than being rejected.

Verification questions

  • Confirm linux tests exercise OwnedProcess through the implementation but cannot establish that Windows descendants are actually terminated as a tree.
  • Confirm after the post-exit grace expires, the loop breaks and calls terminate_tree, then drains only queued lines; output written by descendants after that point can be intentionally truncated while the log is still marked usable.
  • Confirm actionlint failure means workflow syntax or expression validity is not proven by this review packet.
  • Confirm the leaked-descendant unit test expects status 0 although its POSIX shell normally exits 124 after the background sleep remains.

Evidence gaps

  • Windows termination behavior remains the principal sibling-path gap: Linux tests use shell/background processes, while the claimed whole-tree guarantee depends on OwnedProcess::terminate_tree using a Job Object.
  • The main security claim depends on OwnedProcess providing actual Windows Job Object containment; the supplied evidence is advisory and hosted Windows wiring is not shown.
  • The claimed Windows Job Object termination and hosted workflow wiring remain unverified by the available evidence.
  • Windows Job Object behavior and hosted step wiring are not demonstrated by the available review evidence.
  • The PR explicitly lacks proof for the Windows Job Object path and hosted workflow wiring.
  • The tests establish runner logic on Unix but do not directly exercise Windows OwnedProcess/Job Object assignment or descendant termination.
  • The PR's strongest source-route claim still requires a hosted Windows execution witness.

Copy link
Copy Markdown
Member Author

Terminal observation for the existing Windows Advisory run 39866369241 / full job 120129769081, checked 2026-10-23 00:53 UTC.

Subject and native outcome:

  • The job completed at 00:36:04 UTC. Its checkout's own git log -1 --format=%H prints b373ced79915dc65db753bbd2d3aa92dc11ac056 (22:39:12.793Z). This is actual checkout evidence.
  • Workspace repeat 1 ran 23:15:24–00:04:04; repeat 2 ran 00:04:04–00:35:54. Both native Cargo statuses are 101, classified nonzero_with_observed_test_failures. Repeat 1 observed 19,008 pass / 16 fail; repeat 2 observed 19,007 pass / 17 fail. The summary records 16 repeated failures and 1 unstable row. The job's SUCCESS is advisory-wrapper success, not a Windows-test pass.
  • Feature checks: no-default-features check PASS, no-default-features test FAIL (101), all-features check PASS.

Runner/output evidence:

  • Output is present throughout both workspace steps, not withheld until a final cat.
  • At 00:04:03.9239643Z, after repeat 1's Cargo command exited, the runner printed: “windows-advisory-run: output was still open 15s after the command exited; termination of the process tree was requested”. Repeat 2 starts at 00:04:04.1103813Z. This directly observes the hosted 15-second post-exit drain branch and subsequent step progress. It does not independently inventory every descendant after termination.
  • Neither repeat reached the 70-minute inner deadline; neither recorded status 124. The forced-deadline/still-running-test-report path is NOT_ESTABLISHED on Windows by this run. The runner's deadline and synthetic leaked-pipe integration tests are cfg(unix); they were not selected here. Five platform-neutral windows_advisory_run tests did pass in each repeat. Existing native process release-seam controls also report pass/pass, but do not substitute for the runner's unexercised deadline path.

Reusable, bounded #9736 / #9660 row evidence:
6ff98f80...b373ced7 reports merge-base 6ff98f800da869580fcadba5091e55d0c4a4d33a, 8 ahead / 0 behind. None of #9736's eight changed paths differs in that comparison. The following raw terminal rows are all ... ok in BOTH repeats (times UTC; date rolls over between columns):

Exact row Repeat 1 Repeat 2
dispatch::precommit_v2::tests::workspace_only_metadata_projects_identical_roots_and_plan 23:46:51.603 00:21:11.496
reports::release::candidate_harness::live_head::tests::budget_tests::direct_manifest_caps_proof_inputs_and_aggregate_bytes 23:53:57.620 00:26:34.120
reports::release::candidate_harness::source::inventory::tests::batch_size_identity_cannot_expand_the_reviewed_source_inventory 23:53:56.201 00:26:32.455
reports::release::candidate_harness::source::inventory::tests::replacement_objects_cannot_change_inventory_or_admit_substituted_checkout 23:53:58.383 00:26:34.536
reports::release::candidate_harness::source::inventory::tests::source_inventory_and_checkout_enforce_independent_precise_budgets 23:53:59.306 00:26:35.839
reports::release_ledger::capture_tests::newline_prefixed_file_names_keep_their_tree_effect 23:54:12.885 00:26:47.974
tests::policy_checker_facade_runs_current_repo_checks 23:58:31.940 00:30:41.240
contabo_result_policy::policy_text_keeps_its_source_and_verdict_guards (integration target; raw row omits target prefix) 23:58:59.040603 00:31:08.504036
contabo_result_policy::caller_grants_only_the_four_approved_read_scopes (same target) 23:58:59.040907 00:31:08.504294
reports::release::candidate_harness::live_head::tests::source_tests::direct_source_admission_refuses_moved_ref_wrong_tree_origin_and_same_version_substitution (Git-path sibling repair) 23:54:19.922 00:26:55.593
windows_shard_summary::colored_nextest_rows_still_reach_the_summary (integration target) 00:03:36.057 00:35:42.284
windows_advisory::tests::the_summarizer_verdict_reaches_the_job_log_and_its_refusal_is_not_suppressed 23:58:42.830 00:30:52.082

The windows_shard_summary target itself reports 1 passed / 0 failed in each repeat. The two static policy rows above are the whole Windows-selected contabo_result_policy target, 2 passed / 0 failed.

This is reusable native evidence for the listed #9736 subset on the executed descendant, for the canonical #9660 owner record. It does not rehabilitate cancelled original run 39836520247, close all of #9660, establish the later #9822 rows, or resolve the separate #9688 doctor/eval-sweep limitation. The latest #9660 owner update remains applicable to that later scope.

No new dispatch, rerun, writer, label action, cancellation, merge or closure was performed for this observation. The already-produced full advisory artifact was finalized in the job log; no artifact was downloaded.

Copy link
Copy Markdown
Member Author

Owner continuation for the remaining Windows evidence, 2026-10-23 03:48 UTC.

Owner / governing claim: @EffortlessSteven, retain the existing #9840 author lane (claude/project-thread-wn73zi, session_01PrRRMBXfD85Xo2kQ9La4AV) for #9272 single-job observability. The #9822/#9660/#9661 author lane remains separate. No branch was overwritten or second writer created.

Candidate / review: #9840 remains Draft at b373ced79915dc65db753bbd2d3aa92dc11ac056, tree b752880aed09e37ed4d781431ba1c987538e78c0, PR base 5a7f7eff1c16cf5358998a5c9d7e6c96c0d472b7. The independent review described at cc6cbb8 predates the b373ced repair; it is not a blanket independent final-head clearance. The current review questions, including duplicate option handling and native containment, need explicit owner disposition. No inline review threads were returned; that does not clear Conversation findings or missing proof.

Validation reused: paired receipt 6354750369 is terminal on actual raw checkout b373ced: Cargo 101/101, 16 repeated failures plus one unstable row. Its streamed output and 15-second post-exit drain branch are observed. No 70-minute deadline fired and no status 124 was recorded. Earlier #9736 rows pass/pass are reusable within their scope, not #9822 proof. The original #9822 cancelled receipt remains unchanged.

New evidence reduces the requested work: the already-completed #9812 run 39873139606 checked out f81fd10, containing #9822 squash e0b147f with unchanged product/test blobs. The recovered native row receipt now supplies doctor injected-refusal, parity, gitfile, owner-pin and scoped printed-path PASS rows, plus the expected named ACL refusals. All four shards remain native 100 with 13 failures overall. There is no reason to repeat the full #9822 qualification merely to recover those rows.

Next smallest proof action / canonical owner: one bounded synthetic native Windows forced-deadline control of this runner's real entry point, on the frozen candidate. Its CLI already accepts windows-advisory-run --timeout-minutes 1 --log <owned-log> --status <owned-status> -- <owned-helper>; no whole workspace pair is needed. The helper must announce one slow test and keep an invocation-owned primary plus a pipe-holding descendant alive past the deadline. Observe:

  • before deadline, output is visible in both retained log and external job sink;
  • runner terminal result and status file 124, with the exact still-running name;
  • primary reaped and the recorded descendant actually absent afterward, using ownership/PID identity captured before launch;
  • an independent sentinel remains alive, and the following step can read/retain the completed receipt.

A timeout banner, status 124 alone, or the prior post-exit-drain message is insufficient for descendant cleanup. Preserve failed/partial outcomes. Execute through the existing owner on an authorized native Windows executor; if a focused probe must be added to the candidate, keep it in this branch's repair wave and obtain independent exact-head review plus relevant integration checks before promotion. Source inspection confirms the existing synthetic deadline/leak tests are Unix-only, so rerunning Linux cannot close this gap. #9812's separate shell watchdog is not this runner's forced-deadline witness.

Blocking / resume: native controlled execution and final-head independent review are pending; no owner acknowledgment is claimed. A repository-wide active-run CLI GET returned bare Forbidden (not a rate-limit diagnosis), and owner cloud-task listing failed at transport. Both outcomes were preserved without retry or credential changes. Named #9822, #9840 and #9812 runs were independently read as terminal through the connected GitHub tool; other active jobs remain unverified. Reconcile any same-claim running job before admitting the focused control.

No new dispatch, rerun, cancellation, writer, label change, Ready transition, merge, artifact access or protection access was performed. Retain Draft until the claimed native bounds, findings and integration/review prerequisites are satisfied.

@EffortlessSteven EffortlessSteven left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Scoped source review of PR #9840; inspected commit b373ced79915dc65db753bbd2d3aa92dc11ac056, tree b752880aed09e37ed4d781431ba1c987538e78c0, PR base 5a7f7eff1c16cf5358998a5c9d7e6c96c0d472b7. Observation: 2026-10-23 16:46 UTC. This is a source-bound review of the retrieved snapshot, not final current-head clearance.

Disposition: REPAIR_REQUIRED for the source findings below; merge review remains REVIEW_INCOMPLETE. Preserve the existing author lane and Draft. No replacement custody, candidate edit, build, dispatch, rerun, cancellation, runner change or merge was performed.

Three new source findings are attached inline: unbounded re-wait after termination error (P1), sink delivery blocking deadline observation (P1), and discarded output I/O failures (P2). They are source findings, not newly executed native Windows failures.

Existing evidence reused, independently inspected. Run 39866369241/job 120129769081 prints the actual checkout b373ced79915dc65db753bbd2d3aa92dc11ac056 at 22:39:12.793Z. Both repeats emitted the five platform-neutral runner test PASS rows; the Unix-only runner deadline/leak/order/exit controls were not selected on Windows. Raw verdict lines at 00:35:56Z report Cargo 101/101 and 19008 pass/16 fail, 19007 pass/17 fail. The 00:04:03.923Z message observes the 15-second post-exit drain branch. Artifact upload finalized ID 12469692767; its archive was not downloaded. These corroborate the existing paired receipt, including its explicit native-proof limits. No new full qualification is warranted to repeat these observations.

Cancellation and proof boundary. Workflow source uses !cancelled() for later tests/summaries and always() for log upload; that expresses partial-evidence retention intent, not an observed cancellation receipt. The runner has no cancellation observation/handler, and the process owner's comments explicitly state that Job Object kill-on-close is off. Normal Rust Drop cleanup cannot by itself establish abrupt runner-process termination behavior. GitHub's cancellation sequence uses signals/control events followed by external tree termination; that platform cleanup must not be credited as this runner's own forced-deadline proof. No leak on cancellation is asserted from source alone. Preserve the existing owner's pending native forced-deadline control and add controlled runner cancellation/termination to the native evidence denominator if cancellation containment is claimed.

Prior review dispositions. Duplicate options do overwrite earlier values; this is not exercised by the fixed single-occurrence workflow arguments and remains an explicit CLI-contract decision for the owner. The leaked-pipe test's expected shell status 0 is consistent with sh -c 'sleep 120 & echo finished': a local bounded shell control with only the sleep reduced to 1 second observed primary status 0 after 0.011s and pipe EOF at 1.002s. That refutes the claimed inherent shell status 124; it is only POSIX shell evidence. The post-grace drain intentionally takes queued lines and can truncate pipe bytes, as already disclosed; it does not prove an inventory of terminated Windows descendants. The hosted job demonstrates acceptance/execution of its workflow path; no actionlint result is claimed.

Checks and limits. All eight changed paths, full runner, command routing/catalog, OwnedProcess, summarizer, docs/changelog, process allowance and workflow retention/deadline guards were inspected from committed objects. git diff --check 5a7f7eff...b373ced7 passed. Existing connector reads returned two successful classic statuses and PR-triggered workflows with CI/Windows/other lanes skipped; these are not a complete required-check clearance. Rust/Cargo/actionlint/native Windows are unavailable on this cloud host; no installations or builds were attempted. The broader CLI read gh pr view ... --json ...statusCheckRollup returned Post "https://api.github.com/graphql": Forbidden; that denied operation was not retried or routed around. Consequently complete live required checks and a later posting-time head refresh are unverified. No final-current-head or merge eligibility claim is made.

Next executable step / custody. The existing integrating owner should accept or refute these source findings on the current candidate, repair through the same author lane, refresh affected focused review/proof, then use the already-described bounded native Windows deadline/descendant/sentinel receipt. Parent/lead coordinates custody and landing. A full paired Windows rerun, second writer or dispatch is not requested by this contribution.

Comment thread xtask/src/windows_advisory_run.rs Resolved
Comment thread xtask/src/windows_advisory_run.rs Resolved
Comment thread xtask/src/windows_advisory_run.rs Resolved
…utput delivery and refuse incomplete output (#9272)

Address the review of b373ced: bound the post-termination observation and
report unconfirmed termination, deliver the job log from its own bounded
queue, withhold the status when the pipe or log file failed, refuse
duplicate options, and add a native Windows forced-deadline control behind
a dispatch-only input.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PrRRMBXfD85Xo2kQ9La4AV

Copy link
Copy Markdown
Member Author

Owner disposition for the b373ced review, repaired at head 31b4e11e16fbc23ef958dd6e02e78db48e6b2653 (same lane, same branch, still Draft).

  • P1 re-wait after termination error: fixed. terminate observes the primary for 10 s with try_wait and never calls the unbounded wait. A failed or unconfirmed termination is carried into the banner ("process tree termination NOT confirmed: ...") instead of "terminated". Test with an injected OwnedTree whose termination fails and whose primary stays live: returns bounded, error text kept.
  • P1 sink blocking the deadline observer: fixed. Job-log delivery is a separate thread behind a bounded queue (4096 chunks); a full queue drops the chunk from the job log only and is reported. The log file is written by the supervisor, and the sink gets 5 s to flush at exit. Test with a writer blocked on a condvar for the whole run: the 1 s deadline still fires, status 124 and the still-running name land in the log file, the sink note says delivery was blocked.
  • P2 discarded I/O failures: fixed. A pipe read error is now a distinct message, and a log-file write error is recorded. Either withholds the status file (a stale one is removed at start), so the summarizer refuses the step; the child's code is in the banner. Tests: a read fault is kept; a log on /dev/full yields no status and an "OUTPUT EVIDENCE INCOMPLETE" banner. A failing job-log sink is reported separately and does not withhold the status.
  • Duplicate options: now refused with a test (decision: reject, not last-wins).
  • Cancellation: not claimed. The runner has no cancellation handler; the workflow's !cancelled()/always() retention is intent, not an observed receipt. Platform cancellation cleanup is not credited to the runner.
  • Native forced-deadline control: added as a cfg(windows) test plus a dispatch-only job (runner_probe_only). It runs the real execute entry with a PowerShell primary that announces stuck::forever and starts a pipe-holding descendant (pid recorded before the deadline), and asserts status 124, the exact still-running name, no termination error, the descendant pid absent afterward, and an unowned sentinel still alive. Dispatched as run 40135056813; I will post the raw rows when it finishes. Before-deadline visibility in the external sink is not asserted by this test.

Local: cargo xtask precommit passes; 21 runner tests pass on Linux (the Windows one is compiled out there).

Not yet established: the Windows result above, and a fresh exact-head independent review of this repair.


Generated by Claude Code

Copy link
Copy Markdown
Member Author

Native Windows forced-deadline control: PASS on head 31b4e11e16fbc23ef958dd6e02e78db48e6b2653 (run 40135056813 / job 120994712437, windows-latest, step "Native forced-deadline control", 21:44:13Z). Raw rows:

native deadline control: elapsed=20.0402762s outcome=Outcome { status: 124, timed_out: true, still_running: ["stuck::forever"], pipe_held_after_exit: false, termination_error: None, output_faults: [], sink_note: None } descendant_pid=6068 descendant_alive=false sentinel_alive=true
windows-advisory-run: TIMEOUT after 20s running `powershell -NoProfile -Command $d = Start-Process -PassThru -NoNewWindow powershell ...`; process tree terminated
windows-advisory-run: still running: stuck::forever
test ...windows_native_deadline_ends_the_descendant_and_spares_a_sentinel ... ok
test result: ok. 1 passed; 0 failed

What this establishes: the real execute entry on Windows ended a primary plus a pipe-holding descendant at the 20 s deadline, recorded status 124 and the exact slow test name, reported no termination error, and left the descendant pid (recorded before the deadline) absent, while an unowned sentinel process stayed alive. The test also asserts the status file reads 124.

Not established: the descendant was checked by pid via tasklist only after execute returned; before-deadline streaming into the external job sink is not asserted (the earlier full run showed streamed output on Windows); runner behaviour on workflow cancellation is not claimed. The full workspace pair was not re-run for this head, since the repair does not touch what those runs measured beyond the runner itself.

Next: independent exact-head review of 31b4e11, then ready, merge-ready and the required check.


Generated by Claude Code

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verification questions

  • Confirm runner_probe_only gates the main and subset advisory jobs but does not gate every job in the workflow, so a probe dispatch may still execute unrelated jobs unless their conditions independently exclude workflow_dispatch.
  • Confirm the Windows-native forced-deadline test is the decisive check for whole-tree termination and non-interference with an unrelated sentinel process.
  • Confirm the workflow uses inputs.runner_probe_only in both full-lane job conditions, but GitHub inputs context is primarily populated for workflow_dispatch; the surrounding condition does not explicitly guard the event.
  • Confirm no repository test proves the edited workflow passes the intended runner arguments and that only the native probe job runs in runner_probe_only mode.
  • Confirm the Windows-native test proves that an auxiliary process dies, but not that it is a descendant retaining the runner's output pipe.
  • Confirm the runner's status file is withheld on output faults, but the workflow still exits 0 and relies on a later summarizer to refuse missing evidence; this is intentional advisory behavior, not evidence of a passing test.
  • Confirm the adjacent windows-advisory-summary path remains separate from the new runner: it consumes retained logs and status files, while the runner produces them.
  • Confirm the native test would pass even if Job Object termination killed the primary but not the auxiliary process if tasklist reported the PID incorrectly.

Refuted

  • The shared output pipe may expose a stale or partially resized active view of the child's output.; refuted because: The reader sends owned Vec chunks over a channel, and the supervisor consumes each chunk before handling it. There is no ArrayBuffer/TypedArray, resize operation, detach/transfer, or shared backing store; the sink queue is bounded by dropping queued chunks rather than exposing a truncated buffer.

Evidence gaps

  • Windows-native whole-tree termination remains an unproven sibling route: the repository provides a native probe, but this packet contains no successful probe receipt.
  • The Windows forced-deadline control is the material executable evidence for whole-tree termination; Linux unit tests do not establish Job Object behavior.
  • Model proof intent was rejected by deterministic validation.

…ounded reap cannot hang it (#9272)

Address the exact-head review of 31b4e11: terminate_tree and OwnedProcess
drop both end in an unbounded reap, so the call now runs on a thread that
owns the child and is abandoned after twice the observation budget.
Also withhold the status on the spawn-failure path after a log fault, wait
briefly for in-flight output after terminating pipe holders, and make the
native Windows test clean up its sentinel first.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PrRRMBXfD85Xo2kQ9La4AV

Copy link
Copy Markdown
Member Author

Review of record input for 31b4e11e (independent read-only reviewer, ran the runner tests, could not run the Windows test) and the repair at head cd8556610a9dcda806161e3a361352843e9283da.

Prior findings: duplicate options fixed; job-log delivery off the deadline path fixed; output I/O faults fixed (gap below); termination bound partly fixed.

Finding Disposition
P2 terminate_tree and OwnedProcess drop end in the owner's unbounded reap, so a primary that survives a successful kill request still hangs the runner after status 124 is decided Confirmed in process_owner.rs (terminate_tree calls wait, Drop calls wait). Fixed: termination runs on a helper thread that owns the child (terminate_bounded); the supervisor abandons it after twice the observation budget and reports "termination call did not return". Test with a tree whose terminate_tree sleeps for two minutes: returns in seconds, error says so. Docs corrected.
P3 status written on the spawn-failure path after a log fault Fixed: same faults.is_empty() guard.
P3 banner can be dropped from the job log when the sink queue is full Accepted: a stalled job log cannot carry any banner, and the log file holds it plus the sink note. Stated in the comment and docs.
P3 single non-blocking drain after terminating pipe holders Fixed: waits up to 1 s for in-flight output.
P3 stale status/log if the old status file cannot be removed Not changed: the runner returns an error and the workflow swallows it; a fresh hosted runner has no prior pair. Noted as a limit.
P3 non-Windows leaked-descendant path terminates nothing; Unix test passes on the drain grace Accepted: production is Windows; the Unix test asserts the bounded wait and the "requested" banner, not a kill.
P3 execute-level read-fault and termination_error paths untested Partly: unit tests cover Output::handle and terminate/terminate_bounded; no injection seam for execute itself.
P3 Windows test fragility (sentinel leak on ?, cold PowerShell start inside 20 s, tasklist right after kill) Sentinel is now killed before any fallible call. Timing and tasklist risks stay; the first native run passed.

Local: cargo xtask precommit passes; 15 runner tests pass. Re-running the native Windows control on this head, which also proves OwnedProcess is Send on Windows (the helper thread needs it).


Generated by Claude Code

Copy link
Copy Markdown
Member Author

Native Windows forced-deadline control on head cd8556610a9dcda806161e3a361352843e9283da: PASS (run 40137552436 / job 121002186408, 22:20:24Z). The helper-thread termination compiled and ran on Windows, so OwnedProcess is Send there.

native deadline control: elapsed=20.0977062s outcome=Outcome { status: 124, timed_out: true, still_running: ["stuck::forever"], pipe_held_after_exit: false, termination_error: None, output_faults: [], sink_note: None } descendant_pid=2380 descendant_alive=false sentinel_alive=true
windows-advisory-run: TIMEOUT after 20s ...; process tree terminated
windows-advisory-run: still running: stuck::forever
test ...windows_native_deadline_ends_the_descendant_and_spares_a_sentinel ... ok

Same limits as the first native run: the descendant check is a tasklist pid lookup after the call returns; the test does not separately prove the descendant held the pipe, and cancellation behaviour is not claimed. The github-actions verification questions on the previous head are answered by this evidence and by the dispositions above; CodeRabbit is rate-limited, so its review is missing, not clean.

Taking the PR out of draft and requesting the required check.


Generated by Claude Code

@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 24, 2026 22:24
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

… action-count policies (#9272)

The required Rust tests rejected the probe job's if: (every job must admit
the merge-ready labeled event) and the third rust-cache and toolchain action
in windows-advisory.yml. Reshape the guard and drop both actions; the pinned
rust-toolchain.toml selects 1.95.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PrRRMBXfD85Xo2kQ9La4AV
@github-actions

Copy link
Copy Markdown
Contributor

merge-ready was requested, but this PR conflicts with main (head 7b90b853), so GitHub creates no test-merge ref and no qualification run can start. Merge main into the branch and resolve the conflicts, then remove and re-apply merge-ready.

Copy link
Copy Markdown
Member Author

Required check on cd855661 failed (run 40138407536), and it was this PR's fault: nextest stopped at repo-policy::rust_only_routing::gated_lanes_admit_pull_requests_only_on_the_merge_ready_labeled_event, which requires every job in windows-advisory.yml to carry a guard that admits the explicit merge-ready event. My probe job's if: did not. A second policy test, workflow_action_pins::burn_down_pins_preserve_step_local_tool_selections, pins the per-workflow count of rust-cache and rust-toolchain actions and would have failed next. My local precommit does not run either test.

Fixed at 7b90b8538850657e95106e34a1869fdeb608617a: the probe's guard now has the shape the test accepts (still dispatch-only with the input), and the probe job drops the cache and toolchain actions (rust-toolchain.toml pins 1.95). Both tests pass locally, as do check-workflows, the 64 windows_advisory tests and the rest of the xtask suite except installed_pin_missing_locked_dependency..., which needs a prepared sparse-registry cache that this host lacks. merge-ready is re-applied and the probe is re-dispatched on this head, because it now builds without the toolchain and cache actions.


Generated by Claude Code

Copy link
Copy Markdown
Member Author

Required check on ea47da8d (run 40143727346) failed on one test that is not this PR's: xtask reports::verdict_corpus::known_false::tests::committed_ceilings_equal_the_blessed_missed_credit (rust missed_credit_ceiling must equal the blessed count, left 135, right 143). This PR touches no corpus, ceiling, or analyzer file, and the committed ceiling of 135 is the same on current origin/main, so main is red for it too. Fix PRs #10140 and #10152 are already open, so I am not opening a third. Everything before the test step passed (format, precommit, process and network policy, check, clippy), and the two workflow-policy tests that failed the previous head now pass. Once one of the two fixes lands I will merge main, re-run the local gates and re-request the check.


Generated by Claude Code

Copy link
Copy Markdown
Member Author

Review of record, head 6eb6958313023eb75e0f78b98d0bd3da6b3ebbf9 (main 6212bda merged in).

Angles: two independent read-only reviews (correctness/edge cases; workflow/contract), a native Windows control, and local gates.

Findings and resolutions:

  • Unbounded re-wait after termination error: fixed (bounded try_wait, plus terminate_bounded helper thread because OwnedProcess::terminate_tree and Drop end in an unbounded reap).
  • Sink blocking the deadline observer: fixed (off-thread job-log sink, bounded queue).
  • Discarded output I/O faults: fixed (fault withholds the status file; spawn-failure path guarded the same way).
  • Duplicate options: refused with a test.
  • Probe-job guard and action counts (repo-policy): fixed in 7b90b85; the previous required-check failure on ea47da8 was the main-wide missed-credit ceiling break, healed by test(corpus): realign missed_credit_ceiling with blessed counts (#9271 follow-up) #10152, not this PR.
  • Open: tasklist pid check runs after return; pipe-holding by the descendant is not separately proven; cancellation behaviour is not claimed; failure to remove a stale status file is a noted limit.

Evidence: native Windows probe PASS on 31b4e11, cd85566 and 7b90b85 (status 124, still_running ["stuck::forever"], no termination error, descendant absent, sentinel alive). cargo xtask precommit exit 0 and repo-policy tests pass on this merge, except 3 llvm coverage_diagnostics tests that need a matching llvm-profdata absent from this container. Required check Ripr Rust Small Result is success on this exact head. The three inline threads are replied to and resolved. CodeRabbit and Gemini are quota-limited, so their review is missing, not clean.


Generated by Claude Code

@EffortlessSteven
EffortlessSteven merged commit a6909e9 into main Oct 25, 2026
52 checks passed
@EffortlessSteven
EffortlessSteven deleted the claude/project-thread-wn73zi branch October 25, 2026 02:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants