Skip to content

fix(release,xtask): Windows install-record ripr.exe and check-pr scratch cleanup (#10344) - #10523

Merged
EffortlessSteven merged 4 commits into
mainfrom
claude/project-thread-qdq5b6-10344-install-exe
Oct 26, 2026
Merged

EffortlessSteven merged 4 commits into
mainfrom
claude/project-thread-qdq5b6-10344-install-exe

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Oct 26, 2026 •

Copy link
Copy Markdown
Member

Summary

Swarm / Source Boundary

  • ordinary feature, analyzer, editor, docs, spec, fixture, badge, dependency, or repo-ops development for ripr-swarm

Source-of-truth Links

Proposal: none
Spec: none
ADR: none
Plan item: #10344
Governing issue or accepted claim: #10344
Acceptance delta (one sentence): Release packaged-install provenance accepts the binary name Cargo actually records on the host, so a genuine Windows install is no longer refused.

Candidate Relationships

Candidate branch (GitHub PR head is authoritative after publication): claude/project-thread-qdq5b6-10344-install-exe
Stack parent or prerequisite PR (if any): #10506 (main compile break, #10456 × #10488). This PR will merge main once that lands; until then its required run cannot compile.
Proposed replacement of PR (if any; not yet accepted): none
Acceptance retained from a replaced candidate (if any): none
Accepted winner and losing candidate disposition (when decided): none

Scope

  • xtask/src/reports/release.rs:
    • adds records_ripr_bin;
    • validate_install_provenance passes it std::env::consts::EXE_SUFFIX;
    • the unit-test records use the host binary name;
    • adds a new host-explicit test, install_record_bin_names_follow_the_host_executable_suffix.
  • changelog.d/10344-windows-install-record-exe.md (Fixed).
  • xtask/src/tests.rs: remove_owned_scratch_dir and its one caller; changelog.d/10344-check-pr-scratch-cleanup.md (Internal / CI).

Scope Classification

  • One production behavior

Production delta: xtask release qualification only. The ripr product is unchanged.
Non-goals: the eval_sweep ACL NOT_ESTABLISHED row on #10344, which is fail-closed by design.

Support-tier Impact

None.

Policy Impact

None.

Proof

  • Linux, with fix(typescript): main compile break, stale mocks argument in collect_tests_from_statements calls (#10456 x #10488) #10506's 2-line fix applied locally only so the tree builds; it is not in this PR: cargo test -p xtask --bin xtask -- install_record_bin_names packaged_install_provenance install_source_urls gives 4/4 pass.
  • cargo xtask precommit: exit 0.
  • The new test rejects bare ripr under .exe and ripr.exe under no suffix. Under .exe, the old rule (== "ripr") would fail its ripr.exe case.
  • Native proof: the hosted windows-advisory run on this head (windows-ci) runs the real cargo install control.

Claim Boundary

This fixes the binary-name comparison only. The source-path, version and single-install checks are unchanged.

Rollback

Revert this PR.

Spec-Test-Code Traceability

Not applicable.

Static Language Check

No panic-family calls added.

CI Economics

Default required lane.

Engineering Check

Uses the same std::env::consts::EXE_SUFFIX idiom as the rest of release.rs (lines 381, 3687).

Gates

cargo xtask precommit passes.

https://claude.ai/code/session_01PdRXdT9261qDfiBsZW51xs


Generated by Claude Code

…#10344)

Cargo's .crates2.json names each installed binary by file name, so a
Windows path install records ripr.exe. validate_install_provenance
compared against the bare name and refused every genuine Windows
packaged install as "installed no ripr binary" (hosted Windows rows
on #10443/#10467/#10478). The check now takes the host EXE_SUFFIX, and
a host-explicit test covers both spellings.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PdRXdT9261qDfiBsZW51xs
@EffortlessSteven EffortlessSteven added the windows-ci Run the advisory Windows lane on a pull request without opting into every full-ci lane. label Oct 26, 2026 — with Claude
@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 26, 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 16 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 185 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: 12e03fc9-7c83-4d96-9a8e-6c6ee6212cc4
Commits

Reviewing files that changed from the base of the PR and between 494a296 and 7f0e90b.

Files selected for processing: 4
  • changelog.d/10344-check-pr-scratch-cleanup.md
  • changelog.d/10344-windows-install-record-exe.md
  • xtask/src/reports/release.rs
  • xtask/src/tests.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

graphite-app[bot]

This comment was marked as resolved.

… scratch (#10344)

Hosted Windows failed check_pr_failure_report_replaces_stale_success_report
in cleanup (os error 32) after its oracle passed: a briefly held handle
in the test-owned scratch dir. Cleanup now retries os error 32/33 for
up to five seconds; any other error, or a longer holder, still fails.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PdRXdT9261qDfiBsZW51xs
@EffortlessSteven EffortlessSteven changed the title fix(release): accept Cargo's ripr.exe install-record entry on Windows (#10344) fix(release,xtask): Windows install-record ripr.exe and check-pr scratch cleanup (#10344) Oct 26, 2026
…nction

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PdRXdT9261qDfiBsZW51xs

Copy link
Copy Markdown
Member Author

The wheel build and Rust checks on this Draft fail because main's ripr lib doesn't compile. The mocks argument in typescript/tests_extract.rs is stale after #10456 and #10488 crossed (E0425/E0061). This PR doesn't cause it; it touches only xtask. The fix of record is #10506. At the coordinator's request I'm not porting it, because #10506 also carries a stale-test fix. I'll merge main once it lands, then mark this Ready and apply merge-ready.


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 the full lane does not prove there are no additional scratch-cleanup siblings or Cargo install-record bin-name variants outside the checked surfaces.
  • Confirm no focused test directly drives remove_owned_scratch_dir through transient errors 32/33, exhaustion, or a non-retryable error.
  • Confirm sibling code paths that construct or validate Cargo install-record binary names were not comprehensively enumerated.
  • Confirm the scratch cleanup retry is localized to the named xtask test; whether other test-owned temporary directories have analogous Windows cleanup failures requires a repository-wide cleanup inventory.
  • Confirm the Windows cleanup retry has no focused deterministic test for retry count, retryable error selection, five-second bound, or propagation of non-32/33 errors.

Test proof

  • Focused HEAD proof failed (exit 101): cargo test --locked --package xtask --test help_hierarchy. This is a current failure, not a red/green witness.

Refuted

  • A worker or async transfer boundary could make the Windows scratch-directory cleanup race unsafe or detach ownership.; refuted because: The helper calls std::fs::remove_dir_all synchronously and retries only matching Windows raw OS errors 32/33; no worker, async, GC, detach, or transfer abstraction is involved.
  • The diff contains no JavaScript-backed worker, async task, GC, detach, or transfer boundary; the affected implementation paths are synchronous Rust filesystem and JSON operations.
  • The new suffix-aware install-record check could introduce a dangling reference or ownership hazard through its formatted binary name.; refuted because: records_ripr_bin constructs an owned String and compares each JSON value against it during the iterator's borrow; no reference outlives the local value.

Evidence gaps

  • The central cargo-test receipt and native Windows execution remain necessary to close runtime proof gaps.
  • The diff lacks completed native Windows proof in the available packet.
  • Model proof intent was rejected by deterministic validation.

@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 26, 2026 01:45
@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!

@devin-ai-integration devin-ai-integration 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.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@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 the Windows cleanup retry is localized to remove_owned_scratch_dir and the named check-pr test; the displayed diff contains no second caller to migrate.
  • Confirm the cleanup retry recognizes raw OS error values 32 and 33, but the diff does not establish portability of those values across Rust platforms.
  • Confirm the Windows scratch-cleanup retry branch has no direct deterministic test for error selection, retry count, the five-second bound, or non-retryable propagation.
  • Confirm the cleanup helper's retry contract is described in code but lacks a deterministic focused test for retry, exhaustion, and non-retryable errors.
  • Confirm the retry helper is routed only through the named check-pr failure-report test.

Refuted

  • The install-record comparison risks memory unsafety through string construction or JSON iteration.; refuted because: records_ripr_bin builds an owned String and compares each serde_json::Value as a borrowed str without mutation or lifetime extension.
  • The cleanup retry could hide unrelated filesystem failures or become an unbounded denial-of-service loop.; refuted because: The implementation limits retries to errors 32 and 33 and a maximum of 50 attempts; other errors are returned immediately.
  • The install-record binary list may be resized, detached, or transferred while records_ripr_bin reads it, exposing stale length or backing-store state.; refuted because: No buffer ownership, resize, detach, transfer, or mutation occurs in the changed path; records_ripr_bin receives an immutable slice of parsed serde_json::Value elements.
  • The changes require a broader shared cleanup or install-record abstraction to be architecturally complete.; refuted because: Both changes are narrowly scoped: one private predicate used by one validator and one private retry helper used by one test; extracting broader abstractions would increase scope rather than complete the fix.
  • The cleanup retry might cross an unsafe worker/async handoff or detach directory ownership while a child process retains a handle.; refuted because: No worker, async runtime, JavaScript-backed object, GC transfer, detach, or ownership handoff exists on the changed path. The operation remains synchronous, test-owned, and bounded to five seconds.
  • The prior doc-comment split invalidates the current oracle review.; refuted because: The seeded thread records the author moving records_ripr_bin above validate_install_provenance's doc block, and the current patch shows the helper before that doc block.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.

Copy link
Copy Markdown
Member Author

Review of record: head 7f0e90ba

Disposition: REVIEW_READY. Nothing blocking.

Angles inspected

  • Correctness. records_ripr_bin compares each install-record bin against ripr{EXE_SUFFIX}. That matches Cargo's .crates2.json, which names bins by file name (ripr.exe on Windows). The suffix is a parameter, so both spellings are tested on any host.
  • Test oracle. install_record_bin_names_follow_the_host_executable_suffix asserts that ripr is accepted and ripr.exe refused for an empty suffix, and the reverse for .exe. The existing provenance tests now build host-correct records.
  • Scratch cleanup. remove_owned_scratch_dir is a test-only helper with one caller. It retries only raw os errors 32/33 (sharing and lock violations), up to 50 times 100 ms apart, and returns any other error at once. Those error values only occur on Windows, so on other hosts it is a single remove_dir_all. It has no dedicated test: it is test scaffolding, and the native run below exercises it.
  • Native Windows proof. The windows-advisory job 121357299487 on this head passed packaged_install_provenance_reads_cargos_real_install_record, check_pr_failure_report_replaces_stale_success_report and the new suffix test. The only failures were the 3 doctor ACL rows and the eval_sweep ACL row. All four fail closed by design (Windows: doctor subdirectory-deny check never runs on hosted runners (icacls (AD) deny not enforced) #9688) and are outside this diff.
  • Required CI. Ripr Rust Small Result is green (121370753655). Merge state is clean.

Findings


Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-ready windows-ci Run the advisory Windows lane on a pull request without opting into every full-ci lane.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants