Skip to content

Give the whole-period proof test a July onset - #601

Draft
MaxGhenis wants to merge 1 commit into
masterfrom
trackb-proof-july-onset-20261106
Draft

MaxGhenis wants to merge 1 commit into
masterfrom
trackb-proof-july-onset-20261106

Conversation

@MaxGhenis

Copy link
Copy Markdown
Contributor

This moves test_unknown_prior_history_keeps_its_row_on_the_whole_period from an August 1975 onset to a July 1975 onset, so the test fails again if _unknown_prior_joint_shortfall swaps the Act's half of the whole period for the regulation's 20 of the last 40 quarters. insured_status.py and the tier counts don't change. docs/design/track_b_insured_status.md gains a section on the change, and the mutation report gains a round 25 list that holds the run.

Why the onset moves

Since round 23 of #562 (8522452), the proof drops an uncredited onset quarter from its clock when a prior period can end in that quarter, which needs an onset after the quarter's first month. With an August onset, the clock at 1975Q3 holds 41 quarters and 20 of the worker's 21 QCs sit in the last 40, so the proof's 40-quarter test keeps the row on either reading. With a July onset, the clock keeps 1975Q3 and holds 42 quarters: the 21 QCs meet half of them, and only 19 sit in the last 40.

Round 17 ran this flip as proof_keeps_last_40, and this test caught it. Round 23's mutation list didn't carry that mutation, so no run showed the loss.

Verification

All runs use invented records under the audit hook, with both data roots set to a nonexistent path and no restricted open.

  • The test passes on the merged source at 4ab9729.
  • With the cap in special_recent, the rule raises InvalidFamilyInput on the July record, and the test fails on assert 0 == 1. With the August onset the same cap passes, and with the shared clause also removed the August onset fails again.
  • With the August onset, the same cap passes all 1,997 cases in the 41 insured test modules, so no other test caught it at 4ab9729.
  • The other two long-period flips, in _witness, leave this test passing, so this test pins the proof's marker alone.
  • Black 26.5.1 with -l 79 and ruff pass on the test module, and the test modules that read the note pass.

Invariant

The rule raises InvalidFamilyInput only where every reading of the long period would (round 17). This test executes that invariant for the proof.

TheAxiomFoundation/rulespec-us#2054 pins this test to us:oasdi-insured-subsequent-special-long-period once this merges.

axiom: n/a: this changes one test's record and no rule.

🤖 Generated with Claude Code

Since round 23, _unknown_prior_joint_shortfall drops an uncredited onset
quarter from its clock when a prior can end in that quarter, which needs
an onset after the quarter's first month. With its August 1975 onset,
test_unknown_prior_history_keeps_its_row_on_the_whole_period lost 1975Q3
that way. Its clock then held 41 quarters with 20 QCs in the last 40, so
the test no longer told the Act's half of the whole period from the
regulation's 20 of the last 40. A July onset keeps 1975Q3 on the clock,
and the regulation's cap now fails the test.

The mutation report's round 25 list holds that run, so a later list can
carry proof_keeps_last_40 forward.

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

vercel Bot commented Nov 6, 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 Nov 6, 2026 2:38pm UTC

Request Review

This branch was successfully deployed

1 active deployment
Preview — 23b6a949 Deployed Nov 6, 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