Fix CDCC returning $0 for disabled adult dependents (with section 21(d)(2) deemed income)#8704
Draft
hua7450 wants to merge 4 commits into
Draft
Fix CDCC returning $0 for disabled adult dependents (with section 21(d)(2) deemed income)#8704hua7450 wants to merge 4 commits into
hua7450 wants to merge 4 commits into
Conversation
The Child and Dependent Care Credit counts a disabled non-head dependent or spouse of any age as a qualifying individual (is_cdcc_eligible) and raises the dollar limit accordingly, but childcare expenses were distributed only across is_child (under-18) members. A disabled qualifying individual aged 18+ was therefore allocated $0 of expenses, yielding a $0 federal credit and $0 state CDCCs (e.g. ks_cdcc). IRC § 21(b)(1)(B)/(C) imposes no age limit on the disabled-dependent/spouse prongs. Adds is_dependent_care_recipient = is_child | (is_incapable_of_self_care & ~is_tax_unit_head) and uses it as the distribution key in both pre_subsidy_childcare_expenses and tax_unit_childcare_expenses. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8704 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 3 7 +4
Lines 47 109 +62
=========================================
+ Hits 47 109 +62
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…andling Refine is_cdcc_eligible so the child-by-age prong requires dependency and the disability prong counts a dependent or a member of a married couple, correctly treating a disabled spouse who is modeled as the tax unit head as a qualifying individual. Rewrite min_head_spouse_earned to apply the IRC section 21(d)(2) deemed earned income ($3,000 for one qualifying individual, $6,000 for two or more) for a student or incapacitated spouse, applying it to only one spouse. Adds the deemed_earned_income parameter and cdcc_income_floor_eligible variable, and aligns is_dependent_care_recipient's disability prong. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…into cdcc-disabled-dependent-expenses
…ouses When both the head and spouse are students or incapable of self-care, only one spouse may be deemed to have the minimum earned income (Treas. Reg. 1.21-2(b)(4), Example 3). Deem whichever eligible spouse maximizes the lesser of the two earnings, leaving the other spouse's actual earnings, instead of returning the greater unfloored earnings (which overstated the cap when the two earnings straddled the floor). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes the Child and Dependent Care Credit (CDCC) for households whose qualifying individual is a disabled adult — which previously returned $0. Extends the original expense-gate fix with a correct IRC § 21 qualifying-individual definition, handling of a disabled spouse the model assigns as head, and the § 21(d)(2) deemed-earned-income floor.
The bug
CDCC eligibility and the dollar limit already counted a disabled non-head dependent/spouse of any age, but expense attribution was gated on
is_child(age < 18). A disabled qualifying individual aged 18+ was therefore allocated $0 of expenses → $0 federal credit and $0 state CDCCs (e.g.ks_cdcc). Separately, a lone disabled adult could still net $0 because the model infers them as a "spouse" with $0 actual earnings while the § 21(d)(2) deemed-income floor was not modeled.Changes
1. Qualifying individual —
is_cdcc_eligible(IRC § 21(b)(1))is_dependent & (age < 13).disabled & (is_dependent | (head_or_spouse & has_spouse))— a disabled dependent of any age, or a disabled member of a married couple (so a disabled spouse the model assigns as head is still counted).2. Expense attribution —
is_dependent_care_recipient+ plumbing (IRC § 21(b)(2))is_dependent_care_recipient = is_child | (disabled & (dependent | member-of-couple)), used as the distribution key inpre_subsidy_childcare_expenses;tax_unit_childcare_expensesdistributes byis_cdcc_eligible.3. Deemed earned income —
min_head_spouse_earned(IRC § 21(d)(2))deemed_earned_incomeparameter ($3,000 / $6,000 annual) and thecdcc_income_floor_eligiblevariable.Reproduction (TY 2024, disabled dependent, only the age changed)
cdccks_cdccStatutory basis
Modeling notes (approximations)
Tests
494 tests pass locally across the childcare-expense plumbing, federal CDCC (including new
is_cdcc_eligible,min_head_spouse_earned, andcdcc_income_floor_eligiblecases), ~30 state/local CDCC mirrors, SNAP deductions, and the partner CDCC edge-case test. CI runs the full suite (including the partner contract suite).🤖 Generated with Claude Code