Skip to content

fix(dx-scoreboard): require typed limitations array before complete admission - #7284

Merged
EffortlessSteven merged 1 commit into
mainfrom
cursor/typed-limitations-admission-40e5
Oct 10, 2026
Merged

EffortlessSteven merged 1 commit into
mainfrom
cursor/typed-limitations-admission-40e5

Conversation

@EffortlessSteven

@EffortlessSteven EffortlessSteven commented Oct 10, 2026 •

Copy link
Copy Markdown
Member

Summary

Complete-kind DX scoreboard admission treated a missing, non-array, or kind-less analysis_outcome.outcome.limitations value as “no incomplete limitations,” so omitted, object-valued, and [{}] envelopes could admit as complete work.

This PR requires a present typed array whose every entry has a string kind before applying the complete-kind allowlist. Empty [] and eol_only_churn still admit. producer_failure still rejects.

Closes #7276 (Advances #3794/#5363). Residual of #7259 / #7271; not a live producer hole.

Exact candidate SHA: 5755a247453e90837a24a194d9d5d2b561d3ba6c.

Swarm / Source Boundary

This PR targets EffortlessMetrics/ripr-swarm, the normal development trunk for
trusted same-repo ripr work. Confirm the change belongs here:

  • ordinary feature, analyzer, editor, docs, spec, fixture, badge,
    dependency, or repo-ops development for ripr-swarm
  • repair or follow-up for a same-repo swarm PR
  • swarm-only CI, runner, routing, source-of-truth, or agent-operating
    surface
  • other swarm-scoped work:

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/ripr
unless a dedicated release-boundary change has already been approved.

Source-of-truth Links

Proposal:
Spec: native check JSON / analysis-outcome producer contract (producer already emits a typed limitations vector)
ADR:
Plan item:
Governing issue or accepted claim: #7276; parents #3794 / #5363; reuse #5299 and the #7259/#7271 admission predicate
Acceptance delta (one sentence): A complete kind cannot admit unless outcome.limitations is a present array of entries that each carry a string kind.

Candidate Relationships

Candidate branch (GitHub PR head is authoritative after publication): cursor/typed-limitations-admission-40e5
Stack 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

All-state search for #7276, complete_kind_has_incomplete_limitation, and typed limitations array found no equivalent owner. Neighbor fences respected: no measure.rs (#7275 / #7283); no files from #7281/#7282; no check.rs / output/json / triage.rs (#7258); no #7273/#7274/#7277.

Scope

One local xtask admission predicate in the existing DX scoreboard consumer. Do not copy private AnalysisLimitation into xtask.

Scope Classification

This PR is scoped by:

  • One production behavior
  • One public contract
  • One architectural seam
  • Docs/spec/test-only evidence package
  • Other:

Production delta:

  • complete_kind_has_incomplete_limitation fail-closes unless limitations is an array.
  • Every array entry must have a string kind before the eol_only_churn allowlist is applied.
  • Omitted, object-valued, [{}], and non-string kind values reject complete admission.
  • Empty [] and eol_only_churn still admit; producer_failure still rejects with the existing allowlist reason.

Evidence/support delta:

  • Discriminator omitted_object_and_kindless_limitations_cannot_admit_as_complete exercises admit_check_document.
  • Old flatten is retained as permissive_complete_kind_limitation_flatten so restoring it fails the discriminator.
  • Changelog fragment changelog.d/7276-typed-limitations-admission.md.

Single acceptance criterion:

  • Injected omitted / object / [{}] limitations cannot admit as complete; restoring the flatten helper as the production predicate would fail the discriminator; [] and eol_only_churn still admit; producer_failure still rejects.

Non-goals:

Support-tier Impact

  • none
  • updates docs/status/SUPPORT_TIERS.md
  • changes a README, release, docs, CLI, JSON, editor, CI, or package claim

Claim/proof notes:

  • Internal xtask measurement honesty only. Does not change public check JSON or support tiers.

Policy Impact

  • none
  • doc artifacts
  • CI lane
  • package boundary
  • lint / Clippy
  • no-panic
  • file policy
  • generated artifact
  • dependency
  • process/network

Ledger or exception notes:

  • Local admission still uses existing serde_json already in xtask.

Proof

# Inherited baseline on origin/main 5d8893478 before mutation:
# cargo xtask worktree doctor → pass
# cargo xtask check-fast → 6 gates / 0 files / skipped clippy+4
# cargo check -p xtask --all-targets → pass
# Defect still present: omitted limitations admitted as Complete

# Pre-repair red on the discriminator (tests added, production still flattening):
cargo test -p xtask omitted_object_and_kindless_limitations_cannot_admit_as_complete
# FAILED: expected rejection, got Complete { kind: "complete_with_findings" }

# Post-repair on 5755a247453e90837a24a194d9d5d2b561d3ba6c:
cargo test -p xtask reports::dx_scoreboard::measure::check_admission
# 10 passed, including omitted_object_and_kindless_limitations_cannot_admit_as_complete
cargo test -p xtask reports::dx_scoreboard
# 82 passed
cargo xtask precommit
# pass, including cargo fmt --check
cargo xtask check-fast
# ran 10 gate(s), skipped 1 (check-fixture-contracts), base=origin/main, 2 file(s) changed
# independent git diff --name-only origin/main...HEAD:
#   changelog.d/7276-typed-limitations-admission.md
#   xtask/src/reports/dx_scoreboard/measure/check_admission.rs

Result, failures, or skipped proof:

  • Pre-repair red observed: omitted limitations admitted as Complete.
  • Focused admission tests (10) and reports::dx_scoreboard (82) passed on 5755a2474.
  • precommit passed. check-fast selected the same 2-file set independently resolved from origin/main...HEAD; clippy ran as part of that set.
  • Hosted Ripr Rust Small Result runs on Draft → Ready for this head.

Claim Boundary

What may be claimed after this PR? What must not be claimed yet?

  • May claim: complete-kind warm-check samples now require a typed limitations array with a string kind on every entry; omitted / object / kind-less entries cannot improve complete-work baselines; empty arrays and eol_only_churn still admit; producer_failure still rejects.
  • Must not claim: a live producer hole (the real check JSON writer already emits a vector); that private ripr validators are now a public API; analyzer correctness; runtime mutation results; support-tier or release readiness; that this is a general JSON schema validator.

Rollback

How can this PR be reverted safely?

  • Revert the squash commit. Only xtask dx-scoreboard admission + changelog fragment change. No schema, analyzer, CI, or Cargo.toml delta.

Spec-Test-Code Traceability

  • Spec: dx-scoreboard: require a typed limitations array before complete admission #7276 acceptance; native check JSON / analysis-outcome producer contract
  • Tests: xtask/src/reports/dx_scoreboard/measure/check_admission.rs::omitted_object_and_kindless_limitations_cannot_admit_as_complete
  • Code: xtask/src/reports/dx_scoreboard/measure/check_admission.rs
  • Golden outputs: none
  • Metrics: existing speed.warm_check_* admission tightened; no new metric
  • ADR/learning: local xtask predicate kept over copying AnalysisLimitation into xtask

Static Language Check

  • Static output avoids killed, survived, untested, proven, and adequate.
  • Unknowns include stop reasons where applicable.

CI Economics

  • LEM impact: n/a
  • Workflows touched: n/a
  • Branch protection impact: n/a
  • Failure mode caught: n/a
  • Cheaper signal considered: n/a
  • Required lanes affected: n/a
  • Advisory lanes affected: n/a
  • On-demand/release lanes affected: n/a
  • Labels that alter behavior: n/a
  • Artifact families affected: n/a
  • Rollback path: n/a

Engineering Check

  • No new panic, unwrap, expect, todo, or unimplemented in production code.
  • No new panic, unwrap, expect, todo, or unimplemented in tests.
  • New non-Rust programming files are allowlisted with owner, surface, and reason.
  • New generated, dependency, process-spawn, or network surfaces are allowlisted with owner and reason.
  • Errors are reported with actionable context.
  • Public JSON/schema changes are documented.

Gates

Local focused suite and precommit passed on 5755a2474. Hosted merge-gate matrix owns required checks. The required Ripr Rust Small Result check runs on Draft → Ready.

Open in Web Open in Cursor 

…dmission

Complete-kind warm-check admission no longer treats omitted, non-array, or
kind-less outcome.limitations as an empty allowlist. Empty arrays and
eol_only_churn still admit; producer_failure still rejects.

Closes #7276

Co-authored-by: Steven Zimmerman, CPA <EffortlessSteven@users.noreply.github.com>
@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 Oct 10, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: f7378b18-b529-469b-83ec-725c53a8b2c5


📥 Commits

Reviewing files that changed from the base of the PR and between 7aafeee and 5755a24.



📒 Files selected for processing (2)
  • changelog.d/7276-typed-limitations-admission.md
  • xtask/src/reports/dx_scoreboard/measure/check_admission.rs


🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:



Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 4 remain after this review.




Summary by CodeRabbit

  • Bug Fixes
    • Complete-kind admission on the DX scoreboard now requires limitations to be an array, with every entry containing a string kind.
    • Missing or non-array limitations, entries without a kind, and limitation kinds other than eol_only_churn are rejected, preventing them from improving the complete-work baseline.
    • Empty arrays and arrays containing only eol_only_churn remain admissible.

Walkthrough

The DX scoreboard now requires limitations to be an array with a string kind on every entry before admitting complete work. Only eol_only_churn is allowed as a limitation kind. Tests cover malformed values and accepted cases.

Changes

Complete-kind admission

Layer / File(s) Summary
Validate limitations before admission
xtask/src/reports/dx_scoreboard/measure/check_admission.rs, changelog.d/7276-typed-limitations-admission.md
The predicate rejects missing or non-array limitations and entries without a string kind, and returns a specific rejection reason. Tests cover these cases and confirm that an empty array and eol_only_churn remain admissible, while producer_failure is rejected. The changelog records the admission requirements.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to 5755a

No actionable merge-blocking issue is identified; the change is mergeable after normal checks.

Security Architecture Review

Security architecture risk: ⚪ Minimal · up to 5755a

The change rejects malformed completion evidence without adding callers, privileges, or external access. Valid typed output remains compatible, and rejected samples cannot appear as complete work or clean trust results.

Retained concerns
No architecture-level concerns identified.

Security review details

Security Blast Radius

  • inferred — The demonstrated exposure change is confined to scoreboard classification and trust-scan eligibility for malformed child output. The inspected comparison does not expand transport reachability, execution authority, credentials, or persistent-state ownership.

Security Findings and Attack Paths

  • observed — The malformed-limitations admission path existed in the base. The PR closes that path: otherwise qualifying documents with omitted, object-valued, or kindless limitations now fail admission and cannot improve the complete-work population or supply a clean measured trust result.

Trust Boundaries and Controls

  • observed — The routed public-entrypoint label describes a crate-local function, not a newly exposed service endpoint. Its module remains private, and its re-export from measure.rs is test-only. Child-produced JSON continues to pass through local validation before it influences completion and trust metrics.

Pre-merge checks | Passed 4 | Failed 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 60.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 10 functions across 1 files. (1 skipped: … Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check Passed Issue #7276 requires a present analysis_outcome.outcome.limitations array with a string kind on every entry before complete admission. complete_kind_has_incomplete_limitation now rejects missing…
Out of Scope Changes check Passed The reported changes are limited to xtask/src/reports/dx_scoreboard/measure/check_admission.rs and the #7276 changelog fragment. They add the required admission gate and focused tests. No analyzer, …
Title check Passed The title clearly and concisely identifies the main change: requiring a typed limitations array before DX scoreboard complete admission.
Description check Passed The description follows the repository template and provides the scope, acceptance criterion, relationships, proof, traceability, claim boundary, rollback plan, and engineering checks. It also documen…

Full details: Docstring Coverage

Explanation

Docstring coverage is 60.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 10 functions across 1 files. (1 skipped: 1 unsupported.)


  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR



🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR



  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

A rabbit checks each kind with care,
And finds the missing fields laid bare.
Empty arrays may pass the gate,
eol_only_churn may still wait.
Other kinds are turned away,
While tests keep watch along the way.

Comment @coderabbitai help to get the list of available commands.

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

review-pr (author self-review, COMMENT)

GitHub cannot request changes from the author; this is not approval.

reviewed_head_sha: 5755a247453e90837a24a194d9d5d2b561d3ba6c
integration_basis: origin/main 5d889347851db00c63f5ec31c4ef76c44d40ad73
claim_boundary: #7276 — complete-kind admission requires a present typed limitations array whose every entry has a string kind; [] and eol_only_churn still admit; producer_failure still rejects. Local xtask predicate only.
changed_surfaces_and_semantic_owners_inspected:
  - xtask/src/reports/dx_scoreboard/measure/check_admission.rs::complete_kind_has_incomplete_limitation and admit_check_document call site (admission owner)
  - changelog.d/7276-typed-limitations-admission.md
  - consumers: measure.rs still only calls admit_check_sample/admit_check_document (not edited; #7275/#7283 fence)
  - non-owners confirmed untouched: scan_check_contradictions (#7277), portable_root (#7274), measure.rs (#7275), analyzer/public schema
blocking_findings: none in source/oracle on this head
non_blocking_suggestions: none in-claim
refuted_or_stale_findings: none yet (no bot threads on this head)
proof_and_ci_observed:
  - pre-repair red: omitted limitations admitted as Complete
  - cargo test -p xtask reports::dx_scoreboard::measure::check_admission: 10 passed
  - cargo test -p xtask reports::dx_scoreboard: 82 passed
  - cargo xtask precommit: pass
  - cargo xtask check-fast: 10 gates, 2 files, skipped check-fixture-contracts; matches independent origin/main...HEAD path set
proof_or_review_missing: hosted required checks (Ripr Rust Small Result / merge gate) and any external review providers — not yet current on this published head
affected_currentness_dimensions: production implementation, test stimulus, test oracle, public claim (changelog). integration basis and candidate head identity bound above. generated/conflict: n/a
residual_assumptions_and_non_claims: not a live producer hole; not a copy of AnalysisLimitation; not a general schema validator; incomplete kinds still rejected by kind, not this predicate; trust-row tightening remains #7277
disposition: REVIEW_INCOMPLETE

Maintainer lens

Diff is the named seam plus a changelog fragment. Did not copy private ripr validators, did not touch measure.rs / check.rs / output/json / triage.rs, did not take #7273/#7274/#7275/#7277. Distinct reject reasons (missing array vs missing string kind vs allowlist) stay inside the local predicate and make the discriminator distinguish shape failure from producer_failure.

Test/oracle lens

Discriminator calls admit_check_document (retained production authority). Old flatten is retained as permissive_complete_kind_limitation_flatten so restoring the hole fails. Controls: omitted, object, [{}], non-string kind, mixed eol_only_churn+kindless reject; [] and eol_only_churn admit; producer_failure still uses the allowlist reason. Pre-repair red was the intended Complete admission, not a compile failure.

Hosted exact-head checks are missing until Draft → Ready completes. Re-enter this pass on the same SHA after those receipts exist before merge convergence.

@EffortlessSteven
EffortlessSteven marked this pull request as ready for review October 10, 2026 20:46
@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!

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-10T20:47:56.795305Z 5755a24 Draft marked ready
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

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

Decision

  • Needs verification checks before upstream.

Verification questions

  • Confirm discriminator omits null limitations variant and entries with non-object shape (e.g. [null], strings, numbers).
  • Confirm pR claims tightening speed.warm_check_* baselines but emits no live produce-side proof that the real check JSON writer always emits a vector.

Refuted

  • Allocation failure on Some(reason) could cause the function to silently admit, but the function only inspects existing JSON and returns a 'static str; no allocation occurs on the rejection path.; refuted because: Path is borrow-only: matches on Value variants and returns &'static str literals; no Vec, String, or Box allocation touched by the new code or its callers.

Evidence gaps

  • Model proof intent was rejected by deterministic validation.

@EffortlessSteven

Copy link
Copy Markdown
Member Author

Source-backed reply to the verification review on 5755a247453e90837a24a194d9d5d2b561d3ba6c. No head change; these are not in-claim source defects.

Null / non-object entries. Production already fail-closes both shapes in complete_kind_has_incomplete_limitation:

  • limitations: null (and any other non-array, including the named object control) misses Some(Value::Array(_)) and returns complete analysis requires a typed limitations array.
  • [null], string, or numeric entries miss limitation.get("kind").and_then(Value::as_str) and return complete analysis limitations must each have a string kind — the same path as [{}].

#7276 required controls are omitted, object, and [{}]. The discriminator covers those through admit_check_document plus the retained flatten helper. Extra JSON-type fixtures would not change the predicate.

Producer-side vector. This is not a live producer hole (#7276 current-source evidence; the check JSON writer already emits a typed limitations vector). The PR does not claim produce-side proof. Claim boundary: must not claim a live producer hole, a public schema change, or a copy of AnalysisLimitation. speed.warm_check_* is the existing consumer metric whose admission gate tightened; there is no new metric and no producer/analyzer delta.

Classification: incorrect-as-blocker / already in the claim boundary. Unresolved inline threads: none.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

dx-scoreboard: require a typed limitations array before complete admission

2 participants