Skip to content

Held-out registry: deeply nested events raise LookupError; test the 64-digit zero before - #592

Open
MaxGhenis wants to merge 2 commits into
masterfrom
trackb-registry-r8-followups
Open

MaxGhenis wants to merge 2 commits into
masterfrom
trackb-registry-r8-followups

Conversation

@MaxGhenis

@MaxGhenis MaxGhenis commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Round 8's two low findings on #580 (merged as 172f690f), with the mutation record rerun on the new source.

Changes

  • L1: _event turns a RecursionError from the JSON parser into LookupError, as _parse_registry already does. Before, an event nested about 200,000 levels deep let RecursionError through. That broke the rule that an unreadable event raises LookupError, though it failed closed. New test test_a_too_deeply_nested_event_raises covers a push and a pull_request.
  • L2: test_a_zero_push_boundary_needs_a_created_branch now runs on 40- and 64-digit all-zero befores. Before, a fallback limited to 40 digits survived both modules.
  • N3: base_commit's docstring now says the zero before falls back only with created set to true.

Invariants (unchanged)

  • An event that cannot be read raises LookupError and never another exception type.
  • A push is compared with its own boundary: its before, or the merge base only for an all-zero before with created: true.

Checks

  • Each new test fails on its mutant and passes on the fix:
    • RecursionError dropped from the handler: 2 failed;
    • the fallback limited to 40 digits: 4 failed.
  • Registry module: 222 passed. Committed-registry module: 8 passed, 2 skipped. Serial, single file each, at afcbf820.
  • Black and ruff are clean.
  • Tiers: unit 18,789 + 6 = 18,795, total 25,365. The README table matches.
  • CI: gh pr checks exits 0 at e83fb252.
  • Mutation record, docs/design/track_b_holdout_registry_mutations.json (e83fb252): all 79 checks rerun on the source at afcbf820 (SHA-256 0b31ff14…), one at a time in a clean clone, single core at nice 10. 79 killed, none survived; the source was restored after each.
    • Check 76 ("an unset event path leaks TypeError") is re-anchored to the handler tuple that now includes RecursionError.
    • Two new checks: "a too deeply nested event leaks RecursionError" (2 tests fail) and "a 64-digit zero push boundary falls back without created" (4 fail).
    • The zero-boundary check's failed ids now carry the 40/64 parameter. Every other check's failed-test list is unchanged.
  • Independent review naming the head: round 1 (Opus 5.5, the Codex lanes being closed) APPROVED e83fb252.
    • L1, L2 and N3 are resolved in substance. Every unreadable event it tried raises LookupError, including arrays 100,000 to 5,000,000 deep.
    • A differential of this head against master over 1,592 well-formed and malformed events found no difference. The only syntax-tree change is _event's handler tuple.
    • The record matches as the commit message lists: all 145 unique failed ids collect, and 13 sampled checks reproduce their failed ids exactly.
    • Tier arithmetic is correct.
    • One new low, nonblocking gap, L-A: no test asserts the created: true fallback for a 64-digit all-zero before, so a zero check that knows only 40 digits survives. It fails closed, and this repository uses SHA-1. It goes to a follow-up with nit N-C (each check's command omits the id-recording plugin).
  • Coordinator's tier-count slot: requested.

🤖 Generated with Claude Code

… the 64-digit zero before

Round 8's review of #580 (APPROVE at b111ad9) left two low findings:

- L1: _event let RecursionError through on an event nested too deeply
  for the JSON parser (200,000 levels), against the module's own rule
  that an unreadable event raises LookupError. It failed closed, since
  resolved_base() catches only LookupError. _event now catches
  RecursionError as _parse_registry already does.
  test_a_too_deeply_nested_event_raises covers a push and a
  pull_request whose payloads would otherwise resolve.
- L2: only the 40-digit all-zero before was tested, so a fallback
  limited to 40 digits survived both modules.
  test_a_zero_push_boundary_needs_a_created_branch now runs on 40 and
  64 digits.

It also corrects base_commit's docstring (round 8's N3): the zero before
falls back only with created set to true.

Both new tests fail on their mutants and pass on the fix. Tiers: unit
18,789 + 6 = 18,795, total 25,365.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
social-security-model Ready Ready Preview Oct 27, 2026 11:08am UTC

Request Review

Reran all 79 checks on holdout_registry.py at 0b31ff14 (afcbf82), one
check at a time in a clean clone, single core at nice 10; 79 killed,
none survived, and the source was restored to 0b31ff14 after each.

- Check 76 ("an unset event path leaks TypeError") is re-anchored to
  the handler tuple that now includes RecursionError.
- New check "a too deeply nested event leaks RecursionError" drops
  RecursionError from that handler: 2 tests fail.
- New check "a 64-digit zero push boundary falls back without created"
  limits the created check to 40-digit boundaries: 4 tests fail.
- The zero-boundary check's failed ids now carry the 40/64 parameter.
- Every other check's failed-test list is unchanged.
- restored_source_sha256 moves from 9ca7fc52 to 0b31ff14.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@MaxGhenis
MaxGhenis marked this pull request as ready for review October 27, 2026 17:06

This branch was successfully deployed

1 active deployment
Preview — e83fb252 Deployed Oct 27, 2026 by vercel[bot]
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