Skip to content

Add Idaho senior deduction conformity#7964

Open
PavelMakarchuk wants to merge 7 commits intomainfrom
fix/id-hb559-senior-deduction
Open

Add Idaho senior deduction conformity#7964
PavelMakarchuk wants to merge 7 commits intomainfrom
fix/id-hb559-senior-deduction

Conversation

@PavelMakarchuk
Copy link
Copy Markdown
Collaborator

Summary

Add Idaho conformity to the federal enhanced senior deduction under HB 559.

What this does

  • adds an Idaho subtraction variable that mirrors the federal additional senior deduction
  • wires that subtraction into Idaho AGI subtractions starting in 2025
  • adds direct and integration regression coverage for the Idaho senior deduction path

Notes

The issue body example had an inconsistent expected Idaho taxable income value. With 200,000 dollars of AGI, 60,000 dollars of itemized deductions, and a 9,000 dollar senior deduction, the coherent Idaho taxable income is 131,000, and that is what the new integration test asserts.

Testing

  • python policyengine_us/tests/test_batched.py policyengine_us/tests/policy/baseline/gov/states/id/tax/income/subtractions/id_additional_senior_deduction.yaml --batches 1
  • python policyengine_us/tests/test_batched.py policyengine_us/tests/policy/baseline/gov/states/id/tax/income/integration.yaml --batches 1
  • python policyengine_us/tests/test_batched.py policyengine_us/tests/policy/baseline/gov/states/id/tax/income --batches 1

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 9, 2026

Codecov Report

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

Additional details and impacted files
@@             Coverage Diff              @@
##             main     #7964       +/-   ##
============================================
+ Coverage   85.36%   100.00%   +14.63%     
============================================
  Files           3         4        +1     
  Lines          41        48        +7     
  Branches        2         0        -2     
============================================
+ Hits           35        48       +13     
+ Misses          6         0        -6     
Flag Coverage Δ
unittests 100.00% <100.00%> (+14.63%) ⬆️

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

☔ View full report in Codecov by Sentry.
📢 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.

PavelMakarchuk and others added 5 commits April 10, 2026 10:28
The senior deduction was introduced in 2025 by H.R.1 but the
parameters only had values from 2025-01-01, causing microsim
crashes when running for 2024. Add 2018-01-01 entries with 0
so the parameter tree is valid for all years.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add missing Schedule 1-A deductions (tip, overtime, car loan
  interest) to id_qualified_business_income_and_federal_schedule_1a_deductions
- Add #page= anchors to PDF references
- Add permanent statute reference (IC 63-3004) to id_additional_senior_deduction
- Remove redundant documentation field from id_taxable_income
- Rename changelog from .fixed to .added (new functionality)
- Add test cases: pre-2025 zero, single filer phase-out, age
  boundary (64 vs 65), and full phase-out elimination

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Main's federal additional_senior_deduction now applies the Schedule 1-A
phase-out per eligible senior before summing (commit f6fafc5). For
joint filers with both age 70 and AGI $200k, the correct value is $6,000
(2 × max($6k − $3k, 0)), not $9,000 as this branch originally expected.

Updates three tests to match the corrected federal formula:
- id_additional_senior_deduction.yaml joint case
- id_taxable_income.yaml conformity scalar input
- integration.yaml joint senior integration

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@PavelMakarchuk PavelMakarchuk requested a review from hua7450 April 22, 2026 13:33
@PavelMakarchuk PavelMakarchuk marked this pull request as ready for review April 22, 2026 13:33
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