Apply KY personal credits per column under combined-separate election (#9010)#9017
Open
PavelMakarchuk wants to merge 1 commit into
Open
Apply KY personal credits per column under combined-separate election (#9010)#9017PavelMakarchuk wants to merge 1 commit into
PavelMakarchuk wants to merge 1 commit into
Conversation
…#9010) Under filing status 2 (married filing separately on a combined return), ky_personal_tax_credits_potential pooled each spouse's Schedule ITC Section B personal credits at the tax-unit level and capped against unit-level tax, letting a low-income spouse's credit offset the other spouse's tax. Form 740 lines 16-18 compute the credit per column with a per-column zero floor. Now caps each person's ky_personal_tax_credits_indiv at their own ky_income_tax_before_non_refundable_credits_indiv before summing. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #9017 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 1 1
Lines 18 17 -1
=========================================
- Hits 18 17 -1
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:
|
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.
Fixes #9010.
Problem
For married couples electing filing status 2 (married filing separately on a combined return), PolicyEngine pooled the Schedule ITC Section B personal credits ($40 aged / $40 blind / $20 National Guard) at the tax-unit level and capped them against unit-level tax. Form 740 computes lines 16–18 per column: each spouse's own credit offsets only that spouse's own tax, with a per-column zero floor (line 18: "If line 17 is larger than line 16, enter zero"). PolicyEngine therefore let a low-income elderly spouse's credit offset the other spouse's tax.
On the taxsim #1076 record, TaxAct and TAXSIM-35 both report KY income tax $1,353.50–$1,354; PolicyEngine reported $1,313.50 — the 66-year-old spouse's $40 over-65 credit was pooled into the head's column instead of dying in her near-zero column.
Fix
ky_personal_tax_credits_potentialnow caps each person'sky_personal_tax_credits_indivat their ownky_income_tax_before_non_refundable_credits_indivbefore summing, under the separate election. Same class as the DE Filing Status 4 fix (#8978).Scope note (follow-up)
The issue also notes a secondary item:
ky_files_separatelyelects on pre-credit column tax, whereas Form 740's election should compare post-credit column liabilities (line 26). It does not flip this record, and implementing it naively creates a circular dependency (ky_files_separately→ post-credit tax → personal credits →ky_files_separately), so it's left as a documented follow-up rather than folded into this fix.Tests
ky_files_separately: true,ky_income_tax$1,353.50 (matches TaxAct and TAXSIM-35).🤖 Generated with Claude Code