Skip to content

fix(ci): require candidate CLI proof for changed release-note commands - #16014

Merged
EffortlessSteven merged 2 commits into
mainfrom
ci/14644-doc-cli-projection
Nov 22, 2026
Merged

EffortlessSteven merged 2 commits into
mainfrom
ci/14644-doc-cli-projection

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Nov 21, 2026 •

Copy link
Copy Markdown
Member

Summary

A release-note edit can change the command path or flag that the public guide contract checks against candidate CLI help. The scoped docs gate now compares the original and candidate Git blobs with the same parser as that contract. A changed ordered command/flag sequence requires candidate CLI proof. Surrounding prose can keep the same projection. Changed source lines containing a ripr command prefix and shell continuations also require candidate proof, including bracketed flags and bare commands outside the flag parser.

Swarm / Source Boundary

  • swarm-only CI, runner, routing, source-of-truth, or agent-operating surface

Source-of-truth Links

Governing issue or accepted claim: #14644 Leaf A. The existing full precommit obligation is governed by #2258, and #14989 governs the candidate public guide contract.
Spec: RIPR-SPEC-0060, release-note CLI inputs to the scoped docs gate, with the new revision test mapped in .ripr/traceability.toml.
Acceptance delta (one sentence): A release note that changes ripr check --diff to a different command or introduces an undocumented flag can no longer earn the standalone scoped docs-gate pass.

Candidate Relationships

#15900 merged the independent whole-tree document-role prerequisite. This change advances the same #14644 lane. #15971 covers hosted cache save behavior. Neither replaces the other.

Scope

The product-free consumer uses the public-guide parser embedded by the existing candidate help contract. Revision mode uses Git object identities and compares the ordered paths and flags. Non-UTF-8 or missing blobs, deleted destinations, and unknown modes widen. Direct changed-list mode lacks historical bytes and requests revision mode or full proof for release notes.

Scope Classification

  • One production behavior

Proof

  • cargo test --offline --locked -p repo-policy --test docs_gate passed 24 tests on Windows. The new test exercises additions, removals, new flags, different commands, prose changes, opaque bracketed and bare examples, multiline continuations, dirty working copies, and missing revision context.
  • cargo clippy --offline --locked -p repo-policy --lib --test docs_gate -- -D warnings passed.
  • The original portable three-file help harness compiled in isolation and enumerated all 39 tests. The original and final parser returned 234 identical line, command-word and flag records across all 16 governed documents.
  • The scoped revision API inspected the complete historical docs(release): name the selected alpha adapters in the 0.11 draft #15674 committed base, group and role tree and passed the scoped product-free subset; the release-note blobs contain 29 identical flag-bearing invocations. Changing a candidate option widens.
  • The full candidate-binary public guide contract is left to protected CI. Its optional-dependency-free build is unavailable because that test directly imports ripr and release archive support.

Claim Boundary

The normal hosted docs gate continues running the full precommit table and candidate CLI contracts. This change establishes a product-free reason to widen; a matching projection alone cannot qualify an executable or authorize reuse of a previous run.

CI Economics

The modified-file path reuses the two Git blob reads already needed for heading retention. The change does not dispatch an extra job.

Rollback

Revert this single PR to restore the prior docs-gate eligibility decision.

@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 Nov 21, 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 27 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 148 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: 5616ab2d-f2b0-403f-8c78-2be3631f823b
Commits

Reviewing files that changed from the base of the PR and between aaf5155 and e102270.

Files selected for processing: 6

  • .ripr/traceability.toml
  • changelog.d/14644-docs-gate-release-note-cli.md
  • crates/ripr/tests/common/help_contract.rs
  • docs/specs/RIPR-SPEC-0060-source-of-truth-stack.md
  • tools/repo-policy/src/docs_gate.rs
  • tools/repo-policy/tests/docs_gate.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@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.

SOURCE_REVIEW_READY

Reviewed e670646 against aaf5155. I traced the public-guide executable contract through its extraction, help lookup, line diagnostics, and the product-free revision consumer. A separately compiled comparison against the original extractor produced identical line, ordered command-word, and ordered flag observations for all 16 governed documents (234 invocations). The #15674 base and group retain the same 29 release-note invocations; appending an invalid flag changes the comparison.

The changed decision is bound to the raw Git blob IDs. Moving prose and changing example values preserves the flag checker input, while adding a flag, changing the command path, or dropping an invocation widens even against a repaired working copy. A new prose-only document remains eligible and a new CLI example widens. An unbound changed list widens for release notes. Protected precommit and all five Markdown contract executions remain in the hosted workflow.

The 154 library, 24 docs gate and 25 frontdoor tests passed on Windows, alongside strict focused Clippy. The canonical public guide binary imports ripr and release archive support, so its full candidate-product execution belongs to the pending protected run. This source disposition is limited to the new widening decision. No unresolved source finding.

@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 found 5 potential issues.

Devin Review

Comment thread tools/repo-policy/src/docs_gate.rs Resolved
Comment thread tools/repo-policy/tests/docs_gate.rs Resolved

@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.

Source review found one release blocker at e670646. The candidate archive copies only the three paths in HELP_HARNESS_FILES. After help_contract.rs began importing common/doc_invocations.rs, that archived subset stopped compiling. I materialized exactly the three committed blobs under an isolated H directory and ran rustc --edition=2024 --test --emit=metadata. It failed to read common/doc_invocations.rs. Adding that single file made the identical command succeed. Please retain the standalone harness contract and exercise the production roster after the correction. The parsed release-note projection otherwise preserves the ordered command paths and flags used by the existing candidate help consumer, and unsupported Git changes widen.

@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.

SOURCE_REVIEW_READY

Independently re-reviewed e102270. I extracted just the three committed files from the installed candidate help harness roster and reproduced a successful standalone Rust test compile. Those same three inputs had failed at the previous head. The scoped docs gate compares both the parsed help inputs and the complete raw lines containing possible command examples, including continuations. Changed, removed, flagless and bracketed command examples widen to the candidate contract. Unavailable historical inputs and unknown Git transitions still require full proof. The normal hosted gate keeps its full precommit obligations.

@EffortlessSteven
EffortlessSteven added this pull request to the merge queue Nov 22, 2026
Merged via the queue into main with commit eebec83 Nov 22, 2026
19 checks passed
@EffortlessSteven
EffortlessSteven deleted the ci/14644-doc-cli-projection branch November 22, 2026 06:50
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.

1 participant