Skip to content

Give Idaho standard-deduction filers the federal non-itemizer charitable deduction - #11703

Merged
MaxGhenis merged 6 commits into
mainfrom
id-charitable-non-itemizer-deduction
Dec 3, 2026
Merged

MaxGhenis merged 6 commits into
mainfrom
id-charitable-non-itemizer-deduction

Conversation

@MaxGhenis

@MaxGhenis MaxGhenis commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor

Agent-written for Max, updated after independent review to fix dependent-gift, AGI-ceiling, negative-input, source-conflict, and test-coverage findings.

What and why

Idaho starts with federal taxable income, applies its resident adjustments, and lets taxpayers elect between the Idaho standard deduction and Idaho itemized deductions under Idaho Code § 63-3022(j). H0559 conformed Idaho law to the Internal Revenue Code in effect on January 1, 2026, retroactive to January 1, 2025. § 63-3011B § 63-3026 § 63-3022(j) § 63-3004 H0559 history H0559, PDF p. 5

Under IRC § 63(b)(4) and § 170(p), non-itemizing filers deduct qualifying cash gifts to IRC § 170(b)(1)(A) 50%-limit organizations in TY2021 (up to $300 non-joint / $600 joint) and again from TY2026 under P.L. 119-21 § 70424 (up to $1,000 for a non-joint return and $2,000 for a joint return), subject to § 170(b)(1)(G)’s percentage-of-AGI limit (100% in 2021, 60% in 2026+) and excluding dependent gifts. 26 U.S.C. § 170(p), PDF pp. 19–20 26 U.S.C. § 63(b)(4), PDF p. 1 P.L. 119-21 § 70424, PDF p. 165

Both id_deductions.py and id_itemizes.py now share id_non_itemizer_charitable_deduction (_id_non_itemizer_charity.py), which:

  • Follows Idaho Code § 63-3022(j)(1)’s incorporation of IRC § 63 by checking deductions_if_not_itemizing period membership, is_neutralized, and non_itemizers_amount[filing_status] > 0 before honoring direct charitable_deduction_for_non_itemizers overrides (so TY2020 and TY2022–2025 $0-cap years ignore direct overrides cleanly), flooring active-year overrides at zero;
  • Excludes tax-unit dependents’ charitable gifts (restricting eligibility to head and joint spouse under filing_status == JOINT, excluding explicit DEPENDENT tax_unit_role_input members from both joint spouse eligibility and the missing-head fallback, and filtering input dependents in the fallback, matching and hardening Fix federal, Oregon, and Hawaii non-itemizer charitable deductions #11313’s role filter without editing federal files);
  • Enforces non-negative person cash donation inputs and the gov.irs.deductions.itemized.charity.ceiling.all * positive_agi limit (60% in 2026+, 100% in 2021);
  • Preserves the health-insurance-premium subtraction overlap comparison and return mandatory | (itemized > standard + overlap) in id_itemizes.py (clean alongside Add joint federal and state itemization and correct deduction worksheets #11157).

Source-conflict rulings recorded

Recorded two ruled entries in source_conflicts/candidates.yaml (without # Source conflict code markers yet until known-source-conflicts.yaml registers them):

  • us-id:standard-charitable-2021-schedule-a-line-11 (follows: statute): Under Idaho Code § 63-3022(j)(1) -> IRC § 170(p) and Idaho’s January 27, 2022 press release (“qualifying organizations”), TY2021 standard-side gifts remain limited to 50%-limit cash contributions rather than importing non-50% Schedule A line 11 cash gifts from the TY2021 Standard Deduction Worksheet line 6 shorthand.
  • us-id:non-itemizer-charity-federal-itemizer-split (follows: statute): Under Idaho Code § 63-3022(j)’s independent Idaho election (and 2021 Form 40 Worksheet line 6 importing Schedule A line 11), Idaho evaluates the § 170(p) allowance under Idaho’s own id_itemizes election even when the taxpayer itemizes federally. TY2026 Form 40 instructions remain unpublished and should be re-checked when released. 2021 worksheet, line 6, PDF p. 10 2021 Idaho guidance Current forms

Test plan

31 cases in policyengine_us/tests/policy/baseline/gov/states/id/tax/income/deductions/id_deductions.yaml and 5 unit tests in policyengine_us/tests/core/test_id_non_itemizer_charity.py verify:

  • 2026 single ($17,100), joint ($34,200), capped single ($17,100), itemization election switch (False, $17,100), HEAD_OF_HOUSEHOLD ($25,150), SURVIVING_SPOUSE ($33,200), SEPARATE when spouse does not itemize ($17,100), and mandatory separate itemization (True, $10,000);

  • Dependent gift exclusion with explicit is_tax_unit_head ($400 head + $600 dependent -> $16,500), without is_tax_unit_head fallback ($16,500), and under forced-false is_tax_unit_head with tax_unit_role_input (HEAD/SPOUSE/DEPENDENT including conflicting is_tax_unit_spouse -> $32,200), explicit resolved_charitable_cash_donations_50_pct override ($16,600), explicit charitable_cash_donations_50_pct_orgs input ($16,400), 60% * positive_agi limit alongside state addition ($16,700 deduction, $14,300 taxable income), unearned taxable_interest_income AGI ($17,100), and full id_health_insurance_premiums_subtraction retention ($18,500 itemized < $16,100 + $1,000 + $2,000, $6,000 subtraction);

  • 2020 CARES non-duplication, ignored TY2020 & TY2025 direct overrides (id_agi: $74,700, id_deductions: $12,400 / $15,750), reform neutralization guard (both parameter removal & neutralize_variable, $16,100), 2025 non-applicability ($15,750), 2021 federal itemizer electing Idaho standard ($12,850), 2021 non-50%-organization exclusion ($12,550), 2026 federal itemizer electing Idaho standard ($17,100), and separate 2026 simulations for negative AGI / negative raw cash / negative resolved cash / negative direct override guards ($16,100);

  • Model projection note: TY2026 id_income_tax values ($2,715.79 -> $2,662.79 single; $5,421.59 -> $5,315.59 joint) use C-CPI-U uprated projections of main/{single,joint}.yaml (whose published statutory table ends at TY2025); the $53 single and $106 joint reductions reflect Idaho Code § 63-3024’s statutory 5.3% marginal rate. Idaho Code § 63-3024 Model rate

  • Full policyengine_us/tests/policy/baseline/gov/states/id/tax/income YAML suite (including all 31 cases in deductions/id_deductions.yaml, id_deductions.yaml, id_itemized_deductions.yaml, id_taxable_income.yaml, and id_health_insurance_premiums_subtraction.yaml): 332 passed.

  • test_id_non_itemizer_charity.py (5 passed), test_id_health_insurance_premiums.py, test_source_conflicts.py, test_no_group_variables_in_person_adds.py, test_no_in_place_writes_to_cached_arrays.py, test_no_engine_time_randomness.py, and test_reference_urls.py pass (325 passed); ruff check and ruff format --check pass.

  • Both us-id:standard-charitable-2021-schedule-a-line-11 and us-id:non-itemizer-charity-federal-itemizer-split recorded in source_conflicts/candidates.yaml; one changelog fragment in changelog.d/.

Fixes #11267

Follow-ups: #11717

axiom: TheAxiomFoundation/rulespec-us#2939 queued

Co-Authored-By: GPT-6 <noreply@openai.com>
@MaxGhenis
MaxGhenis marked this pull request as ready for review December 3, 2026 12:56
@codecov

codecov Bot commented Dec 3, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (5a7f9b5) to head (896dd85).
⚠️ Report is 106 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #11703      +/-   ##
===========================================
+ Coverage   95.34%   100.00%   +4.65%     
===========================================
  Files           1         3       +2     
  Lines          86        75      -11     
  Branches        2         5       +3     
===========================================
- Hits           82        75       -7     
+ Misses          4         0       -4     
Flag Coverage Δ
unittests 100.00% <100.00%> (+4.65%) ⬆️

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.

@MaxGhenis

Copy link
Copy Markdown
Contributor Author

Agent review for Max, written by Codex and posted by Antigravity for Max Ghenis (exact reviewed head b913024e174608a6a66b18903f00588d3969f2e0).

VERDICT: REQUEST_CHANGES at b913024
The seven submitted expectations match the pinned model, but the Idaho change also admits gifts paid by dependents and deductions above the statutory contribution-base ceiling.

Merge base and main 50af7fba6908a17bff784c297440acd179252136. Model: Codex (gpt-6.2-sol, effort ultra).

Findings

  1. P1 — Idaho deducts gifts paid by a dependent. id_deductions.py:18, id_itemizes.py:29, and charitable_deduction_for_non_itemizers.py:26. A 2026 Idaho single filer with $75,000 wages and no gifts gets a $17,100 deduction when their dependent pays $1,000 to charity. The expected deduction is $16,100 because the gift was paid by the dependent. The helper sums gifts from every tax-unit member. Make Fix federal, Oregon, and Hawaii non-itemizer charitable deductions #11313’s filer and joint-spouse filtering a merge prerequisite. IRC § 170(a), (p), PDF pp. 1, 19–20 · Draft TY2026 Form 1040 instructions, line 12f, PDF p. 38

  2. P1 — Idaho inherits a missing contribution-base ceiling. id_deductions.py:18, id_itemizes.py:29, and charitable_deduction_for_non_itemizers.py:28. A 2026 single filer with $1,000 federal AGI and a $1,000 eligible cash gift can deduct $600 of the gift, for a $16,700 Idaho deduction. Head gives $17,100. With a $30,000 Idaho addition, taxable income is $13,900 at head versus $14,300 expected, understating tax by $21.20. Section 170(p) excludes the itemized floor and carryovers. The 60% cash ceiling still applies. Fix federal, Oregon, and Hawaii non-itemizer charitable deductions #11313 supplies that ceiling and handles a zero contribution base. P.L. 119-21 §§ 70424–70425, PDF pp. 165–167 · Idaho Form 39R instructions, PDF p. 42

  3. P2 — The split federal and Idaho election needs coverage and an explicit source decision. id_deductions.py:18, id_itemizes.py:29, new deductions/id_deductions.yaml:51, and PR body line 33. The submitted switch case has $16,500 in federal itemized deductions against $17,100 on the federal standard side, so it also takes the federal standard route. In a genuine 2026 split election with $18,000 federal itemized deductions, $2,000 removed Idaho SALT, and a $1,000 eligible gift, head gives $17,100. The result is $16,100 if the federal election controls § 170(p), and $17,100 if Idaho applies § 170(p) using its own election. The latest Idaho instructions I found cover TY2025. The 2021 worksheet expressly supports the split election for that year. It also takes Schedule A line 11 directly. For a federal itemizer with $13,000 itemized, $500 removed SALT, and $400 of deductible Schedule A cash gifts to a nonoperating private foundation, the worksheet yields $12,850 on its face and head gives $12,550 under the § 170(p) recipient filter. Resolve and document the TY2021 source choice. If the worksheet and statute produce different results under that reading, register the conflict. Idaho Code § 63-3022(j) · IRC § 63(b)–(d), PDF pp. 1–2 · TY2021 Form 40 instructions, PDF pp. 9–10 · TY2021 Schedule A, line 11 · Idaho instruction listings

  4. P2 — The integration case fixes exact cents to a model projection. New deductions/id_deductions.yaml:94 and :121, PR body lines 21 and 25, and main/single.yaml:39. For the $75,000 single filer, head uses a $4,922.7421 cutoff from federal September–August chained CPI-U. Idaho law calls for the Commission’s calendar-year CPI-U adjustment. The posted schedule ends at TY2025, so the exact TY2026 cutoff and tax totals remain unverified. The $53 single and $106 joint savings follow from the 5.3% rate. Label the absolute amounts as model projections or assert the change in liability. Idaho Code § 63-3024(2)–(3) · Idaho rate schedule, TY2025

  5. P2 — Negative charity inputs can bypass the ordinary floor. id_deductions.py:18, id_itemizes.py:29, and resolved_charitable_cash_donations_50_pct.py:22. A 2026 single filer with $75,000 wages, zero gifts, and a -100 non-50%-organization input gets $16,200 because the resolver subtracts the negative input. Expected is $16,100. A direct -100 override of the federal helper in 2025 gives $15,650 instead of $15,750. Ordinary negative cash totals already floor to zero. Negative wages floor to zero before AGI, which still leaves the missing contribution-base guard in finding 2. IRC § 170(a), (p), PDF pp. 1, 19–20

  6. P3 — The description should say “non-joint return.” PR body line 7 describes the $1,000 cap using single returns. The model correctly applies $1,000 to MFS, HOH and qualifying surviving spouse as well. With $1,500 in eligible gifts and sufficient AGI, their 2026 standard-side totals are $17,100, $25,150 and $33,200 respectively, subject to mandatory itemization. P.L. 119-21 § 70424, PDF p. 165 · Rev. Proc. 2025-32 § 3.14, PDF p. 18

Seven-case recomputation

New YAML output line Main Head Independent calculation
11 · 2026 single, $1,000 gift $16,100 $17,100 $16,100 + $1,000
37 · 2026 joint, two $1,000 gifts $32,200 $34,200 $32,200 + $2,000
49 · 2026 single, $1,500 gift $16,100 $17,100 $16,100 + min($1,500, $1,000)
63–64 · 2026 Idaho election true, $16,500 false, $17,100 $16,100 < $16,500 < $17,100, with zero SALT and premium overlap
76 · 2025 single, $1,000 gift $15,750 $15,750 $15,750 + $0
88 · 2021 single, $400 gift $12,550 $12,850 $12,550 + min($400, $300)
121 · 2026 single tax, without and with gift $2,715.79 / $2,715.79 $2,715.79 / $2,662.79 Taxable income $58,900 / $57,900. Apply 5.3% above the modeled cutoff, add $10, subtract $155.

The pinned CPI windows sum to 2,125.365 and 2,077.121, giving modeled cutoffs of $4,922.7421 single and $9,845.4842 joint. The separate joint reproduction uses taxable income of $117,800 and $115,800, one $10 building tax and two $155 food credits. That gives $5,421.59 twice on main and $5,421.59 / $5,315.59 on head. All seven cases have wages, eligible modeled donors and enough AGI to preserve their expectations under #11313. Idaho Code § 63-3082 · Idaho Code § 63-3024A

Sources and integration

The caller search found id_taxable_income.py:15 and id_health_insurance_premiums_subtraction.py:21 as the downstream consumers. The standard route takes charity once and retains qualifying premiums. The itemized route takes the itemized amount and removes the premium overlap from the separate subtraction. The four existing Idaho YAML files and the core premium test have no gift inputs that would change their expectations. The local #11157 diff changes the adjacent return and input handling. The combined code needs both the charity-adjusted comparison and #11157’s explicit and partial elections. Idaho Code § 63-3022P · Form 39R, PDF pp. 48–49

The changelog fragment at changelog.d/id-charitable-non-itemizer-deduction.fixed.md:1 matches the intended change. The description’s six main failures and seven head passes match the static recomputation. The saved head CI confirms PR validation, including formatting and changelog checks. Sixteen checks were queued. The claimed local policy and source-conflict passes remain unverified. The saved discussion and reviews are empty. Fixes #11267 and axiom: TheAxiomFoundation/rulespec-us#2939 queued are present in the saved body. The Axiom issue, encoder blocker, pe-parity label and companion cases are unverified from the supplied materials.

Proposed YAML

The two disputed source readings are labeled in the fixtures. The 2026 split-election case assumes Idaho applies § 170(p) using its own election.

- name: Idaho excludes a dependent's own cash gift
  period: 2026
  input:
    people:
      filer: {age: 40, employment_income: 75_000, is_tax_unit_head: true}
      child: {age: 17, is_tax_unit_dependent: true, charitable_cash_donations: 1_000}
    tax_units:
      return: {members: [filer, child], filing_status: SINGLE}
    households:
      household: {members: [filer, child], state_code: ID}
  output: {id_deductions: 16_100}

- name: Idaho applies the federal contribution-base ceiling before Idaho additions
  period: 2026
  input: {state_code: ID, age: 40, filing_status: SINGLE, employment_income: 1_000, charitable_cash_donations: 1_000, id_other_additions: 30_000}
  output: {id_deductions: 16_700, id_taxable_income: 14_300}

- name: Idaho standard election retains qualifying health premiums
  period: 2026
  input:
    state_code: ID
    age: 40
    filing_status: SINGLE
    employment_income: 75_000
    charitable_cash_donations: 1_000
    tax_unit_itemizes: false
    health_insurance_premiums: 6_000
    medical_expense_deduction: 2_000
    id_itemized_deductions: 19_000
  output: {id_itemizes: false, id_deductions: 17_100, id_health_insurance_premiums_subtraction: 6_000, id_taxable_income: 51_900}

- name: Idaho 2021 standard worksheet accepts a federal itemizer's qualifying gift
  period: 2021
  input: {state_code: ID, age: 40, filing_status: SINGLE, employment_income: 75_000, charitable_cash_donations: 400, itemized_taxable_income_deductions: 13_500, id_salt_deduction: 2_000}
  output: {tax_unit_itemizes: true, id_itemizes: false, id_deductions: 12_850}

# Worksheet reading pending the TY2021 source decision. The recipient filter gives 12_550.
- name: Idaho 2021 standard worksheet uses Schedule A line 11
  period: 2021
  input: {state_code: ID, age: 40, filing_status: SINGLE, employment_income: 75_000, charitable_cash_donations: 400, charitable_cash_donations_non_50_pct_orgs: 400, itemized_taxable_income_deductions: 13_000, id_salt_deduction: 500}
  output: {tax_unit_itemizes: true, id_itemizes: false, id_deductions: 12_850}

# Expected under the independent Idaho election. Federal-election reading gives 16_100.
- name: Idaho 2026 standard election after federal itemization
  period: 2026
  input: {state_code: ID, age: 40, filing_status: SINGLE, employment_income: 75_000, charitable_cash_donations: 1_000, itemized_taxable_income_deductions: 18_000, id_salt_deduction: 2_000}
  output: {tax_unit_itemizes: true, id_itemizes: false, id_deductions: 17_100}

- name: Idaho uses the non-joint cap for MFS, HOH and qualifying surviving spouse
  period: 2026
  input:
    state_code: [ID, ID, ID]
    age: [40, 40, 40]
    filing_status: [SEPARATE, HEAD_OF_HOUSEHOLD, SURVIVING_SPOUSE]
    employment_income: [75_000, 75_000, 75_000]
    charitable_cash_donations: [1_500, 1_500, 1_500]
  output: {id_deductions: [17_100, 25_150, 33_200]}

- name: Idaho separate filer itemizes when their spouse itemizes
  period: 2026
  input: {state_code: ID, age: 40, filing_status: SEPARATE, employment_income: 75_000, charitable_cash_donations: 1_000, separate_filer_itemizes: true, id_itemized_deductions: 1_000}
  output: {id_itemizes: true, id_deductions: 1_000}

- name: Idaho cash gift eligibility uses AGI when the filer has no wages
  period: 2026
  input: {state_code: ID, age: 40, filing_status: SINGLE, taxable_interest_income: 75_000, charitable_cash_donations: 400}
  output: {id_deductions: 16_500}

- name: Idaho floors negative wages and cash gift inputs
  period: 2026
  input:
    state_code: [ID, ID, ID]
    age: [40, 40, 40]
    filing_status: [SINGLE, SINGLE, SINGLE]
    employment_income: [-1_000, 75_000, 75_000]
    charitable_cash_donations: [1_000, -1_000, 0]
    charitable_cash_donations_non_50_pct_orgs: [0, 0, -100]
  output: {id_deductions: [16_100, 16_100, 16_100]}

Owed — lane disk line: no runs — seven-case YAML on main and head, existing Idaho income/id_deductions.yaml, id_itemized_deductions.yaml, id_taxable_income.yaml and subtractions/id_health_insurance_premiums_subtraction.yaml, core test_id_health_insurance_premiums.py, federal charitable_deduction_for_non_itemizers.yaml, test_source_conflicts.py, single and joint tax reproductions, proposed regression cases, and focused reruns with #11313 and #11157 integrated.

@MaxGhenis
MaxGhenis marked this pull request as draft December 3, 2026 13:29
@MaxGhenis

MaxGhenis commented Dec 3, 2026 •

Copy link
Copy Markdown
Contributor Author

Sol r2/r3/r4 independent review ledger on 896dd85ba12ff5d75364cf01f680395d699a80c3:

  • R4 outcome (gpt-6.2-sol, ultra): Items 1 (dollar_cap > 0 direct override gate blocking TY2020 & TY2022–2025 overrides), 2 (conflicting is_tax_unit_spouse + tax_unit_role_input == DEPENDENT exclusion), and 4 (forced-false-head dependent fallback, NeutralizeCharityReform is_neutralized, binding $18,500 election threshold) are closed; zero P0, P1, or P2 findings remain.
  • Level-based review completion: Only one non-blocking P3 note remains (adjusted_gross_income: -1_000 vs direct positive_agi: -1_000 input in id_deductions.yaml:433), tracked with TY2026 Form 40 follow-up confirmation in Follow-ups from Idaho non-itemizer charitable deduction (#11703) #11717.
  • Checks at 896dd85ba12ff5d75364cf01f680395d699a80c3: 332 Idaho income-tax YAML tests and 325 pytest unit/code-health tests passed locally with clean Ruff lint and format; CI workflow 47130097773 is running before marking ready.

@MaxGhenis
MaxGhenis marked this pull request as ready for review December 3, 2026 19:06
@MaxGhenis
MaxGhenis merged commit efd1e4f into main Dec 3, 2026
37 checks passed
@MaxGhenis

Copy link
Copy Markdown
Contributor Author

US + core hub merge audit for #11703 at exact head 896dd85ba12ff5d75364cf01f680395d699a80c3.

@MaxGhenis
MaxGhenis deleted the id-charitable-non-itemizer-deduction branch December 3, 2026 19:06
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.

Idaho taxable income omits the 2026 charitable deduction for non-itemizers (26 U.S.C. 170(p))

1 participant