Skip to content

fix(rubric): redact hostile iterable failures - #783

Closed
seonghobae wants to merge 3 commits into
mainfrom
fix/rubric-iterable-error-boundary
Closed

fix(rubric): redact hostile iterable failures#783
seonghobae wants to merge 3 commits into
mainfrom
fix/rubric-iterable-error-boundary

Conversation

@seonghobae

@seonghobae seonghobae commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Reliability/security defect

Public rubric constructors accept caller-provided iterables. The shared bounded-materialization helper on protected main allowed runtime exceptions raised by iterator construction or advancement to cross a package-owned validation boundary with caller-controlled type/message text.

Test-first RED -> narrow GREEN

The fail-first slice established the public RubricSpecification boundary with hostile iterators. The current exact head is c6d73b685c22affaa5f4d85577ab427570d45267 over protected main c91ae210bc8e0340a5b0587cf5289b82a2e8ab92.

The production fix is confined to the shared bounded-materialization helper:

  • iterator-construction failures are redacted to package-owned ValueError;
  • iteration-time failures after a valid prefix are redacted without reflecting caller text;
  • MemoryError remains an explicit resource-exhaustion signal at both boundaries;
  • the existing maximum collection-size contract is preserved; and
  • no psychometric arithmetic, rubric semantics, persistence, provider behavior, or numerical ownership changes.

Permanent public-boundary regressions cover iterator construction, iterator advancement, and MemoryError preservation.

Exact-current verification

Exact-head Security Scan and SAST Semgrep succeeded. CI run 31559341595 reached the complete Python suite. On Python 3.14 the new tests/test_rubric_iterable_error_boundary.py tests are GREEN; the aggregate result is 5 failed, 3462 passed, 2 skipped.

The only five failures are inherited protected-main baseline contract inconsistencies outside this two-file slice:

  1. canonical documentation coverage is missing the current ACTIVE PR vocabulary expected by its contract;
  2. canonical documentation coverage is missing the expected IMPLEMENTED / PLANNED extensions wording;
  3. stale S-X² test expects an obsolete NumPy fallback although protected main now fails closed without the Rust kernel;
  4. the related S-X² spatial/dimension-floor test has the same obsolete fallback expectation; and
  5. stale person-fit test expects Python fallback although protected main requires the Rust kernel.

Those failures belong to the existing canonical documentation/fit-statistics correction line. This PR must not reintroduce Python numerical ownership or mutate the sole canonical documentation authority merely to make unrelated aggregate CI green.

Merge boundary

Keep Draft until the protected-main baseline correction integrates. Then regenerate all base-sensitive exact-head checks/reviews on the resulting live base and merge only if the unchanged slice is genuinely gate-clean with zero valid unresolved findings.

@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: d4924caa-ea4d-4df4-9b44-98085b28e644

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

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.

❤️ Share

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

@seonghobae

Copy link
Copy Markdown
Contributor Author

Superseded by GREEN.

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.

1 participant