Repository navigation
fix(agent): label mixed artifact-pair currentness truthfully (#3027) - #3053
Conversation
Resolve SPEC-0134 test-mapping and traceability conflicts as unions: the #3049 portable input-identity gates (input:v2 strict shape) and the #3027 truthful pair-currentness vocabulary both survive. cli_smoke fixture helpers now emit input:v2 identities, so the #3027 pair tests need no fixture edits.
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Review limit reached
Next review available in: 54 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (6)
Summary by CodeRabbit
WalkthroughThe change adds a shared classifier for all artifact currentness pairs. Agent verification and receipts use it. Tests, schemas, specifications, ADRs, traceability, and fixtures now cover the expanded labels. ChangesArtifact currentness reporting
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related PRs
Suggested labels: Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 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 |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0f71db98c3
ℹ️ 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".
EffortlessSteven
left a comment
There was a problem hiding this comment.
Exact-head review — REVIEW_READY
reviewed_head_sha: b1f98c5c (branch codex/issue3027-pair-currentness,
merge with main 3f7c9e53 + schema-0.3 repair)
integration_basis: origin/main 0cb57eaa (behind-only; three-dot diff is the
9-file #3027 delta + 6-file schema-bump delta, no conflicts)
claim_boundary: truthful closed pair-currentness vocabulary (#3027);
output-vocabulary change only, no validation-semantics change
changed_surfaces_and_semantic_owners_inspected:
- shared authority: agent::artifact::pair_currentness_label (single source
for verify + receipt; receipt's canonical byte comparison agrees by
construction)
- call sites: cli/commands/agent.rs, app/agent_receipt.rs (fallthrough
deleted at both)
- per-artifact mapping in verification_execution.rs untouched (truthful
dirty_worktree reservation verified)
- schema family: AGENT_VERIFY_SCHEMA_VERSION 0.2 -> 0.3 with fail-closed
0.2 rejection at the receipt gate, no migration path
- docs/spec/ADR/golden parity: OUTPUT_SCHEMA family table + closed token
list, RIPR-SPEC-0134, ADR-0020 amendment, editor-agent-loop golden
re-blessed (two one-field diffs: dirty_both, schema 0.3 — both verified
against actual renderer output)
blocking_findings: none
non_blocking_suggestions: none outstanding
refuted_or_stale_findings:
- codex P1 "preserve dirty state on historical artifacts": rejected with
counter-evidence — pre-existing classification collapse (85065f56),
token truthfully reports repository currentness, production-dirt stays
digest-bound in the envelope; axis split filed as design_question #3056.
Reply-backed, resolved.
- codex P1 "bump the verify schema": valid — repaired in b1f98c5c,
reply with commit+proof, resolved.
proof_and_ci_observed:
- required check Ripr Rust Small Result: pass on b1f98c5c; mergeStateStatus
CLEAN
- advisory: rust-tests-junit, rust-coverage, source-of-truth, ub-review,
codecov/patch, cargo-deny, dependency-review, pr-plan — pass
- CodeRabbit rate-limited again: recorded as missing review, not clean
- local gates re-run by reviewer on b1f98c5c: fmt, agent::artifact 39/39,
cli_smoke agent_ 43/43, goldens check — pass; clippy/xtask suites green
per candidate verification (inherited ETXTBSY flake #3051 noted twice,
passes on rerun, not caused by this diff)
proof_or_review_missing: CodeRabbit quota-limited (non-substantive); no
human-authored review thread on this PR
affected_currentness_dimensions: production implementation, test stimulus,
test oracle, public claim, integration basis, candidate head identity —
refreshed at b1f98c5c after the schema-bump repair
residual_assumptions_and_non_claims:
- two vocabulary cells (current, current_before_historical_after) are
unreachable through the CLI (movement/lineage gates) and stay truthful
in the shared mapping only
- 0.2 verify documents are rejected, not migrated
- review threads: 2/2 resolved with reply-backed adjudication
disposition: REVIEW_READY
COMMENT review per the author-review convention; GitHub's author limitation is not approval. Arming normal auto-merge.
Exact-head review recordDisposition: CHANGES_NEEDED Findings[MAJOR] docs/specs/RIPR-SPEC-0134-repair-artifact-provenance.mdThe spec (and the mirroring unit-test comment) states that a current-before/historical-after pair "fails the lineage gate" and is unreachable, but no gate in the production path rejects that pair; the claim asserts enforcement that does not exist. EvidenceAdded spec text: "A fully current pair fails the movement gate and a current-before/historical-after pair fails the lineage gate, so [MINOR] crates/ripr/src/output/outcome/mod.rsThe PR body's Non-goals still claim "no schema change" and its Gates section cites head 0f71db9, but the exact head b1f98c5 bumps AGENT_VERIFY_SCHEMA_VERSION 0.2 -> 0.3; the squash-merge description would therefore assert the opposite of what the head does, and no gate evidence is quoted for the head that made the change. EvidenceHead b1f98c5 ("fix(agent): bump agent verify schema to 0.3 ...") changes crates/ripr/src/output/outcome/mod.rs L37 to [MINOR] docs/OUTPUT_SCHEMA.mdNew prose calls EvidenceAdded text at L6389-6394: "A dirty side names the side ( [NIT] docs/OUTPUT_SCHEMA.mdThe agent verify JSON shape example still shows Evidencedocs/OUTPUT_SCHEMA.md L6308 (inside the Synthesisreviewed_head_sha: b1f98c5 (confirmed live via Production change is correct and well-owned. Oracle grip is real, not incidental. Mutation challenge: reverting the production hunk restores Golden re-bless verified as truthful, not convenient. Schema bump is sound and complete. Exact-head CI receipts are real, not aggregate-only. All checks pass at b1f98c5; I verified run head SHAs individually (Routed Rust Small 31248644113, Test Analytics 31248644126, Coverage 31248644127, Source of Truth 31248644078 — all b1f98c5). Rather than trust the green roll-up, I pulled job 93081313527 logs and confirmed the three new tests actually executed at that head: Review-evidence gaps, stated rather than papered over: CodeRabbit reports "Review rate limited" and is surfaced as Disposition CHANGES_NEEDED, and I want to be precise about why, because it is not a correctness objection. I found no blocking source, oracle, contract, or platform defect; the runtime behavior, tests, goldens, and schema handling are all sound and I would not hold the code. What I am holding is the committed claim layer. Finding 1 is the one I would not wave through: RIPR-SPEC-0134 is a governing spec, and it now asserts that the lineage gate rejects a pair that the lineage gate demonstrably admits. This repo treats "a gate whose stated contract exceeds its real enforcement" as a false-confidence surface on purpose, and the same sentence is duplicated into a test comment, so it will be read as verified fact by the next person reasoning about reachability. The cost to fix is one sentence in two files; the cost of merging it is a spec that lies about enforcement. Finding 2 matters because the PR body becomes the squash-merge message, and it currently denies the schema change that is the head commit's entire subject — a reader auditing the 0.2->0.3 break later would find the merge record contradicting the code. Findings 3 and 4 are the same family, smaller. All four are documentation/public-claim edits repairable in this candidate without touching production code or re-running the full gate set, after which only the affected currentness dimensions (public claim, spec) need refreshing — production implementation, test stimulus, test oracle, generated relationships, and integration basis all remain current and would not need re-proof. Surfaces inspected
|
|
Recorded post-merge: the review above landed after this PR merged as |
Production delta
The pair-level
artifact_currentnessinagent verify/agent receiptoutput mapped EVERY mixed pair — including the expected clean(Historical, Current)before/after transaction — todirty_worktree, even when neither worktree was dirty. Replaced with a truthful closed vocabulary computed by one shared authority,agent::artifact::pair_currentness_label, called from both renderers so the receipt's fail-closed canonical byte comparison always recomputes the token verify emitted:dirty_worktreestays reserved for per-artifact evidence (verification_execution.rsmapping untouched). There is deliberately nounavailabletoken: per-artifact validation always classifies before pair rendering, so no production path can produce one (recorded in a comment, not emitted as invented vocabulary).No validation-semantics change: comparability, lineage, movement, currentness classification, and the receipt byte comparison are exactly as before. Two cells (
current,current_before_historical_after) are unreachable through the CLI (movement/lineage gates) and stay truthful in the shared mapping.Evidence delta
agent::artifact::tests::pair_currentness_label_covers_the_closed_vocabulary— full 3x3 matrix.cli_smoke::agent_verify_and_receipt_disclose_historical_before_current_after_pair— the ux(agent): mixed historical/current pair currentness is mislabeled dirty_worktree #3027 motivating case through real verify, then the verify JSON feedsagent receiptand is accepted (receipt agrees; canonical byte comparison passes with the new token).cli_smoke::agent_verify_discloses_dirty_before_and_dirty_after_pairs— single-side dirty flips (recommitted) yielddirty_before/dirty_after./artifact_currentnessJSON-pointer assertions:(Historical, Historical) -> historical_noncurrent,(Dirty, Dirty) -> dirty_both(real dirty worktree).fixtures/boundary_gap/expected/editor-agent-loop/agent-verify.jsonre-blesseddirty_worktree -> dirty_both— the fixture genuinely declares both sides dirty; verified the actual-vs-expected diff was exactly this one field.Acceptance criterion
Closes #3027.
Non-goals
repair-assurance.schema.jsoncurrentness enums belong to the separate VerificationCurrentnessV1 axis and were verified unrelated).Gates (run on head 0f71db9, merged with main 3f7c9e5)
cargo fmt --all -- --check,cargo clippy --workspace --all-targets -- -D warnings,cargo test -p ripr --lib agent::artifact(39/39),cargo test -p ripr --test cli_smoke agent_(43/43),cargo test -p xtask reports::release(89/89 — after one rerun past the known inherited ETXTBSY flake #3051),cargo xtask goldens check,cargo xtask precommit— all pass.