Skip to content

Leave dependents' unemployment compensation off California, Rhode Island and Wisconsin filer returns - #10187

Open
MaxGhenis wants to merge 7 commits into
mainfrom
dependent-uc-state-agi
Open

MaxGhenis wants to merge 7 commits into
mainfrom
dependent-uc-state-agi

Conversation

@MaxGhenis

@MaxGhenis MaxGhenis commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

What was wrong

Federal AGI leaves out a tax unit dependent's income: irs_gross_income multiplies every source by ~is_tax_unit_dependent, because the dependent reports that income on their own return. Three state lines still summed person-level unemployment compensation over every tax unit member. A dependent's compensation therefore moved the filers' state AGI, though the filers' federal AGI never included it.

Engine output on main (with #10175 merged locally so the federal side is right). The filers are the same in each pair; only the dependent child's unemployment compensation (UC) changes.

State Line Household Without the child's UC With it, main With it, this PR
CA ca_agi_subtractions TY2024 couple, wages 90,000 + 20,000; child aged 17 with UC 10,000 0 10,000 0
ca_agi 110,000 100,000 110,000
ca_income_tax 2,331.32 1,731.32 2,331.32
RI ri_additions TY2020 single parent, wages 40,000; child with UC 10,000, all excluded under IRC 85(c) 0 10,000 0
ri_income_tax 638.01 1,013.01 638.01
WI wi_unemployment_compensation_subtraction TY2024 single parent, wages 15,000; child with UC 10,000 0 8,500 0
wi_agi 15,000 6,500 15,000

In the WI case, the leak also changed wi_property_tax_credit for an elderly couple (TY2024: 119.02 → 0).

What changes

Each line now sums only the head's and spouse's amounts with tax_unit_non_dep_add, as ri_subtractions and pa_total_taxable_income already do. Tax-unit-level list items (us_govt_interest, investment_in_529_plan, ri_section_179_expense_add_back) are added as before.

  • CA ca_agi_subtractions: the whole Schedule CA list, which has taxable Social Security, UC, U.S. obligation interest and state tax refunds. A dependent's person-level taxable_social_security is already zero (it is allocated to the head and spouse), so only UC and refunds move.
  • RI ri_additions: now a formula instead of adds.
  • WI wi_unemployment_compensation_subtraction: worksheet line 1. Summing non-dependents' person-level taxable_unemployment_compensation equals the UC in federal AGI both on main and after Fix the 2020 unemployment compensation exclusion: cutoff test, per-spouse cap, dependents #10175, so this does not depend on merge order.

Legal basis

I read these sources in this session.

  • California. The 2024 Schedule CA (540) instructions, "Column A – Federal Amounts", say to "Enter … the same amounts entered on your federal Form 1040 … and federal Schedule 1." Section B line 7 reads: "California excludes unemployment compensation from taxable income. Enter on line 7, column B the amount of unemployment compensation shown in column A." The same text appears in the 2021–2025 instructions. A dependent has their own California filing requirement and standard deduction worksheet (2024 Form 540 booklet, file pages 4 and 13). FTB 3803, California's counterpart to Form 8814, moves only a child's interest and dividends.

  • Rhode Island. RIGL 44-30-12:

    • (a) starts from "the individual's adjusted gross income";
    • (b)(6) adds "any unemployment compensation received but not included in federal adjusted gross income".

    The 2020 Schedule M line 2g says "Unemployment compensation received but not included in federal adjusted gross income" (file page 2). The 2020 RI-1040 instructions say "Enter the amount of unemployment compensation excluded from your Federal taxable income" (file page 9). Page 1 of the same instructions covers who must file.

  • Wisconsin. Wis. Stat. 71.05(6)(b)8. subtracts the "amount included in federal adjusted gross income for the current year". Line 1 of the 2021–2025 Schedule SB worksheet reads "Fill in unemployment compensation from line 7 of federal Schedule 1 (Form 1040)" (2024, file page 2). A dependent has their own filing requirement (2024 Form 1 instructions, file page 3).

Invariants

  • Leak removed. For every state and year, adding unemployment compensation to a dependent leaves the filers' ca_agi_subtractions, ri_additions and wi_unemployment_compensation_subtraction unchanged, and so their CA, RI and WI AGI.
  • Filers' own amounts. Each line equals a reference built from the head's and spouse's own amounts:
    • CA: their taxable UC plus state tax refunds;
    • RI: their federally excluded UC;
    • WI: the worksheet on their taxable UC.
  • Unchanged without dependents. For tax units without dependents, each line equals the sum over all members, as on main.

policyengine_us/tests/core/test_dependent_unemployment_compensation_state_invariants.py checks all three on a seeded random population: 40 tax units, each placed in CA, RI and WI; TY2020 and TY2024; single or joint; zero to two dependents with UC. In 2020 each person's taxable UC is an input, so the test does not depend on how the federal exclusion is computed (#10175). It fails on main's formulas.

Cost, measured locally on macOS: 6 tests in 2.9 s, 40 s wall including the model import, 1.36 GB peak. Each year needs two small simulations. It runs in the existing tests/core Python group; no CI job was added.

How it was checked

  1. All-state household sweep, TY2020–2026. Five filer profiles each have a 17-year-old dependent:

    • a single worker at 40,000;
    • a couple at 110,000;
    • two elderly profiles;
    • a 15,000 earner.

    Three pairs:

    • the child has UC 10,000;
    • the child has survivor benefits 12,000;
    • the head has UC 8,000 and the child has UC 10,000.

    The sweep compares household_state_income_tax, household_state_benefits and every state property tax credit, with and without the child's income. It ran on main plus Fix the 2020 unemployment compensation exclusion: cutoff test, per-spouse cap, dependents #10175, then plus Leave dependents' capital income out of state lines on the filers' return #9894/Leave dependents' own items out of DC, Delaware and Ohio subtractions #9939, then plus this PR. A drill-down listed every state variable that moved. Script, drill-down and results: ~/reviews/dependent-uc-state-lines-2026-10-12/.

    After this PR, no CA, RI or WI tax line moves with a dependent's UC. Four kinds of mover remain, none of them this pattern on the return:

  2. Tests. The new cases come from the forms. 7 of the 12 cases in the three files fail on main and pass here. The related CA and RI integration files and salt_refund_integration.yaml pass, and so does test_ca_educator_expense_addition_properties.py (5 passed).

Not in this PR (follow-ups filed)

  • WI homestead household income counts dependents' Social Security, SSI and 2020 excluded UC (Wis. Stat. 71.52(4)). Fixed in Leave dependents' income out of Wisconsin homestead credit household income #10191.
  • RI-1040H misses dependents' taxable income. RIGL 44-33-3 counts all household members' income.
  • RI adds every 529 contribution to RI AGI.
  • WI's UC worksheet leaves out line 5, taxable refunds.
  • Other states' credits may count dependents' Social Security (CO, ME, MI, MO, WV).

Hub microsimulation impact (current head)

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

Output 2024 change 2026 change 2024 records changed (weighted) 2026 records changed (weighted)
ca_agi_subtractions -452.34M -547.71M 15 (132,168) 15 (134,348)
ca_agi +452.34M +547.71M 15 (132,168) 15 (134,348)
ca_income_tax +13.90M +15.67M 10 (77,539) 10 (78,817)
ri_additions +0 +0 0 (0) 0 (0)
ri_agi +0 +0 0 (0) 0 (0)
ri_income_tax +0 +0 0 (0) 0 (0)
wi_unemployment_compensation_subtraction +0 +0 0 (0) 0 (0)
wi_agi +0 +0 0 (0) 0 (0)
wi_income_tax +0 +0 0 (0) 0 (0)
state_income_tax +13.90M +15.67M 10 (77,539) 10 (78,817)
income_tax +0 +0 0 (0) 0 (0)
household_net_income -13.91M -15.80M 11 (87,352) 15 (134,348)
household_benefits +0 +0 0 (0) 0 (0)

Commits after 7cff12835d change only reference metadata, comments, tests and the changelog, so the formulas run here are the ones at the PR head. RI does not move: its add-back applies only to compensation excluded under IRC 85(c), which existed only in 2020. WI does not move: the subtraction is unchanged for every Wisconsin record in both years.

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

Review

The Codex review lanes were held until 06:00Z and the Claude lanes were closed, so per the fallback rule an independent in-session Opus 5.5 reviewer reviewed 042b072820.

Round 1: APPROVE. The reviewer re-fetched every source and file page, recomputed each case, confirmed that 7 of the 12 cases fail on main, ran the related CA, RI and WI files, and probed vectorization across mixed tax units. Follow-ups:

Round 2: APPROVE at 496f635cb0. Reverting each state's formula alone fails that state's cases, and the 2020 input trick is valid. The CI cost (about +0.33 GB and 6 s in the Rest core group, which peaks at 8.14 GB) is acceptable. Nits fixed in 24653845bb: California dependents' refunds are now in the invariants test, and a comment has moved. Round 3: APPROVE at 24653845bb. The reviewer also checked that a formula which drops dependents' UC but still subtracts their refunds fails the test. 208a87f7a9 then only reflows a docstring line the reviewer flagged.

axiom: TheAxiomFoundation/rulespec-us#1729 queued (CA R&TC 17083 for line 7, plus an addendum for the Schedule CA line 1 state refund subtraction; blocked on a corpus pin bump) | TheAxiomFoundation/rulespec-us#1730 queued (RIGL 44-30-12(b)(6); the TY2026 module has no taxpayer-or-spouse restriction and no test exercising it) | TheAxiomFoundation/rulespec-us#1731 queued (Wis. Stat. 71.05(6)(b)8.; not encoded)

🤖 Generated with Claude Code

MaxGhenis and others added 3 commits October 12, 2026 19:26
…eturns

Federal AGI leaves out a tax unit dependent's income (irs_gross_income masks
dependents), but California's AGI subtractions, Rhode Island's AGI additions
and Wisconsin's unemployment compensation subtraction summed person-level
unemployment compensation over every tax unit member, so a dependent's
compensation moved the filers' state AGI. Sum only the head and spouse with
tax_unit_non_dep_add.

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

CA Schedule CA column B, RI's 2020 IRC 85(c) add-back and WI's Schedule SB
unemployment worksheet all start from the filers' own federal return. The new
cases fail on main (7 of 12) and pass with the fix.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CA: 2024 Schedule CA (540) column A takes the filers' federal amounts; the
540 booklet gives a dependent their own filing requirement (pages 4, 13).
RI: RIGL 44-30-12(b)(6) and the 2020 Schedule M line 2g and instructions.
WI: Wis. Stat. 71.05(6)(b)8., the 2024 Schedule SB worksheet line 1, and the
2024 Form 1 dependent filing requirement.

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

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MaxGhenis added a commit that referenced this pull request Oct 13, 2026
#10187 fixes the same three state lines
(ca_agi_subtractions, ri_additions, wi_unemployment_compensation_subtraction)
more broadly and has its own review, impact run and Axiom issues. Restore them
to main here and drop tax_unit_tax_exempt_unemployment_compensation, which only
Rhode Island used. #10175 should land after #10187, so the dependent routing
never meets the old pooled state lines.

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

- ca_agi_subtractions: tax-unit-level items such as us_govt_interest are added
  as they are (#9894 makes that one filer-only).
- WI Schedule SB worksheet is on file page 3 in 2021 and page 2 in 2022; the
  RI reference is the individual 2022 Schedule M, not the RI-1041's.
- The changelog also names California's state tax refund subtraction.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MaxGhenis and others added 2 commits October 12, 2026 22:43
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@MaxGhenis

Copy link
Copy Markdown
Contributor Author

Hand-off to the US + core hub

Head: 208a87f7a9

Review. The Codex review lanes were held until 06:00Z and the Claude lanes were closed, so per the fallback rule an independent in-session Opus 5.5 reviewer reviewed this PR in three rounds: APPROVE at 042b072820, at 496f635cb0 and at 24653845bb. 208a87f7a9 only reflows a docstring line the reviewer flagged. The verdict file is ~/reviews/dependent-uc-state-lines-2026-10-12/review/verdict_10187.md on the hub host.

Passed locally:

  • the touched YAML files, 16 of 16;
  • tests/core/test_dependent_unemployment_compensation_state_invariants.py, 6 of 6;
  • the CA and RI integration files, salt_refund_integration.yaml, the CA educator property test, and the related WI files.

The new cases fail on main.

CI. On 042b072820 every check passed except one shard that was still running. On 208a87f7a9 CI has just started.

Impact. The hub pair at 7cff12835d is in the body (CA tax +$13.9M in 2024, +$15.7M in 2026; RI and WI 0). Later commits change only tests, comments, references and the changelog.

Order. This PR depends on nothing. #10175 depends on it: its owner dropped #10175's duplicate CA/RI/WI edits (head 1bf37f4dc3) and will merge main and append two 2020 cases after this lands.

Merge. The PR needs an approving review (REVIEW_REQUIRED), so land it on the gates with --admin --match-head-commit once CI is green.

Axiom. TheAxiomFoundation/rulespec-us#1729, #1730 and #1731 are queued.

Follow-ups proposed as sessions or chips:

  • Wisconsin's general subtractions still take a dependent's state tax refund;
  • RI-1040H misses dependents' taxable income;
  • RI adds every 529 contribution to RI AGI;
  • WI's UC worksheet leaves out line 5;
  • other states' credits may count dependents' Social Security.

The companion WI homestead PR is #10191, which I'm still finishing.

This branch has not been deployed

No deployments
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