Skip to content

Fix Arkansas inflation relief credit for combined filers - #9321

Merged
DTrim99 merged 1 commit into
PolicyEngine:mainfrom
DTrim99:fix/ar-inflation-relief-combined-table
Aug 24, 2026
Merged

Fix Arkansas inflation relief credit for combined filers#9321
DTrim99 merged 1 commit into
PolicyEngine:mainfrom
DTrim99:fix/ar-inflation-relief-combined-table

Conversation

@DTrim99

@DTrim99 DTrim99 commented Aug 20, 2026

Copy link
Copy Markdown
Collaborator

Fixes #9320.

What

For a married couple filing a combined Arkansas return (filing status 4, ar_files_separately = True), the inflationary relief credit is looked up per spouse in the single-filer table (max $150, phased out from $87,000, gone at $101,000), per the Arkansas Inflationary Relief Income-Tax Credit Worksheet, Filing Status 4. The joint table (max $300, phased out from $174,000) applies only to a true joint return (status 2) on one combined income.

ar_inflation_relief_credit_person keyed the table off filing_status, which is JOINT for any married couple, so combined filers wrongly used the joint table split 50/50. This PR uses the single-filer (SEPARATE) table per spouse for combined filers, reserving the joint table and the halving split for a true joint return.

Failing case (taxsim #1143)

Joint couple, TY2022, $88,000 + $162,381 wages, $10,294 interest, 1 dependent — files combined. Per-spouse net income (AR1000F line 28): primary $90,877, spouse $165,258 (PolicyEngine computes the same split).

  • TaxAct worksheet (single-filer table per spouse): $110 + $0 = $110 (AR1000TC line 7; net tax 11,925).
  • PolicyEngine before (joint table, 50/50): $150 + $150 = $300 (net tax 11,739, ~$186 low).
  • PolicyEngine after: $110. ✓

Impact

Only the combined-married case changes. True-joint, single, head-of-household, surviving-spouse, and separate cases are unchanged (verified against the existing tests).

Tests

  • Added the Add caching #1143 combined-filing case ([110, 0]) and a true-joint contrast on the same incomes ([0, 0], combined income $256,135 > $174,000).
  • Full Arkansas suite passes (469 tests).

Related

The credit now differs by filing method ($110 combined vs $0 joint here), so the combined-vs-joint selection in ar_files_separately should ideally weigh it, as it already does for the additional tax credit for qualified individuals (#9300). Left as a follow-up to keep this change focused and avoid a circular dependency.

🤖 Generated with Claude Code

For a married couple filing combined (Arkansas filing status 4,
ar_files_separately), the inflationary relief credit is looked up per
spouse in the single-filer table (max $150, phased out from $87,000),
per the Inflationary Relief Credit Worksheet. PolicyEngine keyed the
table off filing_status, which is JOINT for any married couple, so
combined filers wrongly used the joint table (max $300, phased out from
$174,000) split 50/50. Use the single-filer table per spouse for
combined filers, reserving the joint table and the halving split for a
true joint return.

Fixes PolicyEngine#9320

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@codecov

codecov Bot commented Aug 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (57743a2) to head (ecc1ff2).
⚠️ Report is 15 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #9321   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            3         1    -2     
  Lines           65        30   -35     
=========================================
- Hits            65        30   -35     
Flag Coverage Δ
unittests 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@DTrim99
DTrim99 marked this pull request as ready for review August 20, 2026 15:04
@DTrim99
DTrim99 requested a review from hua7450 August 20, 2026 15:04

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

Reviewed with a source-verification pass against the official documents (2022 AR1000F/AR1000NR booklet, the standalone 2022 and 2023 Inflationary Relief worksheets, and the DFA HB1002 impact statement). The fix is correct — approving. Also surfacing some pre-existing issues found along the way; @DTrim99 could you take a look and see which are worth fixing (follow-up or here)?

Verified

  • The status-4 remap matches the law, triple-corroborated: Act 2 of 2022, 3rd Ex. Sess., § 6(b)(1)(B) ("Spouses filing separately on the same income-tax return may each claim one (1) credit"), the 2022 worksheet (the $150 table is captioned "Filing Status 1,3,4,5, and 6", and the Status 4 block looks up each spouse's own line-28 income), and the DFA impact statement. The true-joint path correctly keeps the $300 table on combined income.
  • All 17 audited 2022 parameter values match the worksheet exactly (joint phase-out ends at $202,000).
  • Both new tests' expectations hand-verified against the PDF brackets: $90,877 → $110 ($90,001–$91,000 row); $165,258 > $101,000 → $0; joint $256,135 > $202,000 → $0.
  • Code patterns clean: fully parameterized, vectorized encode/decode round-trip, correct changelog fragment. CI green.

Non-blocking suggestions for this PR

  1. ar_files_separately's cheaper-path comparison (and its "other credits are the same for both paths" comment) now ignores a credit that differs by path — a couple with one spouse above $101,000 gets $150×1 combined vs $300 joint, so the optimizer can pick a path that loses up to $300. You already flagged this in the PR description as a follow-up; the comment at ar_files_separately.py:28-31 should at least be corrected now so it doesn't state something false.
  2. The changed variable has no reference — and it now implements exactly the rule under review. The act PDFs above are the durable cite (there's no permanent statute: both enactments are "DO NOT CODIFY" temporary language; Ark. Code Ann. § 26-51-516 is actually the stillborn-child credit).
  3. Test gaps in the changed direction: no case where the fix reduces the credit (e.g., combined [$30,000, $100,000] → new $150 + $20 = $170 vs old $300), and no exact boundary cases ($87,000 → $150, $101,000 → $10, joint $174,000 / $202,000). Also nothing asserts the credit flowing into ar_income_tax (the taxsim case's net-tax figure is only a YAML comment).
  4. Minor: the new code comment and changelog state the 2022 amounts ($150/$87,000/$300/$174,000) as if constant — the 2023 tables differ; and consider where(filing_separately & (filing_status == statuses.JOINT), statuses.SEPARATE, filing_status.decode()) so a directly-input flag on a non-married status can't silently reroute if the single-type columns ever diverge.

Pre-existing issues (not this PR — worth fixing?)

  1. The 2023 parameter values contradict the official 2023 worksheet by up to 3×. The 2023 worksheet keeps $150/$300 maximums (phase-outs $89,600→$103,600 and $179,200→$207,200), but inflationary_relief/max_amount.yaml stores 2023 maximums of $50/$100, and reduction/start.yaml's JOINT block has no 2023 row (inherits $174,000). Origins traced: the $50/$100 matches the State Political Contributions Credit caps on Line 1 of the 2023 AR1000TC instructions (wrong credit), and the JOINT 2023-01-01: 179_200 row was added by #3807 but accidentally deleted by the WIDOW→SURVIVING_SPOUSE rename in #4130. Fixing just those two files reproduces the official 2023 tables exactly (increment/amount are already right). Verified by code-path trace and 600 DPI page reading.
  2. The credit's parameters outlive its sunset. The credit doesn't exist for TY2024 (absent from the 2024 booklet's AR1000TC credit list). Behavior is already right — non_refundable.yaml drops the credit at 2024-01-01 — but max_amount.yaml carries $50/$100 forward indefinitely, so the person-level variable still pays if queried directly in 2024+.
  3. 3 of 4 reference URLs on all four inflationary_relief parameter files are dead — DFA moved from /images/uploads/incomeTaxOffice/ to /wp-content/uploads/ (same filenames). While refreshing: the booklet worksheet is at #page=25 in the current copy (cited as 26), and two entries share the identical title "Inflationary relief income-tax credit worksheet" (2022 vs 2023).
  4. Scalar-masked doubling in the existing HOH/surviving-spouse tests: they put two adults in the unit and assert a scalar, so the broadcast gives the unit $60/$300 — double those statuses' $150 per-return max (the divisor only halves true JOINT). Artificial situations, but worth rewriting as single-adult cases with explicit arrays. Two tests are also both named "Single household with $100,000 taxable income" though the second is a SEPARATE couple.

Items 1–3 all touch the same four parameter files, so they'd bundle naturally into one follow-up PR.

@DTrim99
DTrim99 merged commit 903711e into PolicyEngine:main Aug 24, 2026
33 checks passed
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.

Arkansas inflation relief credit: combined filers use the joint table instead of the per-spouse single-filer table

2 participants