Skip to content

Scope AR MFJ-2dep low-income table rows added in 2024-2025 to those years#9025

Merged
hua7450 merged 3 commits into
mainfrom
fix/ar-low-income-table-backfill-9024
Jul 16, 2026
Merged

Scope AR MFJ-2dep low-income table rows added in 2024-2025 to those years#9025
hua7450 merged 3 commits into
mainfrom
fix/ar-low-income-table-backfill-9024

Conversation

@PavelMakarchuk

Copy link
Copy Markdown
Collaborator

Fixes #9024. Backward-leak class (#9008, #9022).

Two late-defined rows in low_income_tax_tables/joint/two_or_more_dependents.yaml carry finite amounts that backfill to earlier instants: (35,000 → $765) from TY2024 resolved at 2021–2023, and (36,001 → $790) from TY2025 resolved at 2021–2024. The published DFA tables end at "Above $32,200" (2021), "Above $33,100" (2022), "Above $34,100" (2023), "Above $35,100" (2024) — verbatim cutoff notes in the table PDFs.

Impact (verified end-to-end pre-fix): TY2021 MFJ + 2 kids at wages $35,050 → ar_income_tax_before_non_refundable_credits_joint $765 via the leaked row, vs $1,092.54 from the regular table (2021 bracket card, verbatim: "$23,600 $39,699 5.0% minus $439.96"). Non-monotonic: a $150 raise cut AR tax by ~$320.

Change: explicit 2021-01-01: .inf threshold+amount on the four late brackets. Post-fix per-year scale behavior: 2021–2023 → inf (falls through to regular table), 2024 → 765/inf, 2025 → published rows.

Tests (expected values from the published tables/cards): 2021 above-cutoff → 1,092.54; 2021 in-table $31,901–$32,000 row → 921 (TaxTables_2021.pdf); 2024 last published row → 765. 14/14 pass.

🤖 Generated with Claude Code

PavelMakarchuk and others added 2 commits July 13, 2026 13:20
…ears

Core backfills a bracket's first value to the timeline start, so the
rows added for TY2024 (35,000 -> 765) and TY2025 (36,001 -> 790)
resolved at 2021-2023 instants, creating spurious low-income-table
eligibility windows above the published cutoffs ('Above $32,200 use
Standard or Itemized Deductions and Regular Income Tax Table', 2021)
and non-monotonic tax. Adds explicit 2021-01-01: .inf values and
table-verified tests.

Fixes #9024

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@PavelMakarchuk
PavelMakarchuk requested a review from hua7450 July 15, 2026 16:50
…into fix/ar-low-income-table-backfill-9024

@hua7450 hua7450 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified end to end — approving.

Fix verification (per-year bracket resolution, before vs after): pre-fix, the TY2024 row (35,000 → $765) resolved at 2021–2023 and the TY2025 row (36,001 → $790) resolved at 2021–2024. Post-fix, each year ends exactly at its published cutoff — 2021 → "Above $32,200", 2022 → $33,100, 2023 → $34,100, 2024 → $35,100 — and the 2025 column is bit-identical to main. Confirmed the published rows verbatim against the 2021 instructions, 2024 instructions, and TaxTables_FI_2025 PDFs.

Completeness: scanned all eight AR low-income table files for the same backfill class. The other seven files' late-added brackets all backfill .inf amounts (benign — redundant cutoffs above each year's real cutoff). This file was the only one with harmful finite-amount backfills, so the fix is complete for the leak class.

Tests: variable is entity = Person, so the array outputs are correct; all three expected values re-derived independently (35,050 − 4,400 = 30,650 taxable; 0.05 × 30,650 − 439.96 = 1,092.54 ✓; $921 row ✓; $765 row ✓).

Follow-up (pre-existing, filed separately): the 2021–2024 columns key rows at X_X00 while the published tables run $X,X01–$X,X00 inclusive (the 2025 column is correctly keyed at X_X01). At exact-$100 incomes the wrong row applies — e.g., 2024 income of exactly $35,000 returns $765 instead of $754, and exactly $35,100 falls to the regular table instead of $765. Out of scope here since this PR only adds the .inf scoping.

@hua7450
hua7450 merged commit d467784 into main Jul 16, 2026
33 checks passed
@hua7450
hua7450 deleted the fix/ar-low-income-table-backfill-9024 branch July 16, 2026 19:04
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.

AR low-income tax table (MFJ, 2+ dependents): 2024/2025 rows leak into TY2021-2023, creating spurious eligibility windows above the published cutoffs

2 participants