Repository navigation
refactor(contract): found ripr-contract with domain DTOs behind the ripr facade (ADR 0025) - #12926
Conversation
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
…licy, and identity catalog
…ion to ripr-contract
EffortlessSteven
left a comment
There was a problem hiding this comment.
Exact-head review (author self-review, COMMENT disposition)
reviewed_head_sha: 1d8cb53677e7486e19c28f7f8989d3e4a653faac
integration_basis: origin/main 15579a490785e322f809082a964ef9e7002fa3fd (merge-base = base; branch is not behind in any material dimension)
claim_boundary: Found ripr-contract (domain DTOs + value_origins) behind the unchanged ripr::domain facade, per ADR 0025. Enabling slice only; no adapter split, no public API change, no memory-target claim beyond the recorded re-measurement.
changed_surfaces_and_semantic_owners_inspected:
- crates/ripr-contract (new crate: domain, value_origins, identity catalog/render, executed_control fixtures)
- crates/ripr/src/domain.rs facade (explicit per-item re-exports, no glob) + six hosted modules
- Feature forwarding (lang-rust/typescript/python/perl) between ripr and ripr-contract
- xtask gate path lists (output contracts, identity registry, output-enum contracts, capability producers, evidence-state literals, verification contracts, proof preflight/route fixtures)
- policy/architecture.txt domain rules (now cover both domain homes), policy/proof-packs.toml identity-registry pack, policy/public_api.txt record forms, policy/workspace_shape.txt
- Generated identity artifacts (docs/identity/registry.v1.json regenerated with the sanctioned RIPR_WRITE_IDENTITY_REGISTRY=1 writer)
blocking_findings:
- REPAIRED in 0901a4beee: check-identity-registry and check-output-contracts read moved domain files at their old crates/ripr/src/domain paths; identity catalog owner_path strings and generated registry were stale. All path lists, catalog strings, and the generated JSON now follow the moved files; both gates pass.
- REPAIRED in 1d8cb53677: identity-registry proof pack still routed on the old catalog path and one xtask test expected the pre-move `pub(crate)` tokenizer spelling. Both updated; the routed tests pass.
non_blocking_suggestions:
- The refusal-remedy corpus test in ripr-contract reads both crates' source trees (documented in the test); a future adapter split should keep that corpus definition honest in the same way.
refuted_or_stale_findings:
- "windows_cancellation_ends_a_pipe_inheriting_descendant fails": load-sensitive timing flake. Passes in isolation on this head (3/3), serially (18/18), and on the untouched base; fails only inside massively parallel batches on this host. Not candidate-caused; no product code changed for it.
- "xtask readiness/scale_cliff identity tests fail": same load class; pass in isolation and in a 30-test rerun on this head, and on base.
- "cargo check --no-default-features fails (629 errors)": identical error count on the untouched base; that feature combination was never a supported build. Default and default+lang-perl builds pass on both.
proof_and_ci_observed:
- cargo check --workspace-equivalent targets (ripr + ripr-contract, --all-targets) pass; cargo fmt --check pass
- ripr-contract tests: 299 passed. Facade affected batch: 380 passed, 1 ignored, 1 load-flake (above)
- Clippy -D warnings: ripr-contract (all targets, incl. test-fixtures feature) pass; ripr --lib --tests pass
- xtask gates pass: check-workspace-shape, check-architecture, check-public-api, check-traceability, check-spec-format, check-allow-attributes, check-dependencies, check-identity-registry, check-output-contracts, check-capabilities, check-covered-by, check-file-policy, check-fixture-contracts, check-rust-source-role-authority, check-static-language, check-doc-index, check-doc-artifacts
- cargo package --list for both crates at 0.11.0 (lockstep)
- Matched re-measurement (final head): 12,765,424 KiB = 13,071,794,176 bytes vs baseline 13,525,372,928 bytes (-453,578,752)
proof_or_review_missing:
- Hosted CI for the exact head (not yet requested; Draft). check-fast's workspace Clippy step cannot complete on this Windows host — 22 pre-existing platform errors reproduced identically on the untouched base — so the hosted Linux lane owns that step.
affected_currentness_dimensions: production implementation (move only), test stimulus (three helper forms changed, assertions unchanged), public claim (facade list explicit; 9 allowlist record forms), generated relationships (identity registry regenerated), integration basis (unchanged main), head identity (1d8cb53677)
residual_assumptions_and_non_claims: This slice does not claim progress toward closing the 8 GB gap beyond the recorded 3.4%; #12726 remains open, #12719 remains anchor none / 0 of 20, and no publishing action is taken or authorized by this PR.
disposition: REVIEW_INCOMPLETE — source and focused-proof review complete with repairs landed; awaiting hosted exact-head CI before final REVIEW_READY and merge convergence.
|
|
…crate # Conflicts: # crates/ripr-contract/src/domain/mod.rs
…the candidate inside admission scope
EffortlessSteven
left a comment
There was a problem hiding this comment.
SOURCE_REVIEW_READY
Refreshed exact-head source review (author self-review, COMMENT disposition):
reviewed_head_sha: 81b2750301aea9ce7cd1fd6f8c7cfbf42f35609f
integration_basis: origin/main 0244de7dcc67f825b5b43f967aedbb6e103dd2d2 (merged in 6c78b77845; GitHub reports MERGEABLE)
claim_boundary: Found ripr-contract (domain DTOs + value_origins) behind the unchanged ripr::domain facade, per ADR 0025. Enabling slice only; no adapter split, no public API change.
refresh since the 1d8cb53677 review:
- Merge of current main: its three new domain modules (project_facts, typescript_oracle_seam, typescript_preview_related_test) joined the contract with facade re-exports; contract tests now 302 before the language_availability move, 289 after.
- language_availability is facade-hosted (real file at crates/ripr/src/domain/language_availability.rs, unchanged from main) instead of living in the contract, keeping the candidate inside admission scope (145 files / 2335 changed lines vs the 160 / 3000 ordinary limit) and preserving the original public-API record kinds.
- All checks below were re-run on the merged/recomposed tree.
blocking_findings: none outstanding. The two gate defects found in the first review wave (xtask/identity-catalog path lists; proof-pack routing + tokenizer spelling) are repaired and their gates pass.
proof re-run on this head:
- cargo check -p ripr -p ripr-contract --all-targets: pass
- ripr-contract lib tests: 289 passed
- xtask gates pass: check-public-api, check-traceability, check-identity-registry, check-output-contracts, check-architecture, check-workspace-shape, check-allow-attributes, check-capabilities, check-covered-by, check-file-policy, check-fixture-contracts, check-rust-source-role-authority, check-static-language, check-doc-index, check-doc-artifacts
- Final matched re-measurement is being recorded on #12726 for this head (prior heads: 27e981c 13,071,835,136 bytes; merged 6c78b77 13,348,675,584 bytes including main's new code; baseline 13,525,372,928 bytes).
known load flakes (classified, unchanged): windows_cancellation_ends_a_pipe_inheriting_descendant and the readiness/scale_cliff xtask tests fail only inside massively parallel batches on this Windows host and pass in isolation on base and candidate; do not read a batch failure of exactly those names as a product regression without an isolated rerun.
non_claims: no 8 GB target claim beyond the recorded measurements; #12726 stays open; #12719 stays anchor none / 0 of 20; no publishing action.
disposition: SOURCE_REVIEW_READY for qualification request. Final merge judgment still requires the hosted exact-head result below.
EffortlessSteven
left a comment
There was a problem hiding this comment.
SOURCE_REVIEW_READY
EffortlessSteven
left a comment
There was a problem hiding this comment.
REPAIR_REQUIRED
Independent source review bound to head 81b2750301aea9ce7cd1fd6f8c7cfbf42f35609f, base 0244de7dcc67f825b5b43f967aedbb6e103dd2d2 (rechecked unchanged immediately before posting).
Two actionable findings are attached: the schema-version scanner retains the old visibility spelling, and the new production dependency does not enforce ADR 0025's exact lockstep requirement.
Observed evidence: fetched frozen source and compared the two scanner prefixes against head and base. The scanner's literal split/extract operation returns zero versions at head for both moved constants, one version at base, and one correct version at head when only pub(crate) is changed to pub in the prefix. This is a narrow source-level reproduction, not execution of the full Cargo gate. Cargo's documented version-requirement semantics confirm that 0.11.0 allows >=0.11.0, <0.12.0; ADR 0025 explicitly requires = pins.
Inspected: facade exports, moved-module diffs and helper changes, feature forwarding manifests, packaging ADR/manifests, identity proof-pack path update, changed traceability/policy path readers, current comments/review threads. Existing public root names remain re-exported; this statement is not a complete public-API or test-identity equivalence proof.
Limits: no full compile, packaging or test suite was rerun; no hosted qualification was launched or duplicated; reported author test results were not treated as independent execution evidence. Formal approval and merge readiness are not claimed. Re-run cargo xtask check-verification-contracts and the focused verification_contracts tests after repairing both prefix literals, and verify the normalized production dependency is exactly =0.11.0.
EffortlessSteven
left a comment
There was a problem hiding this comment.
REPAIR_REQUIRED — additional executed CI evidence (technical COMMENT, not approval)
Head rechecked unchanged: 81b2750.
CI run 41802163413, Rust-only feature lane completed with exit 101. The executed command was cargo test -p ripr --locked --no-default-features --features lang-rust --no-fail-fast. This includes the supported lang-rust feature; it is not the earlier no-feature compile attempt.
The job actually checked out merge 3a95ed8, merging this head into 075e4e8.
Four targets reported 14 runtime assertion failures:
ripr --lib: 10, includingdoctor_no_suggestion_when_typescript_adapter_not_compiled,languages_section_rejects_unavailable_python_adapter,languages_section_rejects_unavailable_typescript_adapter, andrust_only_build_reports_no_unavailable_python_row_for_a_changed_py_file.agent_stub_at_disclosure:python_marker_without_config_keeps_feature_admission.cli_smoke:doctor_combined_ordinary_path_with_enablement_tip_fits_one_screenanddoctor_json_carries_every_environment_fact_the_human_screen_prints.doctor_json_schema:doctor_json_conforms_to_the_published_schema.
Examples in the logs: TypeScript/Python configurations were accepted where the tests expected missing-feature refusals; doctor output reported a compiled Python adapter and an enablement suggestion where the Rust-only tests expected no adapter/suggestion.
These are observed test failures, not a compile/setup failure. Root cause and candidate-versus-base attribution are not established here. The separate required request 41802163205 is still running its test shards; its Rust-gates success does not resolve these assertions or the two existing source-review findings. No duplicate checks were launched.
…nto facade test builds
EffortlessSteven
left a comment
There was a problem hiding this comment.
REPAIR_REQUIRED — required shard package-qualification failure (technical COMMENT)
Head rechecked unchanged: 81b2750.
Required request 41802163205, shard 2 job 126504109291 failed at 10:02 UTC. Its actual checkout was 3a95ed8, merging this head into 075e4e8.
The failing test is xtask::ripr_public_guide_contract::packaged_help_target_runs_every_case_and_rejects_missing_shared_asset. Its source-package creation exited 101: no matching package named ripr-contract found, searching the crates.io index while packaging ripr v0.11.0 in offline mode.
The shard ran 5,521 of its 6,842 selected tests: 5,520 passed and 1 failed before fail-fast. It therefore does not establish complete shard coverage. Other shards and the final required result were still pending when checked.
This records a non-publishing package-qualification failure. It is not a suggestion or authorization to publish ripr-contract, change registry state, or bypass the package test. No rerun or new campaign was launched.
EffortlessSteven
left a comment
There was a problem hiding this comment.
SOURCE_REVIEW_READY
|
|
…crate # Conflicts: # crates/ripr/src/domain/mod.rs # docs/adr/README.md
EffortlessSteven
left a comment
There was a problem hiding this comment.
SOURCE_REVIEW_READY
|
Packaged-corpus follow-up at current head Independent source-emulation counted 685 retained messages from the contract-only source tree using the corpus literal selection, versus the unchanged 1,000-message minimum at refusal_remedy_corpus_tests.rs:481. When This count was independently computed by source emulation, not an executed Cargo test or packaged-crate run. Workspace success therefore does not resolve the packaged-corpus coverage policy. This refines the earlier packaged-corpus concern; the owner’s absence guard is present, but the threshold remains to be reconciled with the intended package coverage. Existing ownership, readiness and running qualification are unchanged. |
There was a problem hiding this comment.
Verification questions
- Confirm the package regression identifies the ripr archive by filename prefix rather than an explicit package artifact identity.
- Confirm the packaged-help test now selects both interdependent packages, but identifies the ripr archive by filename-prefix heuristic rather than an explicit artifact identity.
Refuted
- The contract crate publicly exposes every domain module, contradicting the ADR statement that support-crate APIs are not a public contract.
- The facade exposes
context_packet,guarded_edit, andlanguage_availabilityas public submodules, so it is not solely an item-by-item domain facade and direct submodule paths remain reachable.
Evidence gaps
- Source-wide proof is incomplete because the RIPR sensor failed and the scheduled cargo-test receipt is absent.
- Model proof intent was rejected by deterministic validation.
- Current-head executable qualification is incomplete, leaving packaging resolution and full workspace regressions for central verification.
- The current packet does not establish current-head executable correctness.
- Relocated executed-control and intervention-study tests are not covered by the shown policy proof pack.
Parked follow-ups
- Package/archive selection is a parked verification concern: two crates are packaged and the ripr archive is selected by filename heuristic, so no new public issue is inferred from this lane.
- The support crate is itself published with public modules and many newly public items despite being described as implementation-only.
- The contract crate publicly exposes its domain modules, creating a second public package surface beyond the documented ripr facade boundary.
#5163) Rebuilt on main 8ec1a0d after the ripr-contract split (#12926): the plan DTOs live in ripr-contract and are re-exported item by item from ripr::domain. The digest check is a free function in ripr (the contract crate must not own JSON/canonical rendering). The debug-only plan projections return early in release builds. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SvmPmoZuRCYSP9TnjVqQjW
Summary
ripr-contract, the first ADR 0027 internal support crate: thedomainDTO compartment (54 files, ~23.5k lines) andvalue_originsmove out of the monolithicriprrustc unit, behind the unchangedripr::domainfacade.riprpackage, internal support crates published in lockstep (same version, exact requirements), public API unchanged. ADR 0001's packaging clause is superseded; its module seams remain.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
If this PR moves crates.io publishing, VS Marketplace publishing, Open VSX
publishing, GitHub Release assets, signing, release environments, or release
secrets, close or retarget it. Those surfaces belong in
EffortlessMetrics/riprunless a dedicated release-boundary change has already been approved.
Source-of-truth Links
Proposal: #8382 (crate-split architecture carrier)
Spec: docs/specs/RIPR-SPEC-0026-language-adapter-contract.md (adapter result shells this contract hosts)
ADR: docs/adr/0027-one-user-facing-package-lockstep-support-crates.md (new; supersedes ADR 0001 packaging clause)
Plan item: #12726 Phase 5/6 �^C�� contract extraction before the first adapter split
Governing issue or accepted claim: #12726 (measured defect), #8382 (architecture carrier)
Acceptance delta (one sentence):
domaincompiles as the separateripr-contractrustc unit with everyripr::domainpath, assertion, and test identity preserved, and the matched largest-rustc re-measurement is recorded below.Candidate Relationships
Candidate branch (GitHub PR head is authoritative after publication):
agent/12726-contract-crateStack parent or prerequisite PR (if any): none (baseline and compartment map are recorded on #12726)
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
crates/ripr-contract(published in lockstep,version.workspace);riprdepends on it with an exact-version path dependency anddefault-features = false, forwardinglang-rust/lang-typescript/lang-python/lang-perlso language enablement is identical.crates/ripr/src/domain.rsbecomes the facade: every formerpub/pub(crate)domain item is re-exported by name at its established path (no glob;check-public-apirecords the same 154 root entries, plus 9language_availabilityentries whose record form changes from declaration kind topub usebecause the declaration now lives in the contract crate �^C�� names unchanged).riprbecause they consume analysis/agent/app helpers that have not moved:context_packet,diagnostic_witness,next_action,fix_instruction,repair_card,verification_result.domain::executed_control::testsfixtures compile under the contract'stest-fixturesfeature (enabled byripr's dev-dependency only); threeinclude_str!source readers and traceability/spec path records follow the moved files.policy/workspace_shape.txtallowlists the new member/manifest with the ADR 0027 reason;AGENTS.mdarchitecture text follows ADR 0027.Scope Classification
This PR is scoped by:
Production delta:
domain+value_originsintoripr-contract; three test-only helpers change form, not assertions: acfg(test)inherentimpl Findingincontext_packettests becomes a free function (orphan rule across crates), andcells_for/example_preregistered_studyare compiled unconditionally in the contract because facade tests import them.Evidence/support delta:
Single acceptance criterion:
Non-goals:
Support-tier Impact
Claim/proof notes:
Policy Impact
Ledger or exception notes:
policy/workspace_shape.txt: new member + manifest rows citing ADR 0027.policy/public_api.txt: 9language_availabilityentries change record form (declaration kind �^C��pub use), names and reachability unchanged. No allowlist exceptions added (the two candidate#[allow]suppressions were removed by fixing the underlying warnings).Proof
Result, failures, or skipped proof:
app::verification_execution::tests::windows_cancellation_ends_a_pipe_inheriting_descendantfails only inside the massively parallel batch on this Windows host ("descendant never started", 2 s cancellation window). It passes in isolation on this candidate (3/3), in a serial module run (18/18), and on the untouched base (1/1, and 395-test base batch). Classified as a load-sensitive timing flake, not candidate or inherited product failure; no product code changed for it.cargo xtask check-fastreaches its workspace Clippy step and fails there on 22 pre-existing Windows-platform errors inxtask'sexact_candidate_harness/termination_qualification�^C�� reproduced identically on the untouched base (15579a4), so inherited and environmental; the hosted Linux lane owns that step. Every check-fast gate before Clippy (selector, fmt, allow-attributes, no-panic) passes.RUSTC_WORKSPACE_WRAPPER+ GNUtimeattribution as the baseline): baseline at15579a4was 13,208,372 KiB = 13,525,372,928 bytes (13.525 GB / 12.596 GiB); the final candidate head1d8cb53677measures 12,765,424 KiB = 13,071,794,176 bytes (13.072 GB / 12.174 GiB), a reduction of 453,578,752 bytes (3.4%), wall 519 s vs 493 s. This slice is enabling work and was not expected to close the gap; 5,071,794,176 bytes remain above the 8,000,000,000-byte target, which is the TypeScript slice's job. Review repairs after the first measurement (gate path lists, identity catalog strings, policy records) moved the result by only 40 KiB.Claim Boundary
What may be claimed after this PR? What must not be claimed yet?
Rollback
How can this PR be reverted safely?
domain(all moves are git renames behind the same paths). Nothing was published; no registry state exists to unwind.Spec-Test-Code Traceability
ripr_contractlib-test binary (299 tests, names unchanged); facade tests import fixtures viatest-fixtures.crates/ripr-contract,crates/ripr/src/domain.rsfacade, six hosted modules listed under Scope.docs/LEARNINGS.mdalready records the diffuse-compiler conclusion this follows.Static Language Check
killed,survived,untested,proven, andadequate.CI Economics
Complete this section when the PR changes workflows, policy gates, branch
protection expectations, CI artifacts, report uploads, release checks, or the
cost/posture of existing lanes. Use
n/afor ordinary PRs that do not affectCI behavior.
Engineering Check
panic,unwrap,expect,todo, orunimplementedin production code.panic,unwrap,expect,todo, orunimplementedin tests.Gates
cargo fmt --checkcargo check --workspace --all-targetscargo test --workspace(hosted lane; focused local subsets above)cargo clippy --workspace --all-targets -- -D warnings(hosted Linux lane; Windows base fails identically �^C�� see Proof)cargo doc --workspace --no-depscargo package -p ripr --listcargo publish -p ripr --dry-runcargo xtask check-static-languagecargo xtask check-doc-artifactscargo xtask check-support-tierscargo xtask check-no-panic-familycargo xtask check-allow-attributescargo xtask check-local-contextcargo xtask check-file-policycargo xtask check-covered-bycargo xtask check-executable-filescargo xtask check-workflowscargo xtask check-spec-formatcargo xtask check-spec-numberingcargo xtask check-fixture-contractscargo xtask check-generatedcargo xtask check-badge-diff-policycargo xtask check-generated-cleancargo xtask check-dependenciescargo xtask check-process-policycargo xtask check-network-policyExtension changes:
cd editors/vscode && npm cicd editors/vscode && npm run compilecd editors/vscode && npm run package