Repository navigation
fix(xtask): cite a spec id in fixtures new bless step - #8099
Conversation
Closes #7398 `cargo xtask fixtures new` printed `--reason "initial scaffold"`, which `goldens bless` rejects because reasons must cite an existing spec id. Step 4 now prints a copy-pasteable live spec example and points at `cargo xtask specs next` to replace it. Co-authored-by: Steven Zimmerman, CPA <EffortlessSteven@users.noreply.github.com>
|
Warning Review limit reachedThe included review limit has been reached and this organization has disabled usage-based review continuation. Wait for reviews to reset or ask a billing admin to change After included review limits. Next included review available in 1 minute. View limit details
Comment |
EffortlessSteven
left a comment
There was a problem hiding this comment.
review-pr (author self-review, COMMENT)
GitHub cannot request-changes from the author; this is not an approval.
reviewed_head_sha: c2cdca591fd7c93cf91828418d6ea74219e471c8
integration_basis: origin/main at PR base (GitHub reports 1fb5236427df97e08a9fc7111e64178077a228c8; candidate branched from 40a5de602). Behind-only; no content conflict inspected.
claim_boundary: #7398 only — fixtures new step-4 bless --reason must cite a spec id that validate_bless_reason accepts, plus instructions via cargo xtask specs next. Not #7399.
changed_surfaces_and_semantic_owners_inspected: xtask/src/reports/fixtures.rs — fixtures_new / fixtures_new_step4 (producer) and goldens_bless → validate_bless_reason / parse_reason (consumer). No product classify/CLI/schema/editor/golden files.
blocking_findings: none on source/oracle for this claim.
non_blocking_suggestions: the unit test binds fixtures_new_step4, which println! uses; it does not capture fixtures_new stdout. A later println that bypassed the helper would not be caught. Acceptable for this UX-text claim; not worth spawning a fixture.
refuted_or_stale_findings: none.
proof_and_ci_observed: cargo test -p xtask fixtures_new_printed_bless_reason_passes_the_reason_validator passed; cargo xtask precommit exited 0 locally. Hosted required checks not yet observed on this published head (PR still Draft at review time).
proof_or_review_missing: hosted exact-head CI receipts.
affected_currentness_dimensions: production implementation, test stimulus, test oracle. Unchanged: public claim, generated relationships, conflict resolution.
residual_assumptions_and_non_claims: RIPR-SPEC-0001 is a live example, not the fixture's spec; contributors must replace it. #7399 SPEC.md / traceability placeholder is untouched. Test does not prove a full fixtures new → goldens bless subprocess.
disposition: REVIEW_INCOMPLETE until hosted required checks on this SHA; source and oracle are otherwise ready for this claim.
Oracle challenge: the old printed reason initial scaffold is an explicit failing control in the new test; validate_bless_reason still rejects it. The extracted quoted --reason from fixtures_new_step4 is the string println! emits. A placeholder RIPR-SPEC-NNNN would fail the same validator (NNNN is not four digits / not a known spec), so the live example is load-bearing.
There was a problem hiding this comment.
Code Review
This pull request updates the fixtures new command to include a valid spec ID in the generated bless command, ensuring that the printed instructions are compatible with the reason validator. A new helper function was introduced to format the step-4 output, and a corresponding test was added to verify that the generated reason passes validation. The review feedback suggests simplifying the bless_reason_quoted_in_step4 helper function by using str::split_once and returning a &str to avoid unnecessary allocations.
There was a problem hiding this comment.
Decision
- Needs verification checks before upstream.
Verification questions
- Confirm test is bound to fixtures_new_step4, not to fixtures_new stdout. A bypass println! would not be caught — bounded concession, not material to claim #7398.
- Confirm helper couples the printed step-4 string to the validator, eliminating a whole class of drift regressions; only risk is someone reintroducing a side println that bypasses the helper, which the test would not catch (already noted by author self-review).
Refuted
- validate_bless_reason would reject the printed '--reason "RIPR-SPEC-0001: initial scaffold"' because the suffix 'initial scaffold' is non-empty and the spec id might not be registered.; refuted because: The constant FIXTURES_NEW_BLESS_EXAMPLE_SPEC is 'RIPR-SPEC-0001', documented as a live docs/specs/ id; the test feeds the extracted reason into validate_bless_reason and would fail if rejected, and the author reports the test passed locally. Bare 'initial scaffold' is asserted to remain a failing control.
- Test must capture fixtures_new stdout to be a strong oracle for #7398; refuted because: Claim #7398 is the printed step-4 text. The helper IS the printed text; the only indirection is a single println! of the helper. A stdout capture would be a marginal hardening, not a correctness gate for this narrow UX-text claim. Author self-review explicitly accepted the bound; do not drip-feed.
- Helper should be promoted to a shared 'xtask copy' module to prevent future drift between step-4 text and other next-actions lines.; refuted because: Only step-4 has a machine-validated reason (validate_bless_reason). Steps 2, 3, 5 are free-form guidance with no validator binding. A shared module would be premature abstraction and would widen the change beyond #7398's smallest complete fix.
Parked follow-ups
- Prior author self-review (EffortlessSteven) flagged that test binds fixtures_new_step4, not fixtures_new stdout, so a future println! that bypassed the helper would not be caught. Acceptable for UX-text claim, not worth a fixture.
- Ripr sensor failed (exit 2) but claim #7398 is a developer-xtask UX string and does not depend on ripr oracle coverage. Not trust-affecting for this lane.
Evidence gaps
- Model proof intent was rejected by deterministic validation.
- Ripr sensor failed (exit 2) but claim #7398 is a developer-xtask UX string and does not depend on ripr oracle coverage. Not trust-affecting for this lane.
EffortlessSteven
left a comment
There was a problem hiding this comment.
review-pr (published-head, author COMMENT)
GitHub cannot request-changes from the author; this is not an approval.
reviewed_head_sha: c2cdca591fd7c93cf91828418d6ea74219e471c8
integration_basis: origin/main (PR base 1fb5236427df97e08a9fc7111e64178077a228c8). Behind-only; no content conflict; no restack.
claim_boundary: #7398 only — fixtures new step-4 bless --reason cites a live spec id that validate_bless_reason accepts. Not #7399.
changed_surfaces_and_semantic_owners_inspected: xtask/src/reports/fixtures.rs fixtures_new_step4 / fixtures_new (producer) and goldens_bless → validate_bless_reason (consumer).
blocking_findings: none.
non_blocking_suggestions: test binds fixtures_new_step4 rather than fixtures_new stdout (parked).
refuted_or_stale_findings: Devin changelog fragment — not required by docs/CHANGELOG_POLICY.md include list. Gemini split_once/&str — style, not a defect. Graphite verification questions — already answered in the prior self-review.
proof_and_ci_observed: hosted CI on this SHA completed with no failures (40 checks). Ripr Rust Small Result success. Ripr Rust Small on GitHub Hosted / Rust gates success. Docs Gate / extra runner / coverage / MSRV / windows-advisory skipped-by-policy, not passed.
proof_or_review_missing: CodeRabbit quota-limited (missing for that provider). Adequate alternative: this published-head review-pr plus Devin/Gemini/Graphite comments already dispositioned.
affected_currentness_dimensions: candidate head identity (CI receipts now current). Implementation/stimulus/oracle unchanged since c2cdca591.
residual_assumptions_and_non_claims: RIPR-SPEC-0001 is a live example to replace; #7399 remains open.
disposition: REVIEW_READY
Summary
cargo xtask fixtures new <name>printed a step-4 bless command whose--reason "initial scaffold"is always rejected bygoldens bless, because bless reasons must cite an existing spec id. Step 4 now prints a copy-pasteable live spec example and tells the contributor to replace it viacargo xtask specs next.Closes #7398
Swarm / Source Boundary
This PR targets
EffortlessMetrics/ripr-swarm, the normal development trunk fortrusted same-repo
riprwork. Confirm the change belongs here:dependency, or repo-ops development for
ripr-swarmsurface
Source-of-truth Links
Proposal: n/a
Spec: n/a (xtask developer UX; no product spec change)
ADR: n/a
Plan item: n/a
Governing issue or accepted claim: #7398
Acceptance delta (one sentence): the printed
fixtures newstep-4--reasoncites a live spec id thatvalidate_bless_reasonaccepts, and points atcargo xtask specs nextto replace the example.Candidate Relationships
Candidate branch (GitHub PR head is authoritative after publication):
cursor/fixtures-new-bless-reason-e015Stack parent or prerequisite PR (if any): none
Proposed replacement of PR (if any; not yet accepted): none
Acceptance retained from a replaced candidate (if any): n/a
Accepted winner and losing candidate disposition (when decided): n/a
Scope
Only the step-4 next-actions text from
cargo xtask fixtures new, plus a unit test that extracts that printed--reasonand runs it throughvalidate_bless_reason.Scope Classification
This PR is scoped by:
Production delta:
fixtures_new_step4prints--reason "RIPR-SPEC-0001: initial scaffold"(a livedocs/specs/id, the same example the bless validator itself uses) and an instruction to replace it with the fixture's spec viacargo xtask specs next.Evidence/support delta:
fixtures_new_printed_bless_reason_passes_the_reason_validatorextracts the quoted--reasonfrom that production string and requiresvalidate_bless_reasonto accept it. The old bare"initial scaffold"remains a failing control.Single acceptance criterion:
fixtures newcites a spec id thatvalidate_bless_reasonaccepts.Non-goals:
fixtures newleavesSpec: RIPR-SPEC-NNNNthat passes the fixture gate but fails check-traceability with no pointer tospecs next#7399 (SPEC.mdplaceholderRIPR-SPEC-NNNN, fixture-contract vs traceability disagreement, extra numbered spec-assignment step). This PR does not changeSPEC.mdgeneration, fixture-contract validation, or step 5.goldens blessso emptyexpected/can skip a spec citation.Support-tier Impact
docs/status/SUPPORT_TIERS.mdClaim/proof notes:
Policy Impact
Ledger or exception notes:
Proof
cargo test -p xtask fixtures_new_printed_bless_reason_passes_the_reason_validator cargo xtask precommitResult, failures, or skipped proof:
cargo xtask precommitexited 0 on this working tree.Claim Boundary
What may be claimed after this PR? What must not be claimed yet?
RIPR-SPEC-0001) thatvalidate_bless_reasonaccepts.fixtures newleavesSpec: RIPR-SPEC-NNNNthat passes the fixture gate but fails check-traceability with no pointer tospecs next#7399 is fixed. Do not claim hosted CI or merge readiness from local precommit.Rollback
Revert this PR.
fixtures newreturns to printing--reason "initial scaffold".Spec-Test-Code Traceability
xtask/src/reports/fixtures.rsfixtures_new_printed_bless_reason_passes_the_reason_validatorxtask/src/reports/fixtures.rsfixtures_new_step4/fixtures_newStatic Language Check
killed,survived,untested,proven, andadequate.CI Economics
Engineering Check
panic,unwrap,expect,todo, orunimplementedin production code.panic,unwrap,expect,todo, orunimplementedin tests.Gates
Local
cargo xtask precommitran and exited 0. Hosted PR CI owns the merge-gate matrix.Exact candidate
c2cdca591fd7c93cf91828418d6ea74219e471c8origin/main(40a5de602)