Skip to content

Keep federally excluded income in Michigan household resources (MI-1040CR line 30) - #9795

Merged
MaxGhenis merged 25 commits into
mainfrom
mi-household-resources-schedule-1-adjustments
Oct 9, 2026
Merged

MaxGhenis merged 25 commits into
mainfrom
mi-household-resources-schedule-1-adjustments

Conversation

@MaxGhenis

@MaxGhenis MaxGhenis commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

MI-1040CR line 30 is "total adjustments from your U.S. Form 1040, Schedule 1". After #9790, mi_household_resources takes line 30 as the federal above-the-line list without loss_ald. That list still holds four federal exclusions from gross income that are not Schedule 1 adjustments:

variable federal rule where the form counts it
us_bonds_for_higher_ed IRC 135, Form 8815, Schedule B line 3 line 15, "All interest and dividend income (including nontaxable interest)"
qualified_adoption_assistance_expense IRC 137, Form 8839 Part III; W-2 box 12 code T, not box 1 line 14, "any other amounts reported to you on Form W-2"
specified_possession_income IRC 931 "all income exempt or excluded from AGI" (page 26)
puerto_rico_income IRC 933 "all income exempt or excluded from AGI" (page 26)

Because the federal list subtracts each of these from gross income, the excluded amount is entered in the income it comes from (savings bond interest in interest income, adoption benefits in wages), and line 30 then took it back out of household resources. Example: wages 30,000 and interest 2,000, of which 1,500 is excluded under section 135. The model gave 30,500; MI-1040CR line 33 is 32,000.

This PR lists the Schedule 1 Part II adjustments in a Michigan parameter. Line 30 sums the ones the federal list deducts.

#9790 has merged (4732913a0e), so this PR now sits on main. Its own change is git diff $(git merge-base upstream/main HEAD) HEAD. On 2026-10-07 the US + core hub merged main into the branch (99a9ba31da) with no conflicts, and the PR's diff is byte-identical to the one reviewed at 6d436afaaf.

The law and the forms

MCL 206.508(4): "'Total household resources' means all income received by all persons of a household in a tax year while members of a household, ... and increased by the following deductions from federal gross income: (a) Any net business loss after netting all business income and loss. (b) Any net rental or royalty loss. (c) Any carryback or carryforward of a net operating loss ..." The statute adds back only those three deductions. An exclusion is not a deduction from gross income: the amount never enters gross income, but it is still income received.

2025 MI-1040 book (page 26): total household resources "are AGI, excluding net business and farm losses, net rent and royalty losses, and any carryover of a net operating loss, plus all income exempt or excluded from AGI." None of the four is on the page 27 list of items total household resources do not include.

MI-1040CR (2025 form; book pages 31 and 32):

  • Line 14: "Enter all compensation received as an employee. Include strike pay, supplemental unemployment benefits (SUB pay), sick pay, or long-term disability benefits, including income protection insurance, and any other amounts reported to you on Form W-2."
  • Line 15 (form): "All interest and dividend income (including nontaxable interest)".
  • Line 30: "Enter total adjustments from your U.S. Form 1040, Schedule 1." It lists IRA and SEP payments, student loan interest, Armed Forces moving expenses, the self-employment tax deduction, self-employed health insurance, the early withdrawal penalty, alimony paid, jury duty pay given to an employer, Archer MSA and HSA deductions, and "Any other adjustments to gross income included on your 2025 U.S. Form 1040, Schedule 1."
  • The 2024 instructions (page 33) have the same line 30 text.

Federal.

  • 2025 Schedule 1, Part II, lines 11 to 26, is the adjustments to income. The four exclusions are not on it.
  • IRC 135(a): "no amount shall be includible in gross income by reason of the redemption during such year of any qualified United States savings bond". Form 8815 line 14 goes to Schedule B line 3, "Excludable interest on series EE and I U.S. savings bonds issued after 1989."
  • IRC 137(a)(1): "Gross income of an employee does not include amounts paid or expenses incurred by the employer for qualified adoption expenses". The 2025 W-2 instructions say such amounts "are not reportable in box 1" and must be reported "in box 12 with code T".
  • IRC 931(a): "gross income shall not include— (1) income derived from sources within any specified possession".
  • IRC 933: "The following items shall not be included in gross income and shall be exempt from taxation under this subtitle".
  • By contrast, IRC 62(a) defines adjusted gross income as "gross income minus the following deductions"; Schedule 1 Part II reports those deductions.

Changes

  • New parameter gov.states.mi.tax.income.household_resources_adjustments (from 2021): the federal above-the-line deductions that are Schedule 1 Part II adjustments. Each entry carries its line in a comment: educator expenses (line 11), HSA (13), self-employment tax (15), SEP, SIMPLE and qualified plans (16), self-employed health insurance (17), early withdrawal penalty (18), alimony paid (19a), IRA (20) and student loan interest (21).
  • mi_household_resources, line 30: sums that list, keeping only the entries gov.irs.ald.deductions also lists. So a reform that repeals a federal adjustment by removing it from the federal list removes it here too, as on the federal Schedule 1. loss_ald drops off with the four exclusions, so the formula no longer special-cases it.
  • tests/test_mi_household_resources_losses.py (from Net Michigan business and rental losses in household resources (MI-1040CR lines 16, 17 and 30) #9790): its line 30 helper now reads the Michigan list, as the formula does. Its households have no exclusions, so no expected value changes.
  • Line 30 is the claimant's own Schedule 1 (MCL 206.508(3)). Person-level adjustments are summed over the head and spouse with tax_unit_non_dep_add(..., include_dependents=gov.irs.ald.filer_amounts_recorded_on_dependents), the same call above_the_line_deductions makes (6d436afaaf, after review r5). A dependent's IRA deduction, early withdrawal penalty or educator expenses no longer reduce the claimant's line 30.

Tests

5 new YAML cases in mi_household_resources.yaml, with MI-1040CR line comments and expected values worked out from the form. Each also checks federal AGI, to show the exclusion is in effect federally.

case federal AGI line 33 before line 33 now
Section 135 savings bond interest: wages 30,000, interest 2,000, 1,500 excluded 30,500 30,500 32,000
Section 137 adoption benefits: wages 60,000 including 5,000 of benefits 55,000 55,000 60,000
Section 933 Puerto Rico income: wages 45,000 including 15,000 earned in Puerto Rico 30,000 30,000 45,000
Section 931 possession income: wages 40,000 including 8,000 32,000 32,000 40,000
Exclusions plus Schedule 1 adjustments: IRA 2,000, penalty 300, student loan interest 1,000 (line 30 = 3,300) and premiums 1,200 44,700 43,500 48,500

All 5 fail on #9790's head (giving the "before" column) and pass here.

tests/test_mi_household_resources_adjustments.py (4 tests). A 1,542-household grid: every combination of wages, interest, nontaxable interest, Schedule C income, six exclusion patterns, three Schedule 1 adjustments and premiums (1,536), plus each exclusion pattern in the student loan interest phase-out (6). A Hypothesis test runs 25 examples of up to 40 households, each household paired with a copy without exclusions. Invariants, for every input:

  1. Classification. The Michigan list equals SCHEDULE_1_ADJUSTMENTS, the nine variables written in the test from the 2025 Schedule 1 with their line numbers. Every federal above-the-line deduction from 2021 on is either one of them or one of loss_ald and the four exclusions, never both, and each is a federal deduction. This is checked for every year 2021-2035 and every date either list changes. A new federal deduction fails the test until someone classifies it for line 30.
  2. Differential against the form. mi_household_resources = max(0, wages + all interest + max(0, Schedule C) − Schedule 1 adjustments − premiums). Which variables count as adjustments comes from the test's own list, not the parameter. Their amounts are read from the model, since the self-employment tax and student loan interest deductions depend on income. The reference subtracts none of the exclusions.
  3. Exclusions reach household resources only through the student loan interest deduction. That deduction's MAGI applies sections 135 and 137 (IRC 221(b)(2)(C)). Against the copy without exclusions, with D the change in that deduction: household resources = max(0, resources without − D), and federal AGI is lower by the exclusions plus D. In the grid's phase-out households, test_grid checks each exclusion separately. Savings bond interest and adoption benefits must change the deduction (D > 0). Puerto Rico income, which the student loan MAGI adds back, must leave it unchanged (D = 0). Possession income is not checked separately in this grid. Main's merged Add back income excluded under sections 911, 931 and 933 in modified AGIs (student loan interest and 11 siblings) #9817 now adds back specified_possession_income (section 931) in the student loan interest MAGI, alongside puerto_rico_income (section 933), so possession income also leaves that deduction unchanged (D = 0).
  4. Line 30 follows the federal list. A reform removes the early withdrawal penalty, the IRA deduction, us_bonds_for_higher_ed and puerto_rico_income from gov.irs.ald.deductions. The penalty and IRA deduction then leave line 30, and household resources still match the form.

On #9790's head, 3 of the 4 tests fail: the grid, the reform test and the Hypothesis test. The classification test reads only parameters, so it passes there, as it should. The file runs in about 30 s, with a 2.2 GB peak.

6d436afaaf adds a sixth YAML case, "A dependent's own Schedule 1 adjustments are not on the claimant's line 30": the claimant earns 50,000, and a dependent student has a 2,000 IRA contribution, a 100 early withdrawal penalty and 300 of educator expenses. Line 30 is 0 and line 33 is 50,000.

On head 94024821ab, all 619 Michigan YAML tests pass, as do the 9 tests in this file and test_mi_household_resources_losses.py (39 s, 2.3 GB peak).

Hub microsimulation impact (current head)

A real microsimulation on the default dataset, main at the merge base b7e4229d86 against this PR's head c5842079b7, for 2026. The runs went one at a time under the shared heavy-job lock. Sums are weighted.

Output 2026 change 2026 records changed (weighted)
mi_household_resources +2.50M 2 (3,224)
mi_refundable_credits +0 0 (0)
mi_income_tax +0 0 (0)
state_income_tax +0 0 (0)
income_tax +0 0 (0)
household_net_income +0 0 (0)
household_benefits +0 0 (0)

Comparison files are in fixes/9795-impact/ on the hub host.

Microsimulation (historical run, default dataset, 2026)

Historical run at 6d436afaaf, before the main merge and the educator-expense fix requested in review r7. Base: main at the merge base d3978dfc31. Branch: 6d436afaaf. These results do not establish impact at the current head. The US + core hub will rerun the impact at the new head against current main after the r8 educator-expense fix, because #9833 and that fix change the amounts summed on line 30. Both historical runs ran one at a time under the shared heavy-job lock (US + core hub driver, finished 2026-10-07) on populace_us_2024.h5@populace-us-2024-spm-20260909: 79,729 tax units, 1,939 with nonzero Michigan household resources.

variable (tax unit) base branch change records changed
mi_household_resources $521.541bn $521.544bn +$2.97M 8, all up (12,112 weighted tax units); largest +$1,125
mi_refundable_credits $1.592bn $1.592bn −$0.0003 1 record (weight 0.003), −$0.13
mi_income_tax $13.241bn $13.241bn +$0.0003 the same record, +$0.13
state_income_tax $580.02bn $580.02bn +$0.0003 the same record
income_tax $2,589.73bn $2,589.73bn $0 0
household_net_income (household) $17,171.86bn $17,171.86bn −$0.0003 the same record

The earlier run on the same dataset (base 0a2ca21b4a, branch b845167f07, before the head-and-spouse change) was bitwise identical. The dataset has no amounts for the four exclusions this PR moves off line 30 (us_bonds_for_higher_ed, qualified_adoption_assistance_expense, specified_possession_income, puerto_rico_income). So the 8 records that changed in this historical comparison come from the head-and-spouse summation: dependents' own adjustments no longer reduce the claimant's household resources. In that historical sample, this moved Michigan's credits and tax by less than $1 in total. Compare file: ~/reviews/us-hub/fixes/9795-impact/compare.2026.json.

Not in this PR

axiom: TheAxiomFoundation/rulespec-us#1491 queued (to be extended with the federal exclusions and line 30 companion tests)

🤖 Generated with Claude Code

MaxGhenis and others added 11 commits October 4, 2026 15:13
A filer with capital losses or other capital gains enters capital gain
distributions on Schedule D line 13 (2025 Instructions for Schedule D), so
they net against the losses before the 26 U.S.C. 1211(b) limit on line 21.
The model added distributions (non_sch_d_capital_gains) to gross income and
deducted min(3,000, losses) separately: a 5,000 long-term loss with 3,000 of
distributions gave 0 in AGI instead of -2,000.

- capital_losses_allowed_against_gains (new): losses allowed up to the
  gains in gross income, distributions included (1211(b), first part).
- limited_capital_loss: the net loss up to the limit (1211(b)(1)-(2),
  Schedule D line 21). loss_ald deducts both. This also nets spouses'
  gains and losses on a joint return.
- loss_limited_net_capital_gains (+ person version): Form 1040 line 7a,
  max(-limit, LT + ST + distributions). Net investment income no longer
  adds the distributions separately (Form 8960 line 5a).
- has_qdiv_or_ltcg: qualified dividends, or Schedule D lines 15 and 16
  both above zero (Form 1040 instructions, line 16).
- dependent_taxable_ss_magi: the same netting on the dependent's return.
- dc_self_employment_loss_addition: subtracts both capital parts of
  loss_ald.

Tests: YAML cases with form line comments; grid, Hypothesis property and
monotonicity tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ons-agi

# Conflicts:
#	policyengine_us/parameters/gov/irs/investment/income/sources.yaml
filer_loss_limited_net_capital_gains (from #9784) now nets the head and
spouse's capital gain distributions with their Schedule D gains and losses
before the 1211(b) limit, and net investment income no longer adds the
distributions separately. The invariant test's reference computation
follows: distributions move from the person-level Form 8960 amounts to
the Schedule D inputs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
capital_losses_allowed_against_gains counts only the capital gains that
gov.irs.gross_income.sources includes, and dependent_taxable_ss_magi nets
distributions only when both sources are listed. Cover both branches with
reforms that drop non_sch_d_capital_gains or capital_gains.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
From the independent review of #9788:
- mi_household_resources subtracted all above-the-line deductions,
  including the capital loss already netted in the capital gains line
  (MI-1040CR line 30 is U.S. Schedule 1 adjustments only). It now leaves
  out capital_losses_allowed_against_gains and limited_capital_loss. The
  two existing loss-limit cases double counted the loss: 44,000 -> 47,000
  and 47,000 -> 48,500.
- has_qdiv_or_ltcg figures Schedule D lines 15 and 16 over the head and
  spouse, so a dependent's loss cannot switch off the filer's worksheet.
- Distributions are floored at zero per person in every line 7a variable
  (box 2a is not negative), as irs_gross_income does.
- Capital losses are deductible only while capital_gains is a gross income
  source, matching dependent_taxable_ss_magi under such a reform.
- Test that the two loss-limit parameters agree; rename the #9784
  invariant test that no longer compares with the pre-change formula.
- loss_ald label: "Business and capital loss ALD".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CI caught two tests written against the old capital loss formula:
- test_dependent_losses_agi_invariants (#9647) compared limited_capital_loss
  with min(cap, sum of losses), which does not net one spouse's gains
  against the other's losses. Its reference now splits 1211(b) the same
  way: losses allowed up to the gains, plus the excess up to the cap.
  Renamed ..._match_all_member_formula.
- md_capital_gains_surtax "partial offset" set capital_losses (a formula
  variable, max(0, -capital_gains)) to 50,000 next to 150,000 of net gains,
  a state no inputs can produce, and its comment applied the $3,000 cap to
  losses within gains. It now inputs the short-term loss directly
  (30,000 gains less 50,000 losses = -20,000): Schedule D line 16 and Form
  502CG line 1 are 100,000, surtax 2,000 (same on main).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MCL 206.508(4) adds back "any net business loss after netting all business
income and loss" and "any net rental or royalty loss". The MI-1040CR nets
line 16 (Schedule C, Form 4797 Part II, Schedule E Parts II and III,
Schedule F) and line 17 (Schedule E Parts I and V) and floors each total at
zero. Line 30 is the U.S. Schedule 1 adjustments, so loss_ald, which holds
business, rental and capital losses, is no longer subtracted there.

Estate and trust income and Form 4797 ordinary gains now count on line 16.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MCL 206.508(3): "'Household' means a claimant and spouse." Netting every
tax unit member's sources let a dependent's business or rental loss offset
the claimant's income (a 15-year-old's Schedule C loss of 20,000 took the
claimant's household resources from 70,000 to 50,000). Lines 16 and 17 now
sum only non-dependents, as loss_ald and irs_gross_income do.

Tests: three dependent YAML cases and a deterministic dependent property
test. The loss_ald reform check now runs once, on the grid, instead of on
every Hypothesis example; test_properties drops from 931 s in CI to about
8 s. The deterministic tests no longer need hypothesis. Small inputs are
drawn at $100 or more, the tolerance docstring is corrected, and comments
list Schedule E Part IV (REMIC) on line 17.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Line 30 is "total adjustments from your U.S. Form 1040, Schedule 1". It
used the federal above-the-line list without loss_ald, which still held
four exclusions from gross income: us_bonds_for_higher_ed (IRC 135),
qualified_adoption_assistance_expense (137), specified_possession_income
(931) and puerto_rico_income (933). Total household resources include
"all income exempt or excluded from AGI" (2025 MI-1040 book, page 26), and
the excluded amounts already sit in the line 14 and 15 sources (line 15
is "All interest and dividend income (including nontaxable interest)";
adoption benefits are reported on Form W-2, box 12 code T), so line 30
took them back out.

A new parameter, gov.states.mi.tax.income.household_resources_adjustments,
lists the federal above-the-line deductions that are Schedule 1 Part II
adjustments. Line 30 sums those the federal list deducts, so a federal
reform that drops one drops it here too.

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

codecov Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (909176a) to head (f1425da).
⚠️ Report is 320 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #9795   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            4         1    -3     
  Lines           76        27   -49     
  Branches         2         3    +1     
=========================================
- Hits            76        27   -49     
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.

MaxGhenis and others added 6 commits October 5, 2026 13:40
Review r1 on #9795:
- The formula comment stated as model behaviour what is an input
  convention: because the federal list subtracts each exclusion from gross
  income, the excluded amount is entered in the income it comes from.
- The differential reference took line 30's variables from the parameter
  under test. It now uses SCHEDULE_1_ADJUSTMENTS, written in the test from
  the 2025 Schedule 1, and the classification test asserts the parameter
  equals it.
- Invariant 3 skipped every household with student loan interest. It now
  allows for the change D in that deduction (household resources =
  max(0, without - D); AGI lower by the exclusions plus D), and the grid
  adds six phase-out households so that case is exercised.
- test_worked_example duplicated a YAML case and is dropped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… grid

Review r2 on #9795: in the phase-out households, savings bond interest and
adoption benefits must change the student loan interest deduction and
Puerto Rico income (added back under IRC 221(b)(2)(C)) must not; the grid
now asserts each instead of "at least one". Possession income is left
unchecked, since its effect depends on the federal modified AGI's
treatment of section 931. The formula comment adds possession and Puerto
Rico income to the input convention.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ons-agi

# Conflicts:
#	policyengine_us/tests/core/test_dependent_losses_agi_invariants.py
#	policyengine_us/variables/gov/states/mi/tax/income/mi_household_resources.py
… and move the distributions comment

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…to mi-household-resources-business-losses

# Conflicts:
#	policyengine_us/variables/gov/states/mi/tax/income/mi_household_resources.py
…change in the changelog

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s-losses' into mi-household-resources-schedule-1-adjustments
…ces-business-losses

# Conflicts:
#	policyengine_us/tests/policy/baseline/gov/states/mi/tax/income/mi_household_resources.yaml
#	policyengine_us/variables/gov/states/mi/tax/income/mi_household_resources.py
…s-losses' into mi-household-resources-schedule-1-adjustments
@MaxGhenis

Copy link
Copy Markdown
Contributor Author

Hand-off to the US + core hub. Head 94024821ab.

MaxGhenis and others added 3 commits October 6, 2026 04:31
…ces-schedule-1-adjustments

# Conflicts:
#	policyengine_us/tests/test_mi_household_resources_losses.py
#	policyengine_us/variables/gov/states/mi/tax/income/mi_household_resources.py
Review r5: since #9801, the federal above-the-line total leaves dependents'
person-level items out, but line 30 summed educator_expense,
early_withdrawal_penalty and traditional_ira_contributions over every member
with add. It now uses tax_unit_non_dep_add, as above_the_line_deductions does.
Regression case: a dependent's IRA 2,000, penalty 100 and educator expenses
300 gave 47,600; the form gives 50,000.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@MaxGhenis
MaxGhenis merged commit f8bad3f into main Oct 9, 2026
28 checks passed
@MaxGhenis
MaxGhenis deleted the mi-household-resources-schedule-1-adjustments branch October 9, 2026 03:51
@MaxGhenis

Copy link
Copy Markdown
Contributor Author

US + core hub merge audit, us#9795 at f1425da81b (branch updated from main; PR diff lines identical to the reviewed c5842079b7) (squash): Michigan household resources keep federally excluded income (MI-1040CR line 30).

MaxGhenis added a commit that referenced this pull request Oct 9, 2026
Resolve line 30 with #9795's Michigan Schedule 1 adjustment list, including capped educator expenses, and #9796's claimant-and-spouse summation. Preserve all 48 household resources cases and their expected values.
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