-
Notifications
You must be signed in to change notification settings - Fork 201
Fix New Jersey gross income computation #6773
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
b3d25e4
Fix New Jersey gross income computation.
DTrim99 d91fef4
fixes
DTrim99 2d31def
Apply suggestions from code review
DTrim99 23b368b
Apply PR review feedback to NJ parameter files
DTrim99 5d65a75
lint
DTrim99 5c4244b
Apply suggestions from code review
DTrim99 30ec1f9
comments
DTrim99 6ba37f3
add integration test
DTrim99 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| - bump: patch | ||
| changes: | ||
| fixed: | ||
| - Fix New Jersey gross income computation. |
12 changes: 12 additions & 0 deletions
12
policyengine_us/parameters/gov/states/nj/tax/income/additions.yaml
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| description: New Jersey counts these sources as additions to gross income. | ||
| metadata: | ||
| unit: list | ||
| period: year | ||
| label: New Jersey gross income additions | ||
| reference: | ||
| - title: NJ Statute 54A:5-1 - Additions to gross income | ||
| href: https://law.justia.com/codes/new-jersey/title-54a/section-54a-5-1/ | ||
| - title: NJ-1040 Tax Form, Lines 28-38 | ||
| href: https://www.nj.gov/treasury/taxation/pdf/current/1040.pdf | ||
| values: | ||
| 2021-01-01: [] # Currently no additions implemented; update as needed |
32 changes: 32 additions & 0 deletions
32
policyengine_us/parameters/gov/states/nj/tax/income/gross_income_sources.yaml
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| description: New Jersey counts the following sources as gross income. | ||
| metadata: | ||
| unit: list | ||
| period: year | ||
| label: New Jersey gross income sources | ||
| reference: | ||
| - title: NJ Statute 54A:5-1 - Gross income defined | ||
| href: https://law.justia.com/codes/new-jersey/title-54a/section-54a-5-1/ | ||
| - title: NJ-1040 Tax Form | ||
| href: https://www.nj.gov/treasury/taxation/pdf/current/1040.pdf | ||
| values: | ||
| 2021-01-01: | ||
| # Note: NJ uses W-2 Box 16 (state wages), not Box 1 (federal wages). | ||
| # NJ does not allow pre-tax deductions for 401k/403b that federal allows, | ||
| # so employment_income (gross wages) is correct, not irs_employment_income. | ||
| - employment_income # Line 15: Wages, salaries, tips (Category a) | ||
DTrim99 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| - taxable_interest_income # Line 16a: Interest (Category e) | ||
| # Note: NJ Statute 54A:5-1(f) does not distinguish between qualified and | ||
| # non-qualified dividends. All dividends are taxed as ordinary income. | ||
| # dividend_income includes both qualified and non-qualified dividends. | ||
| - dividend_income # Line 17: Dividends (Category f) | ||
DTrim99 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| - self_employment_income # Line 18: Net business profits (Category b) | ||
| - farm_income # Line 18: Farm income (Category b) | ||
| - long_term_capital_gains # Line 19: Long-term capital gains (Category c) | ||
| - short_term_capital_gains # Line 19: Short-term capital gains (Category c) | ||
| - taxable_pension_income # Line 20a: Pensions (Category j) | ||
| - taxable_ira_distributions # Line 20a: IRA distributions (Category j) | ||
| - partnership_s_corp_income # Lines 21-22: Partnership & S-corp (Categories k, p) | ||
| - rental_income # Line 23: Rents, royalties (Category d) | ||
| - gambling_winnings # Line 24: Gambling (Category g) | ||
| - alimony_income # Line 25: Alimony received (Category n) | ||
| - miscellaneous_income # Line 26: Other income | ||
44 changes: 44 additions & 0 deletions
44
policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/integration.yaml
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| - name: 0-NJ.yaml | ||
| absolute_error_margin: 2 | ||
| period: 2024 | ||
| input: | ||
| people: | ||
| person1: | ||
| age: 40 | ||
| employment_income: 0.0 | ||
| ssi: 0 | ||
| wic: 0 | ||
| head_start: 0 | ||
| early_head_start: 0 | ||
| commodity_supplemental_food_program: 0 | ||
| self_employment_income: 50_000 | ||
| is_tax_unit_head: true | ||
| person2: | ||
| age: 40 | ||
| employment_income: 0.0 | ||
| ssi: 0 | ||
| wic: 0 | ||
| head_start: 0 | ||
| early_head_start: 0 | ||
| commodity_supplemental_food_program: 0 | ||
| self_employment_income: 50_000 | ||
| is_tax_unit_spouse: true | ||
| tax_units: | ||
| tax_unit: | ||
| members: [person1, person2] | ||
| premium_tax_credit: 0 | ||
| local_income_tax: 0 | ||
| state_sales_tax: 0 | ||
| spm_units: | ||
| spm_unit: | ||
| members: [person1, person2] | ||
| snap: 0 | ||
| tanf: 0 | ||
| free_school_meals: 0 | ||
| reduced_price_school_meals: 0 | ||
| households: | ||
| household: | ||
| members: [person1, person2] | ||
| state_fips: 34 | ||
| output: | ||
| nj_income_tax: 2_640 |
15 changes: 7 additions & 8 deletions
15
policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/taxable_income/nj_agi.yaml
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
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
17 changes: 17 additions & 0 deletions
17
policyengine_us/variables/gov/states/nj/tax/income/adjusted_gross_income/nj_gross_income.py
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| from policyengine_us.model_api import * | ||
|
|
||
|
|
||
| class nj_gross_income(Variable): | ||
| value_type = float | ||
| entity = Person | ||
| label = "New Jersey gross income" | ||
| unit = USD | ||
| documentation = "Gross income calculated from specific income categories per NJ statute, before additions and subtractions. This is built from gross income sources, not federal AGI." | ||
| definition_period = YEAR | ||
| reference = ( | ||
| "https://law.justia.com/codes/new-jersey/title-54a/section-54a-5-1/", | ||
| "https://www.nj.gov/treasury/taxation/pdf/current/1040.pdf", # Lines 15-27 | ||
| ) | ||
| defined_for = StateCode.NJ | ||
|
|
||
| adds = "gov.states.nj.tax.income.gross_income_sources" |
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
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.
Uh oh!
There was an error while loading. Please reload this page.