PolicyEngine / PolicyEngine/policyengine-us
Alabama federal-tax deduction omits Act 2022-37 Part II (as-if-2020 recomputation / greater-of)
- Dominant language
- Python
- Stars
- 162
- Forks
- 212
- Avg merge
- 3d 3h
- Merged PRs (30d)
- 97
Description
## Issue
`al_federal_income_tax_deduction` implements only **Part I** of Alabama's Federal Income Tax Deduction Worksheet. It omits **Part II** (Act 2022-37 / HB 231) and the "greater of Part I / Part II" selection on line 15, so it understates the deduction whenever the as-if-2020 recomputation exceeds Part I (common for 2021 returns with children/child-care).
Current formula:
```python
income_sources = income_tax_before_refundable_credits
federal_credits = add(tax_unit, period, p.credits) # [eitc, american_opportunity_credit, refundable_ctc]
return max_(income_sources - federal_credits, 0)
```
This is Part I only. Act 2022-37 (applicable to tax year 2021) directs that "any federal income tax reductions attributable to the federal child tax credit, the earned income tax credit, and the federal child and dependent care tax credits, the federal income tax deduction shall be calculated as if the individual paid the federal income tax that would otherwise have been paid under the provisions of the Internal Revenue Code in effect on December 31, 2020," and line 15 takes the **greater** of Part I and Part II.
## Impact (TAXSIM #1184)
AL 2021 HoH, 1 child (6–17), wages $104,762, childcare $12,992, AGI ~$104,800:
- **Part I** = $13,222 − $3,000 (refundable ACTC) = **$10,222**
- **Part II** (2020-rule CTC $2,000 + CDCC $600 = $2,600) = $13,222 − $2,600 = **$10,622**
- **Correct (line 15, greater-of)** = **$10,622**
- PE returns **$10,216** (Part I, on PE's $13,216 tax) — ~$400 low.
The per-return effect is small (a few dollars of Alabama tax), so this is low priority.
## Fix
Add the Act 2022-37 Part II recomputation — CTC under 2020 rules ($2,000/child, $200k HoH phase-out, non-ARPA refundability), CDCC under 2020 Form 2441 ($3,000/$6,000 caps → $600 here), 2020 EIC — then return `max(part_I, part_II)`. Given the small magnitude, worth confirming with @PavelMakarchuk whether to build the full recomputation.
Reported via PolicyEngine/policyengine-taxsim#1184.
Contributor guide
Research direction
Start at the al_federal_income_tax_deduction entry point and compare its current Part I calculation with the Alabama worksheet requirements in the issue. Confirm the TAXSIM #1184 example and determine how the 2020-rule CTC, CDCC, and EIC recomputation fits the existing tax rules. Done means returning the greater of Part I and Part II for applicable 2021 returns, with the reported case matching $10,622.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100