Repository navigation
Warn when gap-ledger repo-exposure input has no artifact envelope - #9570
Conversation
item a) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Dpu1AbBoAbyviXbo3msrWD
|
Warning Review limit reachedEnable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Next included review available in 9 minutes. View limit details
Comment |
There was a problem hiding this comment.
Code Review
This pull request adds a warning to ripr reports gap-ledger --repo-exposure when the input lacks an artifact envelope, ensuring that unvalidated producer identity and currentness are flagged. It also includes a corresponding unit test and changelog entry. The review feedback suggests simplifying the JSON check in gap_decision_ledger.rs by using direct subscript indexing on serde_json::Value instead of .get().is_some_and(), which is safe and cleaner.
…item a) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Dpu1AbBoAbyviXbo3msrWD
There was a problem hiding this comment.
Decision
- Needs reviewer attention before upstream: findings remain.
Confirmed findings
- The envelope predicate accepts any artifact object, not a valid repo-exposure envelope.
- Negative-direction coverage is thin: only one enveloped shape is tried (artifact as object). Cases like missing source_value_snapshot, source_kind != RepoExposure, or artifact present but non-object (e.g., string/number) are not asserted; the gate
!source_value_snapshot.as_ref().is_some_and(\|v\| v.get("artifact").is_some_and(Value::is_object))is the actual contract and is not pinned by a dedicated test.
Refuted
- The warning predicate is overbroad or treats malformed/non-enveloped artifact values as valid envelopes.; refuted because: It is restricted to parsed-clean RepoExposure inputs and requires the artifact member to be an object; malformed JSON does not reach it, while missing or non-object artifact values warn.
Parked follow-ups
- Existing renderer coverage plus the warning's use of the established warnings list is sufficient, though this PR does not add a case-specific rendered assertion.
Evidence gaps
- The repository sensor failure leaves the behavioral claim without a confirmed local receipt, but the provided diff does not substantiate a source defect.
- Model proof intent was rejected by deterministic validation.
… a warning in #9570 (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh
…gn producer.version in agent verify (#9500 b,c) (#9632) * fix(agent): refuse unenveloped/foreign-producer repo-exposure on gap-ledger and verify; bind recovery to running binary (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh * test(cli): gap-ledger repo-exposure envelope refusal through the binary (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh * fix(agent): keep the program-bound repo-exposure command reachable from xtask (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh * refactor: drop gap-ledger refusal; item (a) was delivered upstream as a warning in #9570 (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh * fix(agent): version-independent test fixtures and spec/schema parity for the exact producer-version check (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh * docs: drop ledgers from the 9500 changelog entry; the gap-ledger route is unchanged (#9500) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018HD9fbAVQpnXMUzif6Y2oh --------- Co-authored-by: Claude <noreply@anthropic.com>
Summary
ripr reports gap-ledger --repo-exposurenow adds a warning when the input has noartifactenvelope, since producer identity and currentness are then unvalidated. With records present the status becomesadvisory_with_warnings; an empty input keepsno_recordsplus the warning. Decision: warn rather than refuse, to keep existing consumers working; rationale recorded on agent artifacts: gap-ledger accepts unenveloped legacy artifacts; bareriprrecovery command; forged producer.version passes verify #9500.Swarm / Source Boundary
ripr-swarmSource-of-truth Links
Proposal: n/a
Spec: docs/specs/RIPR-SPEC-0046-gap-decision-ledger.md
ADR: n/a
Plan item: n/a
Governing issue or accepted claim: #9500 item (a)
Acceptance delta (one sentence): An unenveloped repo-exposure input to the gap ledger yields an explicit warning, and an enveloped one does not.
Candidate Relationships
Candidate branch (GitHub PR head is authoritative after publication): claude/gap-ledger-unenveloped-warning
Stack parent or prerequisite PR (if any): none
Proof
cargo test -p ripr --lib output::gap_decision_ledger(116 pass), including newunenveloped_repo_exposure_input_warns_and_enveloped_does_not;check-traceability,check-spec-format,check-doc-artifactspass.goldens checkcould not run offline (anyhow download); hosted CI is the proof there.🤖 Generated with Claude Code
https://claude.ai/code/session_01Dpu1AbBoAbyviXbo3msrWD