From a159438dba385b2736858c75ac820ba607db37bc Mon Sep 17 00:00:00 2001 From: David Trimmer Date: Thu, 7 Nov 2024 06:43:08 -0500 Subject: [PATCH 01/35] Fixes #5311 (#5312) --- changelog_entry.yaml | 4 ++++ .../gov/irs/credits/eitc/phase_out/joint_bonus.yaml | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..940bdd2900d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + added: + - Update EITC joint bonus for childless filers. diff --git a/policyengine_us/parameters/gov/irs/credits/eitc/phase_out/joint_bonus.yaml b/policyengine_us/parameters/gov/irs/credits/eitc/phase_out/joint_bonus.yaml index e3c86b1cde2..bb264fe947d 100644 --- a/policyengine_us/parameters/gov/irs/credits/eitc/phase_out/joint_bonus.yaml +++ b/policyengine_us/parameters/gov/irs/credits/eitc/phase_out/joint_bonus.yaml @@ -50,7 +50,7 @@ brackets: 2022-01-01: 6_130 # 15_290 - 9_160 2023-01-01: 6_570 # 16_370 - 9_800 2024-01-01: 6_920 # 17_250 - 10_330 - 2025-01-01: 7_710 # 17_730 - 10_620 + 2025-01-01: 7_110 # 17_730 - 10_620 # CBO forecast. 2026-01-01: 7_250 2027-01-01: 7_400 From d8173188770d530bf1121f3b944eafce2b626b18 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Thu, 7 Nov 2024 11:46:58 +0000 Subject: [PATCH 02/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2af2002c75e..127b1c3e369 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.139.0] - 2024-11-07 11:43:28 + +### Added + +- Update EITC joint bonus for childless filers. + ## [1.138.0] - 2024-11-05 21:37:21 ### Added @@ -10144,6 +10150,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.139.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.138.0...1.139.0 [1.138.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.137.4...1.138.0 [1.137.4]: https://github.com/PolicyEngine/policyengine-us/compare/1.137.3...1.137.4 [1.137.3]: https://github.com/PolicyEngine/policyengine-us/compare/1.137.2...1.137.3 diff --git a/changelog.yaml b/changelog.yaml index 22cf242f092..d6df98d1fe6 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8600,3 +8600,8 @@ added: - SNAP 2024 SUA for Colorado date: 2024-11-05 21:37:21 +- bump: minor + changes: + added: + - Update EITC joint bonus for childless filers. + date: 2024-11-07 11:43:28 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 940bdd2900d..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: minor - changes: - added: - - Update EITC joint bonus for childless filers. diff --git a/setup.py b/setup.py index e6630292d06..31f15a84b58 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.138.0", + version="1.139.0", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 11e9c5249f9de3ecd394e90c98967ff03c2803d3 Mon Sep 17 00:00:00 2001 From: "Anthony V." Date: Sat, 9 Nov 2024 00:52:39 +0100 Subject: [PATCH 03/35] fix: Add label to Alaska tax param folder (#5314) --- changelog_entry.yaml | 4 ++++ policyengine_us/parameters/gov/states/ak/README.md | 1 + 2 files changed, 5 insertions(+) create mode 100644 policyengine_us/parameters/gov/states/ak/README.md diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..733e11ac622 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + added: + - Label to Alaska tax param folder diff --git a/policyengine_us/parameters/gov/states/ak/README.md b/policyengine_us/parameters/gov/states/ak/README.md new file mode 100644 index 00000000000..377913ba214 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ak/README.md @@ -0,0 +1 @@ +# Alaska From 3a0cfb861eadab02f049a3379ad87af89935964b Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Fri, 8 Nov 2024 23:56:25 +0000 Subject: [PATCH 04/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 127b1c3e369..9cf07e8df51 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.139.1] - 2024-11-08 23:52:56 + +### Added + +- Label to Alaska tax param folder + ## [1.139.0] - 2024-11-07 11:43:28 ### Added @@ -10150,6 +10156,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.139.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.0...1.139.1 [1.139.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.138.0...1.139.0 [1.138.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.137.4...1.138.0 [1.137.4]: https://github.com/PolicyEngine/policyengine-us/compare/1.137.3...1.137.4 diff --git a/changelog.yaml b/changelog.yaml index d6df98d1fe6..db3b1be7c44 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8605,3 +8605,8 @@ added: - Update EITC joint bonus for childless filers. date: 2024-11-07 11:43:28 +- bump: patch + changes: + added: + - Label to Alaska tax param folder + date: 2024-11-08 23:52:56 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 733e11ac622..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - added: - - Label to Alaska tax param folder diff --git a/setup.py b/setup.py index 31f15a84b58..c9f88dd6b66 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.139.0", + version="1.139.1", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From fb949218afba8fb4457adcc98501af3e0881b00a Mon Sep 17 00:00:00 2001 From: "Anthony V." Date: Sun, 10 Nov 2024 19:07:35 +0100 Subject: [PATCH 05/35] Correct meets_school_meal_categorical_eligibility for vectorized inputs (#5318) * fix: Correct meets_school_meal_categorical_eligibility for vectorized inputs * fix: Refactor formula for meets_school_meal_categorical_eligibility --- changelog_entry.yaml | 6 ++++++ .../meets_school_meal_categorical_eligibility.yaml | 9 +++++++++ .../meets_school_meal_categorical_eligibility.py | 6 +----- 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..99484778e0a 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,6 @@ +- bump: patch + changes: + fixed: + - Corrected meets_school_meal_categorical_eligilibity to properly calculate eligibility for vectorized inputs. + added: + - Test for meets_school_meal_categorical_eligibility with vectorized inputs. diff --git a/policyengine_us/tests/policy/baseline/gov/usda/school_meals/meets_school_meal_categorical_eligibility.yaml b/policyengine_us/tests/policy/baseline/gov/usda/school_meals/meets_school_meal_categorical_eligibility.yaml index 5735ce27dfd..4876bb6399a 100644 --- a/policyengine_us/tests/policy/baseline/gov/usda/school_meals/meets_school_meal_categorical_eligibility.yaml +++ b/policyengine_us/tests/policy/baseline/gov/usda/school_meals/meets_school_meal_categorical_eligibility.yaml @@ -81,3 +81,12 @@ is_head_start_eligible: false output: meets_school_meal_categorical_eligibility: false + +- name: Vectorized operations + period: 2024 + input: + snap: [1, 0, 0, 0, 0, 0, 0, 0] + fdpir: [0, 1, 1, 0, 0, 0, 0, 0] + is_homeless: [False, False, True, True, False, False, False, False] + output: + meets_school_meal_categorical_eligibility: [True, True, True, True, False, False, False, False] diff --git a/policyengine_us/variables/gov/usda/school_meals/meets_school_meal_categorical_eligibility.py b/policyengine_us/variables/gov/usda/school_meals/meets_school_meal_categorical_eligibility.py index a6baa464a28..7076727c35f 100644 --- a/policyengine_us/variables/gov/usda/school_meals/meets_school_meal_categorical_eligibility.py +++ b/policyengine_us/variables/gov/usda/school_meals/meets_school_meal_categorical_eligibility.py @@ -8,8 +8,4 @@ class meets_school_meal_categorical_eligibility(Variable): documentation = "Whether this SPM unit is eligible for free school meal via participation in other programs" definition_period = YEAR reference = "https://www.law.cornell.edu/cfr/text/7/245.2" - - def formula(spm_unit, period, parameters): - p = parameters(period).gov.usda.school_meals - programs = add(spm_unit, period, p.categorical_eligibility) - return np.any(programs) + adds = "gov.usda.school_meals.categorical_eligibility" From 5342559cbf98c933b78fe00166ebfa3f2260e57f Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Sun, 10 Nov 2024 18:11:25 +0000 Subject: [PATCH 06/35] Update PolicyEngine US --- CHANGELOG.md | 11 +++++++++++ changelog.yaml | 8 ++++++++ changelog_entry.yaml | 6 ------ setup.py | 2 +- 4 files changed, 20 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9cf07e8df51..e6f3be5911d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.139.2] - 2024-11-10 18:07:53 + +### Added + +- Test for meets_school_meal_categorical_eligibility with vectorized inputs. + +### Fixed + +- Corrected meets_school_meal_categorical_eligilibity to properly calculate eligibility for vectorized inputs. + ## [1.139.1] - 2024-11-08 23:52:56 ### Added @@ -10156,6 +10166,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.139.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.1...1.139.2 [1.139.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.0...1.139.1 [1.139.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.138.0...1.139.0 [1.138.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.137.4...1.138.0 diff --git a/changelog.yaml b/changelog.yaml index db3b1be7c44..f5eb3567f2a 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8610,3 +8610,11 @@ added: - Label to Alaska tax param folder date: 2024-11-08 23:52:56 +- bump: patch + changes: + added: + - Test for meets_school_meal_categorical_eligibility with vectorized inputs. + fixed: + - Corrected meets_school_meal_categorical_eligilibity to properly calculate eligibility + for vectorized inputs. + date: 2024-11-10 18:07:53 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 99484778e0a..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,6 +0,0 @@ -- bump: patch - changes: - fixed: - - Corrected meets_school_meal_categorical_eligilibity to properly calculate eligibility for vectorized inputs. - added: - - Test for meets_school_meal_categorical_eligibility with vectorized inputs. diff --git a/setup.py b/setup.py index c9f88dd6b66..545122e2f20 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.139.1", + version="1.139.2", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 8b57c5b6d09a9ecedfe735b82bb1a50090b0cb95 Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Sun, 10 Nov 2024 19:03:26 -0500 Subject: [PATCH 07/35] Los Angeles County Infant Supplement and Expectant Parent Payment Fixes #5319 --- changelog_entry.yaml | 5 +++ .../dss/expectant_parent_payment/amount.yaml | 12 +++++++ .../eligible_pregnancy_months.yaml | 10 ++++++ .../la/dss/infant_supplement/amount/base.yaml | 12 +++++++ .../infant_supplement/amount/group_home.yaml | 10 ++++++ .../ca_la_expectant_parent_payment.yaml | 23 ++++++++++++ ..._la_expectant_parent_payment_eligible.yaml | 35 +++++++++++++++++++ .../ca_la_infant_supplement.yaml | 23 ++++++++++++ .../ca_la_infant_supplement_eligible.yaml | 35 +++++++++++++++++++ .../ca_la_expectant_parent_payment.py | 17 +++++++++ ...ca_la_expectant_parent_payment_eligible.py | 14 ++++++++ .../ca_la_infant_supplement.py | 17 +++++++++ .../ca_la_infant_supplement_eligible.py | 14 ++++++++ .../person/in_foster_care_group_home.py | 10 ++++++ .../demographic/person/is_in_foster_care.py | 8 +++++ .../demographic/person/months_pregnant.py | 8 +++++ 16 files changed, 253 insertions(+) create mode 100644 policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml create mode 100644 policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml create mode 100644 policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml create mode 100644 policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml create mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml create mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml create mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml create mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml create mode 100644 policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py create mode 100644 policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py create mode 100644 policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py create mode 100644 policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py create mode 100644 policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py create mode 100644 policyengine_us/variables/household/demographic/person/is_in_foster_care.py create mode 100644 policyengine_us/variables/household/demographic/person/months_pregnant.py diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..a627775f9a5 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,5 @@ +- bump: minor + changes: + added: + - Los Angeles County expectant parent payment. + - Los Angeles County infant supplement. diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml new file mode 100644 index 00000000000..02706bfad02 --- /dev/null +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml @@ -0,0 +1,12 @@ +description: The Califronia Department of Social Services provides the following Expectant Parent Payment amount, based on preganncy months. +values: + 2022-01-01: 900 +metadata: + unit: currency-USD + period: month + label: California Department of Social Services Expectant Parent Payment amount + reference: + - title: California Department of Social Services ALL COUNTY LETTER NO. 21-123 + href: https://cdss.ca.gov/Portals/9/Additional-Resources/Letters-and-Notices/ACLs/2021/21-123.pdf?ver=2021-10-08-140950-570 + - title: Los Angeles County Department of Children and Family Services Teen Parenting + href: https://dcfs.lacounty.gov/youth/teen-parenting/ diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml new file mode 100644 index 00000000000..1763b0cceb4 --- /dev/null +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml @@ -0,0 +1,10 @@ +description: The Califronia Department of Social Services provides the Expectant Parent Payment for this number of preganncy months. +values: + 2022-01-01: 3 +metadata: + unit: int + period: year + label: California Department of Social Services Expectant Parent Payment pregnancy months + reference: + - title: California Department of Social Services ALL COUNTY LETTER NO. 21-123 + href: https://cdss.ca.gov/Portals/9/Additional-Resources/Letters-and-Notices/ACLs/2021/21-123.pdf?ver=2021-10-08-140950-570 diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml new file mode 100644 index 00000000000..3423f363f86 --- /dev/null +++ b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml @@ -0,0 +1,12 @@ +description: The Califronia Department of Social Services provides the following base Infant Supplement amount. +values: + 2022-01-01: 900 +metadata: + unit: currency-USD + period: month + label: California Department of Social Services Infant Supplement base amount + reference: + - title: California Department of Social Services ALL COUNTY LETTER NO. 21-123 + href: https://cdss.ca.gov/Portals/9/Additional-Resources/Letters-and-Notices/ACLs/2021/21-123.pdf?ver=2021-10-08-140950-570 + - title: Los Angeles County Department of Children and Family Services Teen Parenting + href: https://dcfs.lacounty.gov/youth/teen-parenting/ diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml new file mode 100644 index 00000000000..ea9092836b4 --- /dev/null +++ b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml @@ -0,0 +1,10 @@ +description: The Califronia Department of Social Services provides the following Infant Supplement amount for filers in group homes or STRTP placements. +values: + 2022-01-01: 1_379 +metadata: + unit: currency-USD + period: month + label: California Department of Social Services Infant Supplement group homeamount + reference: + - title: Los Angeles County Department of Children and Family Services Teen Parenting + href: https://dcfs.lacounty.gov/youth/teen-parenting/ diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml new file mode 100644 index 00000000000..7a417780782 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml @@ -0,0 +1,23 @@ +- name: Only 6 months pregnant + period: 2022 + input: + ca_la_expectant_parent_payment_eligible: True + months_pregnant: 6 + output: + ca_la_expectant_parent_payment: 0 + +- name: 10 Months pregnant + period: 2022 + input: + ca_la_expectant_parent_payment_eligible: True + months_pregnant: 10 + output: + ca_la_expectant_parent_payment: 2_700 + +- name: No months pregnant + period: 2022 + input: + ca_la_expectant_parent_payment_eligible: True + months_pregnant: 0 + output: + ca_la_expectant_parent_payment: 0 diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml new file mode 100644 index 00000000000..f338877c88b --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml @@ -0,0 +1,35 @@ +- name: Eligible person, + period: 2022 + input: + in_la: True + is_in_foster_care: True + is_pregnant: True + output: + ca_la_expectant_parent_payment_eligible: True + +- name: Not pregnant + period: 2023 + input: + in_la: True + is_in_foster_care: True + is_pregnant: False + output: + ca_la_expectant_parent_payment_eligible: False + +- name: Not in LA + period: 2023 + input: + in_la: False + is_in_foster_care: True + is_pregnant: True + output: + ca_la_expectant_parent_payment_eligible: False + +- name: Not in foster care + period: 2024 + input: + in_la: True + is_in_foster_care: False + is_pregnant: True + output: + ca_la_expectant_parent_payment_eligible: False diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml new file mode 100644 index 00000000000..f5cae2c110f --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml @@ -0,0 +1,23 @@ +- name: Not in group home + period: 2024 + input: + ca_la_infant_supplement_eligible: True + is_in_foster_care_group_home: False + output: + ca_la_infant_supplement: 10_800 + +- name: In group home + period: 2022 + input: + ca_la_infant_supplement_eligible: True + is_in_foster_care_group_home: True + output: + ca_la_infant_supplement: 16_548 + +- name: Ineligible + period: 2024 + input: + ca_la_infant_supplement_eligible: False + is_in_foster_care_group_home: True + output: + ca_la_infant_supplement: 0 diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml new file mode 100644 index 00000000000..4462f848ed6 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml @@ -0,0 +1,35 @@ +- name: Eligible person, + period: 2022 + input: + in_la: True + is_in_foster_care: True + is_parent: True + output: + ca_la_infant_supplement_eligible: True + +- name: Not a parent + period: 2023 + input: + in_la: True + is_in_foster_care: True + is_parent: False + output: + ca_la_infant_supplement_eligible: False + +- name: Not in LA + period: 2023 + input: + in_la: False + is_in_foster_care: True + is_parent: True + output: + ca_la_infant_supplement_eligible: False + +- name: Not in foster care + period: 2024 + input: + in_la: True + is_in_foster_care: False + is_parent: True + output: + ca_la_infant_supplement_eligible: False diff --git a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py new file mode 100644 index 00000000000..4c00d256b45 --- /dev/null +++ b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py @@ -0,0 +1,17 @@ +from policyengine_us.model_api import * + + +class ca_la_expectant_parent_payment(Variable): + value_type = float + entity = Person + definition_period = YEAR + label = "Los Angeles County expectant parent payment" + defined_for = "ca_la_expectant_parent_payment_eligible" + + def formula(person, period, parameters): + p = parameters(period).gov.local.ca.la.dss.expectant_parent_payment + months_pregnant = person("months_pregnant", period) + eligible_pregancy_months = max_(0, months_pregnant - 6) + return p.amount * min_( + eligible_pregancy_months, p.eligible_pregnancy_months + ) diff --git a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py new file mode 100644 index 00000000000..36429b77722 --- /dev/null +++ b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py @@ -0,0 +1,14 @@ +from policyengine_us.model_api import * + + +class ca_la_expectant_parent_payment_eligible(Variable): + value_type = bool + entity = Person + definition_period = YEAR + label = "Eligible for the Los Angeles County expectant parent paymentt" + defined_for = "in_la" + + def formula(person, period, parameters): + foster_care = person("is_in_foster_care", period) + is_pregnant = person("is_pregnant", period) + return foster_care & is_pregnant diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py new file mode 100644 index 00000000000..b30385afa85 --- /dev/null +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py @@ -0,0 +1,17 @@ +from policyengine_us.model_api import * + + +class ca_la_infant_supplement(Variable): + value_type = float + entity = Person + definition_period = YEAR + label = "Los Angeles County infant supplement" + defined_for = "ca_la_infant_supplement_eligible" + + def formula(person, period, parameters): + p = parameters(period).gov.local.ca.la.dss.infant_supplement + is_in_group_home = person("is_in_foster_care_group_home", period) + return ( + where(is_in_group_home, p.amount.group_home, p.amount.base) + * MONTHS_IN_YEAR + ) diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py new file mode 100644 index 00000000000..92125dd0457 --- /dev/null +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py @@ -0,0 +1,14 @@ +from policyengine_us.model_api import * + + +class ca_la_infant_supplement_eligible(Variable): + value_type = bool + entity = Person + definition_period = YEAR + label = "Eligible for the Los Angeles County infant supplement" + defined_for = "in_la" + + def formula(person, period, parameters): + foster_care = person("is_in_foster_care", period) + is_parent = person("is_parent", period) + return foster_care & is_parent diff --git a/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py b/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py new file mode 100644 index 00000000000..5a301ab756f --- /dev/null +++ b/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py @@ -0,0 +1,10 @@ +from policyengine_us.model_api import * + + +class is_in_foster_care_group_home(Variable): + value_type = bool + entity = Person + label = "Person is currently in the a qualifying foster care group home" + definition_period = YEAR + default_value = False + defined_for = "is_in_foster_care" diff --git a/policyengine_us/variables/household/demographic/person/is_in_foster_care.py b/policyengine_us/variables/household/demographic/person/is_in_foster_care.py new file mode 100644 index 00000000000..75c40d78415 --- /dev/null +++ b/policyengine_us/variables/household/demographic/person/is_in_foster_care.py @@ -0,0 +1,8 @@ +from policyengine_us.model_api import * + + +class is_in_foster_care(Variable): + value_type = bool + entity = Person + label = "Person is currently in the a qualifying foster care institution" + definition_period = YEAR diff --git a/policyengine_us/variables/household/demographic/person/months_pregnant.py b/policyengine_us/variables/household/demographic/person/months_pregnant.py new file mode 100644 index 00000000000..8eaced64bba --- /dev/null +++ b/policyengine_us/variables/household/demographic/person/months_pregnant.py @@ -0,0 +1,8 @@ +from policyengine_us.model_api import * + + +class months_pregnant(Variable): + value_type = int + entity = Person + label = "Number of months into the pregnancy" + definition_period = YEAR From 368f34ccad08617c55609ce5181031213e729530 Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Sun, 10 Nov 2024 19:05:20 -0500 Subject: [PATCH 08/35] format --- .../household/demographic/person/in_foster_care_group_home.py | 2 +- .../variables/household/demographic/person/is_in_foster_care.py | 2 +- .../variables/household/demographic/person/months_pregnant.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py b/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py index 5a301ab756f..cdc34eebff0 100644 --- a/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py +++ b/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py @@ -4,7 +4,7 @@ class is_in_foster_care_group_home(Variable): value_type = bool entity = Person - label = "Person is currently in the a qualifying foster care group home" + label = "Person is currently in a qualifying foster care group home" definition_period = YEAR default_value = False defined_for = "is_in_foster_care" diff --git a/policyengine_us/variables/household/demographic/person/is_in_foster_care.py b/policyengine_us/variables/household/demographic/person/is_in_foster_care.py index 75c40d78415..ac21bfd0eaa 100644 --- a/policyengine_us/variables/household/demographic/person/is_in_foster_care.py +++ b/policyengine_us/variables/household/demographic/person/is_in_foster_care.py @@ -4,5 +4,5 @@ class is_in_foster_care(Variable): value_type = bool entity = Person - label = "Person is currently in the a qualifying foster care institution" + label = "Person is currently in a qualifying foster care institution" definition_period = YEAR diff --git a/policyengine_us/variables/household/demographic/person/months_pregnant.py b/policyengine_us/variables/household/demographic/person/months_pregnant.py index 8eaced64bba..f02bf81982c 100644 --- a/policyengine_us/variables/household/demographic/person/months_pregnant.py +++ b/policyengine_us/variables/household/demographic/person/months_pregnant.py @@ -4,5 +4,5 @@ class months_pregnant(Variable): value_type = int entity = Person - label = "Number of months into the pregnancy" + label = "Number of pregnancy months completed" definition_period = YEAR From 2ad193c2d1dbcb1a49e38284f1cef429328a8a4f Mon Sep 17 00:00:00 2001 From: Nikhil Woodruff <35577657+nikhilwoodruff@users.noreply.github.com> Date: Mon, 11 Nov 2024 04:40:01 +0000 Subject: [PATCH 09/35] Fix NJ EITC bug (#5201) * Update US data * Bump to PE-US-Data 1.10 * Adjust test? * Bump to 1.11 data * Add extra cg bracket * cg breacket * remove rate * format * testing, not finished * test fixes --------- Co-authored-by: PavelMakarchuk --- changelog_entry.yaml | 4 +++ .../gov/irs/capital_gains/brackets.yaml | 1 + .../nj/tax/income/credits/eitc/nj_eitc.yaml | 33 +++++++++++++++++-- .../states/nj/tax/income/nj_income_tax.yaml | 1 + .../nj/tax/income/credits/eitc/nj_eitc.py | 14 +++++++- 5 files changed, 50 insertions(+), 3 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..92599cb48b4 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + fixed: + - NJ EITC correctly calculates federal EITC entitlement. diff --git a/policyengine_us/parameters/gov/irs/capital_gains/brackets.yaml b/policyengine_us/parameters/gov/irs/capital_gains/brackets.yaml index 69ae43374c0..345bc9e0943 100644 --- a/policyengine_us/parameters/gov/irs/capital_gains/brackets.yaml +++ b/policyengine_us/parameters/gov/irs/capital_gains/brackets.yaml @@ -7,6 +7,7 @@ rates: 2013-01-01: 0.15 3: 2013-01-01: 0.2 + metadata: unit: /1 thresholds: diff --git a/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/credits/eitc/nj_eitc.yaml b/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/credits/eitc/nj_eitc.yaml index 80605c84cf6..73c420228b7 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/credits/eitc/nj_eitc.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/credits/eitc/nj_eitc.yaml @@ -1,5 +1,5 @@ - name: New Jersey EITC, fraction of federal EITC (qualifies for federal EITC) - period: 2022 + period: 2023 absolute_error_margin: 0 input: eitc: 100 @@ -7,7 +7,9 @@ nj_childless_eitc_age_eligible: true state_code: NJ output: - nj_eitc: 40 + eitc: 100 + nj_childless_eitc_age_eligible: true + nj_eitc: 240 - name: New Jersey EITC, fraction of max zero-child federal EITC (doesn't qualify for federal EITC because too young) period: 2022 @@ -41,3 +43,30 @@ state_code: NY output: nj_eitc: 0 + +- name: 40% match for households receiving the federal EITC. + period: 2022 + absolute_error_margin: 0 + input: + eitc_eligible: true + eitc_phased_in: 1_000 + eitc_reduction: 500 + takes_up_eitc: true + eitc: 100 + state_code: NJ + output: + nj_eitc: 40 + +- name: 40% of childless EITC for households not eligible for federal EITC but eligible for childless EITC + period: 2023 + absolute_error_margin: 0 + input: + eitc_eligible: false + eitc_phased_in: 1_000 + eitc_reduction: 500 + takes_up_eitc: true + eitc: 100 + state_code: NJ + nj_childless_eitc_age_eligible: true + output: + nj_eitc: 240 diff --git a/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/nj_income_tax.yaml b/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/nj_income_tax.yaml index 7e022f3f892..06fa60434d9 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/nj_income_tax.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/nj/tax/income/nj_income_tax.yaml @@ -4,6 +4,7 @@ state_code: NJ nj_agi: 9_999 filing_status: SINGLE + nj_childless_eitc_age_eligible: false output: nj_income_tax: 0 diff --git a/policyengine_us/variables/gov/states/nj/tax/income/credits/eitc/nj_eitc.py b/policyengine_us/variables/gov/states/nj/tax/income/credits/eitc/nj_eitc.py index 227ffb78b4e..3bf95b796d9 100644 --- a/policyengine_us/variables/gov/states/nj/tax/income/credits/eitc/nj_eitc.py +++ b/policyengine_us/variables/gov/states/nj/tax/income/credits/eitc/nj_eitc.py @@ -23,9 +23,21 @@ def formula(tax_unit, period, parameters): # Otherwise, return 0. # Worksheet reference: https://www.state.nj.us/treasury/taxation/pdf/current/1040i.pdf#page=43 + federal_eitc_eligible_assuming_meets_income_test = tax_unit( + "eitc_eligible", period + ) + federal_eitc_meets_income_test = tax_unit( + "eitc_phased_in", period + ) > tax_unit("eitc_reduction", period) + federal_eitc_takes_up = tax_unit("takes_up_eitc", period) + federal_eitc_eligible = ( + federal_eitc_eligible_assuming_meets_income_test + & federal_eitc_meets_income_test + & federal_eitc_takes_up + ) federal_eitc = select( [ - tax_unit("eitc_eligible", period), + federal_eitc_eligible, tax_unit("nj_childless_eitc_age_eligible", period), ], [ From 9afbe5430d580aecdc9252a45baf82d4d1c6b4d3 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Mon, 11 Nov 2024 04:43:49 +0000 Subject: [PATCH 10/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e6f3be5911d..04014f02e53 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.140.0] - 2024-11-11 04:40:19 + +### Fixed + +- NJ EITC correctly calculates federal EITC entitlement. + ## [1.139.2] - 2024-11-10 18:07:53 ### Added @@ -10166,6 +10172,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.140.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.2...1.140.0 [1.139.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.1...1.139.2 [1.139.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.0...1.139.1 [1.139.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.138.0...1.139.0 diff --git a/changelog.yaml b/changelog.yaml index f5eb3567f2a..38eff0ab413 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8618,3 +8618,8 @@ - Corrected meets_school_meal_categorical_eligilibity to properly calculate eligibility for vectorized inputs. date: 2024-11-10 18:07:53 +- bump: minor + changes: + fixed: + - NJ EITC correctly calculates federal EITC entitlement. + date: 2024-11-11 04:40:19 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 92599cb48b4..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: minor - changes: - fixed: - - NJ EITC correctly calculates federal EITC entitlement. diff --git a/setup.py b/setup.py index 545122e2f20..717c70e8e77 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.139.2", + version="1.140.0", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From f916db5a460001e388480a4734f3002798c1e6c4 Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Sun, 10 Nov 2024 22:47:33 -0600 Subject: [PATCH 11/35] Iowa Income Tax Rates 2023-2026 (#5221) * Iowa Income Tax Rates 2023-2025 Fixes #5185 * ajdust variables and brackets * changelog * rename files --- changelog_entry.yaml | 4 ++ .../income/rates/by_filing_status/active.yaml | 13 ++++++ .../income/rates/by_filing_status/joint.yaml | 45 +++++++++++++++++++ .../income/rates/by_filing_status/other.yaml | 45 +++++++++++++++++++ .../income/rates/{all.yaml => combined.yaml} | 18 +------- .../ia/tax/income/ia_regular_tax_indiv.yaml | 18 ++++++-- .../ia/tax/income/ia_regular_tax_joint.yaml | 24 +++++++--- .../ia/tax/income/ia_regular_tax_indiv.py | 15 ++++++- .../ia/tax/income/ia_regular_tax_joint.py | 15 ++++++- .../ia/tax/income/ia_withheld_income_tax.py | 4 +- 10 files changed, 168 insertions(+), 33 deletions(-) create mode 100644 policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/active.yaml create mode 100644 policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/joint.yaml create mode 100644 policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/other.yaml rename policyengine_us/parameters/gov/states/ia/tax/income/rates/{all.yaml => combined.yaml} (81%) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..b7e38fd2e49 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + fixed: + - Iowa Income Tax Rates 2023-2026. diff --git a/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/active.yaml b/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/active.yaml new file mode 100644 index 00000000000..d0ed3b74ea7 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/active.yaml @@ -0,0 +1,13 @@ +description: Iowa applies a new income tax rate structure if this is true. +values: + 2020-01-01: false + 2023-01-01: true +metadata: + unit: bool + period: year + label: Iowa post 2023 income tax structure applies + reference: + - title: Iowa Senate File 2442 + href: https://www.legis.iowa.gov/legislation/BillBook?ga=90&ba=SF%202442 + - title: IDR Announces 2023 Interest Rates, Deductions, Income Tax Brackets + href: https://revenue.iowa.gov/taxes/tax-guidance/individual-income-tax/2023-changes-iowa-individual-income-tax diff --git a/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/joint.yaml b/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/joint.yaml new file mode 100644 index 00000000000..ff2bf1b51af --- /dev/null +++ b/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/joint.yaml @@ -0,0 +1,45 @@ +description: Iowa levies income taxes at these rates for all joint filers post 2023. +brackets: + - threshold: + 2023-01-01: 0 + rate: + 2023-01-01: 0.044 + 2024-01-01: 0.04 + 2026-01-01: 0.039 + - threshold: + 2023-01-01: 12_000 + 2024-01-01: 12_420 + 2026-01-01: .inf + rate: + 2023-01-01: 0.0482 + - threshold: + 2023-01-01: 60_000 + 2024-01-01: 62_100 + 2025-01-01: .inf + rate: + 2023-01-01: 0.057 + - threshold: + 2023-01-01: 150_000 + 2024-01-01: .inf + rate: + 2023-01-01: 0.06 + - threshold: + 2023-01-01: .inf + + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Iowa joint filers income tax rates and brackets post 2023 + reference: + # the legal code does not represent the newest legislative changes + - title: Iowa Senate File 2442 + href: https://www.legis.iowa.gov/legislation/BillBook?ga=90&ba=SF%202442 + - title: IDR Announces 2023 Interest Rates, Deductions, Income Tax Brackets + href: https://revenue.iowa.gov/taxes/tax-guidance/individual-income-tax/2023-changes-iowa-individual-income-tax + - title: 2023 IA 1041 Instructions + href: https://tax.iowa.gov/sites/default/files/2023-11/IA1041Inst%2863002%29.pdf#page=4 + - title: IDR Announces 2024 Interest Rates, Deductions, Income Tax Brackets + href: https://revenue.iowa.gov/press-release/2023-10-25/idr-announces-2024-individual-income-tax-brackets-and-interest-rates diff --git a/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/other.yaml b/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/other.yaml new file mode 100644 index 00000000000..362a487c276 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ia/tax/income/rates/by_filing_status/other.yaml @@ -0,0 +1,45 @@ +description: Iowa levies income taxes at these rates for all filers other than joint filers post 2023. +brackets: + - threshold: + 2023-01-01: 0 + rate: + 2023-01-01: 0.044 + 2024-01-01: 0.04 + 2026-01-01: 0.039 + - threshold: + 2023-01-01: 6_000 + 2024-01-01: 6_210 + 2026-01-01: .inf + rate: + 2023-01-01: 0.0482 + - threshold: + 2023-01-01: 30_000 + 2024-01-01: 31_050 + 2025-01-01: .inf + rate: + 2023-01-01: 0.057 + - threshold: + 2023-01-01: 75_000 + 2024-01-01: .inf + rate: + 2023-01-01: 0.06 + - threshold: + 2023-01-01: .inf + + +metadata: + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + threshold_period: year + label: Iowa other filers income tax rates and brackets post 2023 + reference: + # The Iowa legal code does not represent the newest legislative changes + - title: Iowa Senate File 2442 + href: https://www.legis.iowa.gov/legislation/BillBook?ga=90&ba=SF%202442 + - title: IDR Announces 2023 Interest Rates, Deductions, Income Tax Brackets + href: https://revenue.iowa.gov/taxes/tax-guidance/individual-income-tax/2023-changes-iowa-individual-income-tax + - title: 2023 IA 1041 Instructions + href: https://tax.iowa.gov/sites/default/files/2023-11/IA1041Inst%2863002%29.pdf#page=4 + - title: IDR Announces 2024 Interest Rates, Deductions, Income Tax Brackets + href: https://revenue.iowa.gov/press-release/2023-10-25/idr-announces-2024-individual-income-tax-brackets-and-interest-rates diff --git a/policyengine_us/parameters/gov/states/ia/tax/income/rates/all.yaml b/policyengine_us/parameters/gov/states/ia/tax/income/rates/combined.yaml similarity index 81% rename from policyengine_us/parameters/gov/states/ia/tax/income/rates/all.yaml rename to policyengine_us/parameters/gov/states/ia/tax/income/rates/combined.yaml index aeffbe24350..4c1ea9ca2c3 100644 --- a/policyengine_us/parameters/gov/states/ia/tax/income/rates/all.yaml +++ b/policyengine_us/parameters/gov/states/ia/tax/income/rates/combined.yaml @@ -1,63 +1,47 @@ -description: Iowa levies income taxes at these rates for all filers. +description: Iowa levies income taxes at these rates for all filers pre 2023. brackets: - threshold: 2021-01-01: 0 rate: 2021-01-01: 0.0033 - 2023-01-01: 0.044 - 2026-01-01: 0.039 - threshold: 2021-01-01: 1_676 2022-01-01: 1_743 - 2023-01-01: 6_000 - 2026-01-01: .inf rate: 2021-01-01: 0.0067 - 2023-01-01: 0.0482 - threshold: 2021-01-01: 3_352 2022-01-01: 3_486 - 2023-01-01: 30_000 - 2025-01-01: .inf rate: 2021-01-01: 0.0225 - 2023-01-01: 0.057 - threshold: 2021-01-01: 6_704 2022-01-01: 6_972 - 2023-01-01: 75_000 - 2024-01-01: .inf rate: 2021-01-01: 0.0414 - 2023-01-01: 0.06 - threshold: 2021-01-01: 15_084 2022-01-01: 15_687 - 2023-01-01: .inf rate: 2021-01-01: 0.0563 - threshold: 2021-01-01: 25_140 2022-01-01: 26_145 - 2023-01-01: .inf rate: 2021-01-01: 0.0596 - threshold: 2021-01-01: 33_520 2022-01-01: 34_860 - 2023-01-01: .inf rate: 2021-01-01: 0.0625 - threshold: 2021-01-01: 50_280 2022-01-01: 52_290 - 2023-01-01: .inf rate: 2021-01-01: 0.0744 - threshold: 2021-01-01: 75_420 2022-01-01: 78_435 - 2023-01-01: .inf rate: 2021-01-01: 0.0853 diff --git a/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_indiv.yaml b/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_indiv.yaml index 4093ce9ae55..0084545f62b 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_indiv.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_indiv.yaml @@ -40,6 +40,7 @@ input: ia_taxable_income_indiv: 6_000 state_code: IA + filing_status: SEPARATE output: ia_regular_tax_indiv: 264 @@ -49,6 +50,7 @@ input: ia_taxable_income_indiv: 7_000 state_code: IA + filing_status: SEPARATE output: ia_regular_tax_indiv: 312.2 @@ -58,6 +60,7 @@ input: ia_taxable_income_indiv: 30_000 state_code: IA + filing_status: SEPARATE output: ia_regular_tax_indiv: 1_420.8 #6_000*0.044+24_000*0.0482=1420.8 @@ -67,6 +70,7 @@ input: ia_taxable_income_indiv: 80_000 state_code: IA + filing_status: SINGLE output: ia_regular_tax_indiv: 4_285.8 @@ -76,8 +80,9 @@ input: ia_taxable_income_indiv: 30_000 state_code: IA + filing_status: SINGLE output: - ia_regular_tax_indiv: 1_420.8 + ia_regular_tax_indiv: 1_395.08 - name: IA regular tax indiv unit test 10, using all rates 2024 absolute_error_margin: 0.5 @@ -85,8 +90,9 @@ input: ia_taxable_income_indiv: 80_000 state_code: IA + filing_status: SINGLE output: - ia_regular_tax_indiv: 4_270.8 + ia_regular_tax_indiv: 4_235.83 - name: IA regular tax indiv unit test 11, using two rates 2025 absolute_error_margin: 0.5 @@ -94,8 +100,9 @@ input: ia_taxable_income_indiv: 30_000 state_code: IA + filing_status: SEPARATE output: - ia_regular_tax_indiv: 1_420.8 + ia_regular_tax_indiv: 1_395.08 - name: IA regular tax indiv unit test 12, using all rates 2025 absolute_error_margin: 0.5 @@ -103,8 +110,9 @@ input: ia_taxable_income_indiv: 80_000 state_code: IA + filing_status: SEPARATE output: - ia_regular_tax_indiv: 3_830.8 + ia_regular_tax_indiv: 3_805.08 - name: IA regular tax indiv unit test 13, using two rates 2026 absolute_error_margin: 0.5 @@ -112,6 +120,7 @@ input: ia_taxable_income_indiv: 30_000 state_code: IA + filing_status: SEPARATE output: ia_regular_tax_indiv: 1_170 @@ -121,5 +130,6 @@ input: ia_taxable_income_indiv: 80_000 state_code: IA + filing_status: SEPARATE output: ia_regular_tax_indiv: 3_120 diff --git a/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_joint.yaml b/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_joint.yaml index 3baa36ac6ee..5e7ce895435 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_joint.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/ia/tax/income/ia_regular_tax_joint.yaml @@ -40,6 +40,7 @@ input: ia_taxable_income_joint: 6_000 state_code: IA + filing_status: JOINT output: ia_regular_tax_joint: 264 @@ -49,8 +50,9 @@ input: ia_taxable_income_joint: 7_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 312.2 + ia_regular_tax_joint: 308 - name: IA regular tax joint unit test 7, using two rates 2023 absolute_error_margin: 0.5 @@ -58,8 +60,9 @@ input: ia_taxable_income_joint: 30_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 1_420.8 #6_000*0.044+24_000*0.0482=1420.8 + ia_regular_tax_joint: 1_395.6 - name: IA regular tax joint unit test 8, using all rates 2023 absolute_error_margin: 0.5 @@ -67,8 +70,9 @@ input: ia_taxable_income_joint: 80_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 4_285.8 + ia_regular_tax_joint: 3_981.6 - name: IA regular tax joint unit test 9, using two rates 2024 absolute_error_margin: 0.5 @@ -76,8 +80,9 @@ input: ia_taxable_income_joint: 30_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 1_420.8 + ia_regular_tax_joint: 1_344.2 - name: IA regular tax joint unit test 10, using all rates 2024 absolute_error_margin: 0.5 @@ -85,8 +90,9 @@ input: ia_taxable_income_joint: 80_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 4_270.8 + ia_regular_tax_joint: 3_911.7 - name: IA regular tax joint unit test 11, using two rates 2025 absolute_error_margin: 0.5 @@ -94,8 +100,9 @@ input: ia_taxable_income_joint: 30_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 1_420.8 + ia_regular_tax_joint: 1_344.2 - name: IA regular tax joint unit test 12, using all rates 2025 absolute_error_margin: 0.5 @@ -103,8 +110,9 @@ input: ia_taxable_income_joint: 80_000 state_code: IA + filing_status: JOINT output: - ia_regular_tax_joint: 3_830.8 + ia_regular_tax_joint: 3_754.2 - name: IA regular tax joint unit test 13, using two rates 2026 absolute_error_margin: 0.5 @@ -112,6 +120,7 @@ input: ia_taxable_income_joint: 30_000 state_code: IA + filing_status: JOINT output: ia_regular_tax_joint: 1_170 @@ -121,5 +130,6 @@ input: ia_taxable_income_joint: 80_000 state_code: IA + filing_status: JOINT output: ia_regular_tax_joint: 3_120 diff --git a/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_indiv.py b/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_indiv.py index bf701d3aac4..523a1e86ad2 100644 --- a/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_indiv.py +++ b/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_indiv.py @@ -18,5 +18,16 @@ class ia_regular_tax_indiv(Variable): def formula(person, period, parameters): taxable_income = person("ia_taxable_income_indiv", period) - p = parameters(period).gov.states.ia.tax.income - return p.rates.all.calc(max_(0, taxable_income)) + p = parameters(period).gov.states.ia.tax.income.rates + if p.by_filing_status.active: + filing_status = person.tax_unit( + "filing_status", + period, + ) + joint = filing_status == filing_status.possible_values.JOINT + return where( + joint, + p.by_filing_status.joint.calc(taxable_income), + p.by_filing_status.other.calc(taxable_income), + ) + return p.combined.calc(taxable_income) diff --git a/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_joint.py b/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_joint.py index bbe706827a8..3d2db7d3f2c 100644 --- a/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_joint.py +++ b/policyengine_us/variables/gov/states/ia/tax/income/ia_regular_tax_joint.py @@ -18,5 +18,16 @@ class ia_regular_tax_joint(Variable): def formula(person, period, parameters): taxable_income = person("ia_taxable_income_joint", period) - p = parameters(period).gov.states.ia.tax.income - return p.rates.all.calc(max_(0, taxable_income)) + p = parameters(period).gov.states.ia.tax.income.rates + if p.by_filing_status.active: + filing_status = person.tax_unit( + "filing_status", + period, + ) + joint = filing_status == filing_status.possible_values.JOINT + return where( + joint, + p.by_filing_status.joint.calc(taxable_income), + p.by_filing_status.other.calc(taxable_income), + ) + return p.combined.calc(taxable_income) diff --git a/policyengine_us/variables/gov/states/ia/tax/income/ia_withheld_income_tax.py b/policyengine_us/variables/gov/states/ia/tax/income/ia_withheld_income_tax.py index 412c753b9f8..7709214b199 100644 --- a/policyengine_us/variables/gov/states/ia/tax/income/ia_withheld_income_tax.py +++ b/policyengine_us/variables/gov/states/ia/tax/income/ia_withheld_income_tax.py @@ -19,4 +19,6 @@ def formula(person, period, parameters): else: standard_deduction = p.deductions.standard.amount["SINGLE"] reduced_agi = max_(agi - standard_deduction, 0) - return p.rates.all.calc(reduced_agi) + if p.rates.by_filing_status.active: + return p.rates.by_filing_status.other.calc(reduced_agi) + return p.rates.combined.calc(reduced_agi) From de88f46ad17be4a146bd867cab92b6e172e1bedc Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Mon, 11 Nov 2024 04:51:19 +0000 Subject: [PATCH 12/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 04014f02e53..54957542d85 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.140.1] - 2024-11-11 04:47:50 + +### Fixed + +- Iowa Income Tax Rates 2023-2026. + ## [1.140.0] - 2024-11-11 04:40:19 ### Fixed @@ -10172,6 +10178,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.140.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.0...1.140.1 [1.140.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.2...1.140.0 [1.139.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.1...1.139.2 [1.139.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.0...1.139.1 diff --git a/changelog.yaml b/changelog.yaml index 38eff0ab413..1aa0765c393 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8623,3 +8623,8 @@ fixed: - NJ EITC correctly calculates federal EITC entitlement. date: 2024-11-11 04:40:19 +- bump: patch + changes: + fixed: + - Iowa Income Tax Rates 2023-2026. + date: 2024-11-11 04:47:50 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index b7e38fd2e49..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - fixed: - - Iowa Income Tax Rates 2023-2026. diff --git a/setup.py b/setup.py index 717c70e8e77..c9e16cb1219 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.140.0", + version="1.140.1", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 1820e315848075fe67c0b821929d928a6b42dbcc Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Mon, 11 Nov 2024 17:59:40 -0500 Subject: [PATCH 13/35] refactor to monthly and add infant definition --- .../dss/expectant_parent_payment/amount.yaml | 2 +- .../pregnancy_month/max.yaml | 10 +++ .../min.yaml} | 4 +- .../la/dss/infant_supplement/amount/base.yaml | 2 +- .../infant_supplement/amount/group_home.yaml | 2 +- .../gov/states/ca/infant/age_limit.yaml | 11 ++++ .../ca_la_expectant_parent_payment.yaml | 20 ++---- ..._la_expectant_parent_payment_eligible.yaml | 27 +++++--- .../ca_la_infant_supplement.yaml | 61 ++++++++++++++++--- .../ca_la_infant_supplement_eligible.yaml | 35 ----------- ..._la_infant_supplement_eligible_infant.yaml | 23 +++++++ ..._la_infant_supplement_eligible_person.yaml | 35 +++++++++++ .../ca_la_expectant_parent_payment.py | 8 +-- ...ca_la_expectant_parent_payment_eligible.py | 10 ++- .../ca_la_infant_supplement.py | 26 +++++--- ...ca_la_infant_supplement_eligible_infant.py | 15 +++++ ...a_la_infant_supplement_eligible_person.py} | 6 +- .../person/current_pregnancy_month.py | 9 +++ .../demographic/person/is_in_foster_care.py | 2 +- ...ome.py => is_in_foster_care_group_home.py} | 2 +- .../demographic/person/months_pregnant.py | 8 --- 21 files changed, 214 insertions(+), 104 deletions(-) create mode 100644 policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml rename policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/{eligible_pregnancy_months.yaml => pregnancy_month/min.yaml} (70%) create mode 100644 policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml delete mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml create mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.yaml create mode 100644 policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml create mode 100644 policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py rename policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/{ca_la_infant_supplement_eligible.py => ca_la_infant_supplement_eligible_person.py} (70%) create mode 100644 policyengine_us/variables/household/demographic/person/current_pregnancy_month.py rename policyengine_us/variables/household/demographic/person/{in_foster_care_group_home.py => is_in_foster_care_group_home.py} (89%) delete mode 100644 policyengine_us/variables/household/demographic/person/months_pregnant.py diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml index 02706bfad02..0b0089035e3 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml @@ -1,4 +1,4 @@ -description: The Califronia Department of Social Services provides the following Expectant Parent Payment amount, based on preganncy months. +description: The California Department of Social Services provides the following Expectant Parent Payment amount, based on preganncy months. values: 2022-01-01: 900 metadata: diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml new file mode 100644 index 00000000000..235efb48c21 --- /dev/null +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml @@ -0,0 +1,10 @@ +description: The California Department of Social Services provides the Expectant Parent Payment on and before this pregnancy month. +values: + 2022-01-01: 6 +metadata: + unit: int + period: year + label: California Department of Social Services Expectant Parent Payment maximum pregnancy month + reference: + - title: California Department of Social Services ALL COUNTY LETTER NO. 21-123 + href: https://cdss.ca.gov/Portals/9/Additional-Resources/Letters-and-Notices/ACLs/2021/21-123.pdf?ver=2021-10-08-140950-570 diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml similarity index 70% rename from policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml rename to policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml index 1763b0cceb4..5f7a7cb3eb5 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/eligible_pregnancy_months.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml @@ -1,6 +1,6 @@ -description: The Califronia Department of Social Services provides the Expectant Parent Payment for this number of preganncy months. +description: The California Department of Social Services provides the Expectant Parent Payment on and after this pregnancy month. values: - 2022-01-01: 3 + 2022-01-01: 6 metadata: unit: int period: year diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml index 3423f363f86..0ee384faf21 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/base.yaml @@ -1,4 +1,4 @@ -description: The Califronia Department of Social Services provides the following base Infant Supplement amount. +description: The California Department of Social Services provides the following base Infant Supplement amount. values: 2022-01-01: 900 metadata: diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml index ea9092836b4..f4d872a2b29 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml @@ -1,4 +1,4 @@ -description: The Califronia Department of Social Services provides the following Infant Supplement amount for filers in group homes or STRTP placements. +description: The California Department of Social Services provides the following Infant Supplement amount for filers in group homes or STRTP placements. values: 2022-01-01: 1_379 metadata: diff --git a/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml b/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml new file mode 100644 index 00000000000..a22585af290 --- /dev/null +++ b/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml @@ -0,0 +1,11 @@ +description: California defines infants as children below this age threshold. +values: + 2020-01-01: 1 +metadata: + unit: year + period: year + label: California infant age limit + reference: + - title: California Code, Health and Safety Code - HSC § 124116, (f) + href: https://codes.findlaw.com/ca/health-and-safety-code/hsc-sect-124116/ + diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml index 7a417780782..f2c06907063 100644 --- a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.yaml @@ -1,23 +1,13 @@ -- name: Only 6 months pregnant - period: 2022 - input: - ca_la_expectant_parent_payment_eligible: True - months_pregnant: 6 - output: - ca_la_expectant_parent_payment: 0 - -- name: 10 Months pregnant - period: 2022 +- name: Eligible monthly + period: 2022-01 input: ca_la_expectant_parent_payment_eligible: True - months_pregnant: 10 output: - ca_la_expectant_parent_payment: 2_700 + ca_la_expectant_parent_payment: 900 -- name: No months pregnant +- name: Ineligible period: 2022 input: - ca_la_expectant_parent_payment_eligible: True - months_pregnant: 0 + ca_la_expectant_parent_payment_eligible: False output: ca_la_expectant_parent_payment: 0 diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml index f338877c88b..3023ec26ba8 100644 --- a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.yaml @@ -1,35 +1,44 @@ - name: Eligible person, - period: 2022 + period: 2022-01 input: in_la: True is_in_foster_care: True - is_pregnant: True + current_pregnancy_month: 6 output: ca_la_expectant_parent_payment_eligible: True -- name: Not pregnant - period: 2023 +- name: Pregnancy month before 6 + period: 2023-01 input: in_la: True is_in_foster_care: True - is_pregnant: False + current_pregnancy_month: 5 output: ca_la_expectant_parent_payment_eligible: False - name: Not in LA - period: 2023 + period: 2023-01 input: in_la: False is_in_foster_care: True - is_pregnant: True + current_pregnancy_month: 7 output: ca_la_expectant_parent_payment_eligible: False - name: Not in foster care - period: 2024 + period: 2024-01 input: in_la: True is_in_foster_care: False - is_pregnant: True + current_pregnancy_month: 8 + output: + ca_la_expectant_parent_payment_eligible: False + +- name: Pregnancy month after 9 + period: 2023-01 + input: + in_la: True + is_in_foster_care: True + current_pregnancy_month: 10 output: ca_la_expectant_parent_payment_eligible: False diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml index f5cae2c110f..f218e3e8f41 100644 --- a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml @@ -1,23 +1,64 @@ -- name: Not in group home +- name: Eligble household with one infant, not in group home period: 2024 input: - ca_la_infant_supplement_eligible: True - is_in_foster_care_group_home: False + people: + person1: + ca_la_infant_supplement_eligible_person: true + is_in_foster_care_group_home: false + person2: + ca_la_infant_supplement_eligible_infant: true + households: + household: + members: [person1, person2] + in_la: true output: ca_la_infant_supplement: 10_800 -- name: In group home - period: 2022 +- name: Eligble household with one infant, in group home + period: 2024 input: - ca_la_infant_supplement_eligible: True - is_in_foster_care_group_home: True + people: + person1: + ca_la_infant_supplement_eligible_person: true + is_in_foster_care_group_home: true + person2: + ca_la_infant_supplement_eligible_infant: true + households: + household: + members: [person1, person2] + in_la: true output: ca_la_infant_supplement: 16_548 -- name: Ineligible + +- name: Eligble household with no infant, in group home + period: 2024 + input: + people: + person1: + ca_la_infant_supplement_eligible_person: true + is_in_foster_care_group_home: true + person2: + ca_la_infant_supplement_eligible_infant: false + households: + household: + members: [person1, person2] + in_la: true + output: + ca_la_infant_supplement: 0 + +- name: Ineligble household with no infant, in group home period: 2024 input: - ca_la_infant_supplement_eligible: False - is_in_foster_care_group_home: True + people: + person1: + ca_la_infant_supplement_eligible_person: false + is_in_foster_care_group_home: true + person2: + ca_la_infant_supplement_eligible_infant: true + households: + household: + members: [person1, person2] + in_la: true output: ca_la_infant_supplement: 0 diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml deleted file mode 100644 index 4462f848ed6..00000000000 --- a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.yaml +++ /dev/null @@ -1,35 +0,0 @@ -- name: Eligible person, - period: 2022 - input: - in_la: True - is_in_foster_care: True - is_parent: True - output: - ca_la_infant_supplement_eligible: True - -- name: Not a parent - period: 2023 - input: - in_la: True - is_in_foster_care: True - is_parent: False - output: - ca_la_infant_supplement_eligible: False - -- name: Not in LA - period: 2023 - input: - in_la: False - is_in_foster_care: True - is_parent: True - output: - ca_la_infant_supplement_eligible: False - -- name: Not in foster care - period: 2024 - input: - in_la: True - is_in_foster_care: False - is_parent: True - output: - ca_la_infant_supplement_eligible: False diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.yaml new file mode 100644 index 00000000000..991cb8fc001 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.yaml @@ -0,0 +1,23 @@ +- name: Ineligible child + period: 2022 + input: + in_la: true + age: 2 + output: + ca_la_infant_supplement_eligible_infant: false + +- name: Eligible child + period: 2022 + input: + in_la: true + age: 1 + output: + ca_la_infant_supplement_eligible_infant: true + +- name: Eligible newborn + period: 2022 + input: + in_la: true + age: 0 + output: + ca_la_infant_supplement_eligible_infant: true diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml new file mode 100644 index 00000000000..8b146a73ab6 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml @@ -0,0 +1,35 @@ +- name: Eligible person, + period: 2022 + input: + in_la: true + is_in_foster_care: true + is_mother: true + output: + ca_la_infant_supplement_eligible_person: true + +- name: Not a parent + period: 2023 + input: + in_la: true + is_in_foster_care: true + is_mother: False + output: + ca_la_infant_supplement_eligible_person: False + +- name: Not in LA + period: 2023 + input: + in_la: False + is_in_foster_care: true + is_mother: true + output: + ca_la_infant_supplement_eligible_person: False + +- name: Not in foster care + period: 2024 + input: + in_la: true + is_in_foster_care: False + is_mother: true + output: + ca_la_infant_supplement_eligible_person: False diff --git a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py index 4c00d256b45..48d14eef1cd 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py @@ -4,14 +4,10 @@ class ca_la_expectant_parent_payment(Variable): value_type = float entity = Person - definition_period = YEAR + definition_period = MONTH label = "Los Angeles County expectant parent payment" defined_for = "ca_la_expectant_parent_payment_eligible" def formula(person, period, parameters): p = parameters(period).gov.local.ca.la.dss.expectant_parent_payment - months_pregnant = person("months_pregnant", period) - eligible_pregancy_months = max_(0, months_pregnant - 6) - return p.amount * min_( - eligible_pregancy_months, p.eligible_pregnancy_months - ) + return p.amount diff --git a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py index 36429b77722..44e7cb1488e 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py @@ -4,11 +4,15 @@ class ca_la_expectant_parent_payment_eligible(Variable): value_type = bool entity = Person - definition_period = YEAR + definition_period = MONTH label = "Eligible for the Los Angeles County expectant parent paymentt" defined_for = "in_la" def formula(person, period, parameters): foster_care = person("is_in_foster_care", period) - is_pregnant = person("is_pregnant", period) - return foster_care & is_pregnant + pregnancy_month = person("current_pregnancy_month", period) + p = parameters(period).gov.local.ca.la.dss.expectant_parent_payment + eligible_based_on_pregnancy_month = ( + p.pregnancy_month.min <= pregnancy_month <= p.pregnancy_month.max + ) + return foster_care & eligible_based_on_pregnancy_month diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py index b30385afa85..e19ddc22b14 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py @@ -3,15 +3,25 @@ class ca_la_infant_supplement(Variable): value_type = float - entity = Person - definition_period = YEAR + entity = Household + definition_period = MONTH label = "Los Angeles County infant supplement" - defined_for = "ca_la_infant_supplement_eligible" + defined_for = "in_la" - def formula(person, period, parameters): + def formula(household, period, parameters): p = parameters(period).gov.local.ca.la.dss.infant_supplement - is_in_group_home = person("is_in_foster_care_group_home", period) - return ( - where(is_in_group_home, p.amount.group_home, p.amount.base) - * MONTHS_IN_YEAR + person = household.members + is_in_group_home = household.any( + person("is_in_foster_care_group_home", period) ) + base_amount = where( + is_in_group_home, p.amount.group_home, p.amount.base + ) + eligible_infants = add( + household, period, ["ca_la_infant_supplement_eligible_infant"] + ) + eligble_person = person( + "ca_la_infant_supplement_eligible_person", period + ) + eligble = household.any(eligble_person) + return base_amount * eligible_infants * eligble diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py new file mode 100644 index 00000000000..ddc46324e77 --- /dev/null +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py @@ -0,0 +1,15 @@ +from policyengine_us.model_api import * + + +class ca_la_infant_supplement_eligible_infant(Variable): + value_type = bool + entity = Person + definition_period = YEAR + label = "Eligible Infant for the Los Angeles County infant supplement" + defined_for = "in_la" + + def formula(person, period, parameters): + p = parameters(period).gov.local.ca + age = person("age", period) + p = parameters(period).gov.states.ca.infant + return age <= p.age_limit diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py similarity index 70% rename from policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py rename to policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py index 92125dd0457..a1d9d1f6e5f 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py @@ -1,14 +1,14 @@ from policyengine_us.model_api import * -class ca_la_infant_supplement_eligible(Variable): +class ca_la_infant_supplement_eligible_person(Variable): value_type = bool entity = Person - definition_period = YEAR + definition_period = MONTH label = "Eligible for the Los Angeles County infant supplement" defined_for = "in_la" def formula(person, period, parameters): foster_care = person("is_in_foster_care", period) - is_parent = person("is_parent", period) + is_parent = person("is_mother", period) return foster_care & is_parent diff --git a/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py b/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py new file mode 100644 index 00000000000..b3d40104fd3 --- /dev/null +++ b/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py @@ -0,0 +1,9 @@ +from policyengine_us.model_api import * + + +class current_pregnancy_month(Variable): + value_type = int + entity = Person + label = "Current pregnancy month" + definition_period = MONTH + defined_for = "is_pregnant" diff --git a/policyengine_us/variables/household/demographic/person/is_in_foster_care.py b/policyengine_us/variables/household/demographic/person/is_in_foster_care.py index ac21bfd0eaa..2e4c2efac11 100644 --- a/policyengine_us/variables/household/demographic/person/is_in_foster_care.py +++ b/policyengine_us/variables/household/demographic/person/is_in_foster_care.py @@ -5,4 +5,4 @@ class is_in_foster_care(Variable): value_type = bool entity = Person label = "Person is currently in a qualifying foster care institution" - definition_period = YEAR + definition_period = MONTH diff --git a/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py b/policyengine_us/variables/household/demographic/person/is_in_foster_care_group_home.py similarity index 89% rename from policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py rename to policyengine_us/variables/household/demographic/person/is_in_foster_care_group_home.py index cdc34eebff0..d1391be5ee2 100644 --- a/policyengine_us/variables/household/demographic/person/in_foster_care_group_home.py +++ b/policyengine_us/variables/household/demographic/person/is_in_foster_care_group_home.py @@ -5,6 +5,6 @@ class is_in_foster_care_group_home(Variable): value_type = bool entity = Person label = "Person is currently in a qualifying foster care group home" - definition_period = YEAR + definition_period = MONTH default_value = False defined_for = "is_in_foster_care" diff --git a/policyengine_us/variables/household/demographic/person/months_pregnant.py b/policyengine_us/variables/household/demographic/person/months_pregnant.py deleted file mode 100644 index f02bf81982c..00000000000 --- a/policyengine_us/variables/household/demographic/person/months_pregnant.py +++ /dev/null @@ -1,8 +0,0 @@ -from policyengine_us.model_api import * - - -class months_pregnant(Variable): - value_type = int - entity = Person - label = "Number of pregnancy months completed" - definition_period = YEAR From df9eff51082f17294b9d6be477b43f1488e3baa7 Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Mon, 11 Nov 2024 18:02:49 -0500 Subject: [PATCH 14/35] format --- .../gov/local/ca/la/dss/expectant_parent_payment/amount.yaml | 2 +- .../local/ca/la/dss/infant_supplement/amount/group_home.yaml | 2 +- .../ca_la_expectant_parent_payment_eligible.py | 2 +- .../ca/la/dss/infant_supplement/ca_la_infant_supplement.py | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml index 0b0089035e3..4333bf569fc 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml @@ -1,4 +1,4 @@ -description: The California Department of Social Services provides the following Expectant Parent Payment amount, based on preganncy months. +description: The California Department of Social Services provides the following Expectant Parent Payment amount, based on pregnancy months. values: 2022-01-01: 900 metadata: diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml index f4d872a2b29..dc46b3fa1ee 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/infant_supplement/amount/group_home.yaml @@ -4,7 +4,7 @@ values: metadata: unit: currency-USD period: month - label: California Department of Social Services Infant Supplement group homeamount + label: California Department of Social Services Infant Supplement group home amount reference: - title: Los Angeles County Department of Children and Family Services Teen Parenting href: https://dcfs.lacounty.gov/youth/teen-parenting/ diff --git a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py index 44e7cb1488e..a36565ca6c3 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment_eligible.py @@ -5,7 +5,7 @@ class ca_la_expectant_parent_payment_eligible(Variable): value_type = bool entity = Person definition_period = MONTH - label = "Eligible for the Los Angeles County expectant parent paymentt" + label = "Eligible for the Los Angeles County expectant parent payment" defined_for = "in_la" def formula(person, period, parameters): diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py index e19ddc22b14..78cd85e3acf 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py @@ -20,8 +20,8 @@ def formula(household, period, parameters): eligible_infants = add( household, period, ["ca_la_infant_supplement_eligible_infant"] ) - eligble_person = person( + eligible_person = person( "ca_la_infant_supplement_eligible_person", period ) - eligble = household.any(eligble_person) + eligble = household.any(eligible_person) return base_amount * eligible_infants * eligble From 84f41d21e65a25df1c95b0e110353972f5137e32 Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Tue, 12 Nov 2024 10:11:17 -0500 Subject: [PATCH 15/35] format --- .../gov/household/household_state_benefits.yaml | 2 ++ .../local/ca/la/dss/expectant_parent_payment/amount.yaml | 2 +- .../parameters/gov/states/ca/infant/age_limit.yaml | 3 +-- .../la/dss/infant_supplement/ca_la_infant_supplement.yaml | 8 ++++---- .../policy/baseline/gov/usda/wic/is_wic_eligible.yaml | 4 ++-- .../ca_la_expectant_parent_payment.py | 4 +--- .../la/dss/infant_supplement/ca_la_infant_supplement.py | 4 ++-- 7 files changed, 13 insertions(+), 14 deletions(-) diff --git a/policyengine_us/parameters/gov/household/household_state_benefits.yaml b/policyengine_us/parameters/gov/household/household_state_benefits.yaml index 9b83d873289..316987a4e82 100644 --- a/policyengine_us/parameters/gov/household/household_state_benefits.yaml +++ b/policyengine_us/parameters/gov/household/household_state_benefits.yaml @@ -12,6 +12,8 @@ values: - ca_care - ca_fera - ca_la_ez_save + - ca_la_infant_supplement + - ca_la_expectant_parent_payment # Nebraska benefits - ne_child_care_subsidies diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml index 4333bf569fc..e01723bb8e2 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/amount.yaml @@ -1,4 +1,4 @@ -description: The California Department of Social Services provides the following Expectant Parent Payment amount, based on pregnancy months. +description: The California Department of Social Services provides the following Expectant Parent Payment. values: 2022-01-01: 900 metadata: diff --git a/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml b/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml index a22585af290..db54e36d417 100644 --- a/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml +++ b/policyengine_us/parameters/gov/states/ca/infant/age_limit.yaml @@ -1,4 +1,4 @@ -description: California defines infants as children below this age threshold. +description: California defines infants as children at or below this age threshold. values: 2020-01-01: 1 metadata: @@ -8,4 +8,3 @@ metadata: reference: - title: California Code, Health and Safety Code - HSC § 124116, (f) href: https://codes.findlaw.com/ca/health-and-safety-code/hsc-sect-124116/ - diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml index f218e3e8f41..c98bc159a2d 100644 --- a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.yaml @@ -1,4 +1,4 @@ -- name: Eligble household with one infant, not in group home +- name: Eligible household with one infant, not in group home period: 2024 input: people: @@ -14,7 +14,7 @@ output: ca_la_infant_supplement: 10_800 -- name: Eligble household with one infant, in group home +- name: Eligible household with one infant, in group home period: 2024 input: people: @@ -31,7 +31,7 @@ ca_la_infant_supplement: 16_548 -- name: Eligble household with no infant, in group home +- name: Eligible household with no infant, in group home period: 2024 input: people: @@ -47,7 +47,7 @@ output: ca_la_infant_supplement: 0 -- name: Ineligble household with no infant, in group home +- name: Ineligible household with no infant, in group home period: 2024 input: people: diff --git a/policyengine_us/tests/policy/baseline/gov/usda/wic/is_wic_eligible.yaml b/policyengine_us/tests/policy/baseline/gov/usda/wic/is_wic_eligible.yaml index f785332ddd0..7b4855dbd5c 100644 --- a/policyengine_us/tests/policy/baseline/gov/usda/wic/is_wic_eligible.yaml +++ b/policyengine_us/tests/policy/baseline/gov/usda/wic/is_wic_eligible.yaml @@ -20,7 +20,7 @@ output: is_wic_eligible: false -- name: Case 3, eligble when either income test or categorical passed +- name: Case 3, eligible when either income test or categorical passed period: 2022 input: meets_wic_income_test: true @@ -29,7 +29,7 @@ output: is_wic_eligible: true -- name: Case 4, eligble when either income test or categorical passed +- name: Case 4, eligible when either income test or categorical passed period: 2022 input: meets_wic_income_test: false diff --git a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py index 48d14eef1cd..cdb805144ca 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/expectant_parent_payment/ca_la_expectant_parent_payment.py @@ -8,6 +8,4 @@ class ca_la_expectant_parent_payment(Variable): label = "Los Angeles County expectant parent payment" defined_for = "ca_la_expectant_parent_payment_eligible" - def formula(person, period, parameters): - p = parameters(period).gov.local.ca.la.dss.expectant_parent_payment - return p.amount + adds = ["gov.local.ca.la.dss.expectant_parent_payment.amount"] diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py index 78cd85e3acf..e931129c5a4 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement.py @@ -23,5 +23,5 @@ def formula(household, period, parameters): eligible_person = person( "ca_la_infant_supplement_eligible_person", period ) - eligble = household.any(eligible_person) - return base_amount * eligible_infants * eligble + eligible = household.any(eligible_person) + return base_amount * eligible_infants * eligible From 08cd2bb9c32d613d0d0741ba654921ba31e6b21f Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Tue, 12 Nov 2024 10:21:07 -0500 Subject: [PATCH 16/35] reference --- .../ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml | 2 ++ .../ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml | 2 ++ 2 files changed, 4 insertions(+) diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml index 235efb48c21..50759b7347d 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/max.yaml @@ -8,3 +8,5 @@ metadata: reference: - title: California Department of Social Services ALL COUNTY LETTER NO. 21-123 href: https://cdss.ca.gov/Portals/9/Additional-Resources/Letters-and-Notices/ACLs/2021/21-123.pdf?ver=2021-10-08-140950-570 + - title: California Welfare and Institutions Code, Division 9, Part 3, Chapter 2, Article 6, Section 11465 (e)(3) + href: https://leginfo.legislature.ca.gov/faces/codes_displaySection.xhtml?lawCode=WIC§ionNum=11465 diff --git a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml index 5f7a7cb3eb5..b207ebc55e1 100644 --- a/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml +++ b/policyengine_us/parameters/gov/local/ca/la/dss/expectant_parent_payment/pregnancy_month/min.yaml @@ -8,3 +8,5 @@ metadata: reference: - title: California Department of Social Services ALL COUNTY LETTER NO. 21-123 href: https://cdss.ca.gov/Portals/9/Additional-Resources/Letters-and-Notices/ACLs/2021/21-123.pdf?ver=2021-10-08-140950-570 + - title: California Welfare and Institutions Code, Division 9, Part 3, Chapter 2, Article 6, Section 11465 (e)(3) + href: https://leginfo.legislature.ca.gov/faces/codes_displaySection.xhtml?lawCode=WIC§ionNum=11465 From c29c2bbbd33ed81484501d43f25cddd577715213 Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Tue, 12 Nov 2024 15:44:43 -0500 Subject: [PATCH 17/35] minor change and default value --- .../ca_la_infant_supplement_eligible_person.yaml | 8 ++++---- .../ca_la_infant_supplement_eligible_person.py | 2 +- .../demographic/person/current_pregnancy_month.py | 1 + 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml index 8b146a73ab6..f148e12b50a 100644 --- a/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml +++ b/policyengine_us/tests/policy/baseline/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.yaml @@ -3,7 +3,7 @@ input: in_la: true is_in_foster_care: true - is_mother: true + is_pregnant: true output: ca_la_infant_supplement_eligible_person: true @@ -12,7 +12,7 @@ input: in_la: true is_in_foster_care: true - is_mother: False + is_pregnant: False output: ca_la_infant_supplement_eligible_person: False @@ -21,7 +21,7 @@ input: in_la: False is_in_foster_care: true - is_mother: true + is_pregnant: true output: ca_la_infant_supplement_eligible_person: False @@ -30,6 +30,6 @@ input: in_la: true is_in_foster_care: False - is_mother: true + is_pregnant: true output: ca_la_infant_supplement_eligible_person: False diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py index a1d9d1f6e5f..1fc283e772e 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_person.py @@ -10,5 +10,5 @@ class ca_la_infant_supplement_eligible_person(Variable): def formula(person, period, parameters): foster_care = person("is_in_foster_care", period) - is_parent = person("is_mother", period) + is_parent = person("is_pregnant", period) return foster_care & is_parent diff --git a/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py b/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py index b3d40104fd3..ef1a0445067 100644 --- a/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py +++ b/policyengine_us/variables/household/demographic/person/current_pregnancy_month.py @@ -7,3 +7,4 @@ class current_pregnancy_month(Variable): label = "Current pregnancy month" definition_period = MONTH defined_for = "is_pregnant" + default_value = 9 From 4b1668ffdf20062d967ccbbee9cdab4c2ac02fed Mon Sep 17 00:00:00 2001 From: Max Ghenis Date: Tue, 12 Nov 2024 22:22:54 -0500 Subject: [PATCH 18/35] Update policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py --- .../infant_supplement/ca_la_infant_supplement_eligible_infant.py | 1 - 1 file changed, 1 deletion(-) diff --git a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py index ddc46324e77..1e96706b201 100644 --- a/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py +++ b/policyengine_us/variables/gov/local/ca/la/dss/infant_supplement/ca_la_infant_supplement_eligible_infant.py @@ -9,7 +9,6 @@ class ca_la_infant_supplement_eligible_infant(Variable): defined_for = "in_la" def formula(person, period, parameters): - p = parameters(period).gov.local.ca age = person("age", period) p = parameters(period).gov.states.ca.infant return age <= p.age_limit From 03efe523b5dd7f706075826624ef76137c624ec3 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Wed, 13 Nov 2024 16:49:52 +0000 Subject: [PATCH 19/35] Update PolicyEngine US --- CHANGELOG.md | 8 ++++++++ changelog.yaml | 6 ++++++ changelog_entry.yaml | 5 ----- setup.py | 2 +- 4 files changed, 15 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 54957542d85..f54c4714eab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,13 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.141.0] - 2024-11-13 16:46:23 + +### Added + +- Los Angeles County expectant parent payment. +- Los Angeles County infant supplement. + ## [1.140.1] - 2024-11-11 04:47:50 ### Fixed @@ -10178,6 +10185,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.141.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.1...1.141.0 [1.140.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.0...1.140.1 [1.140.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.2...1.140.0 [1.139.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.1...1.139.2 diff --git a/changelog.yaml b/changelog.yaml index 1aa0765c393..58ae6c7a6e8 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8628,3 +8628,9 @@ fixed: - Iowa Income Tax Rates 2023-2026. date: 2024-11-11 04:47:50 +- bump: minor + changes: + added: + - Los Angeles County expectant parent payment. + - Los Angeles County infant supplement. + date: 2024-11-13 16:46:23 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index a627775f9a5..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,5 +0,0 @@ -- bump: minor - changes: - added: - - Los Angeles County expectant parent payment. - - Los Angeles County infant supplement. diff --git a/setup.py b/setup.py index c9e16cb1219..199d821eec2 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.140.1", + version="1.141.0", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From a9e9b05e74adfa2fb42c23f9c7b87729aa278d50 Mon Sep 17 00:00:00 2001 From: Vedant Rathi <72925608+vrathi101@users.noreply.github.com> Date: Thu, 14 Nov 2024 17:44:35 +0000 Subject: [PATCH 20/35] Georgia Income Tax Rate 2024 (#5308) * Georgia Income Tax Rate 2024 * fixing label * updating rate based on updated law * 2028 date * format --------- Co-authored-by: PavelMakarchuk --- changelog_entry.yaml | 4 ++ .../ga/tax/income/main/head_of_household.yaml | 70 +++++++++--------- .../gov/states/ga/tax/income/main/joint.yaml | 68 +++++++++--------- .../states/ga/tax/income/main/separate.yaml | 70 +++++++++--------- .../gov/states/ga/tax/income/main/single.yaml | 68 +++++++++--------- .../ga/tax/income/main/surviving_spouse.yaml | 72 +++++++++---------- 6 files changed, 168 insertions(+), 184 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..2e5aa2eefb4 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + added: + - Georgia 2024 income tax rate update. diff --git a/policyengine_us/parameters/gov/states/ga/tax/income/main/head_of_household.yaml b/policyengine_us/parameters/gov/states/ga/tax/income/main/head_of_household.yaml index 4d5b1aa529b..644d79a8e26 100644 --- a/policyengine_us/parameters/gov/states/ga/tax/income/main/head_of_household.yaml +++ b/policyengine_us/parameters/gov/states/ga/tax/income/main/head_of_household.yaml @@ -4,72 +4,68 @@ metadata: type: marginal_rate threshold_unit: currency-USD rate_unit: /1 - label: Georgia income tax rate joint filers + label: Georgia income tax rate head of household filers reference: - title: Depertment of Revenue - Tax Tables & Georgia Tax Rate Schedule href: https://dor.georgia.gov/tax-tables-georgia-tax-rate-schedule # Georgia transitioned to a flat tax rate, starting in 2024 - title: Official Code of Georgia Annotated | CH17 Income Taxes | O.C.G.A. § 48-7-20 (2)(C) href: https://law.justia.com/codes/georgia/2022/title-48/chapter-7/article-2/section-48-7-20-d-1/ + - title: House Bill 1015 (AS PASSED HOUSE AND SENATE), SECTION 1. (a.1)(1) + href: https://www.legis.ga.gov/legislation/66260 brackets: - threshold: 2022-01-01: 0 rate: 2022-01-01: 0.01 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 1_000 rate: 2022-01-01: 0.02 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 3_000 rate: 2022-01-01: 0.03 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 5_000 rate: 2022-01-01: 0.04 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 7_000 rate: 2022-01-01: 0.05 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 10_000 rate: 2022-01-01: 0.0575 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 diff --git a/policyengine_us/parameters/gov/states/ga/tax/income/main/joint.yaml b/policyengine_us/parameters/gov/states/ga/tax/income/main/joint.yaml index f46e2a24783..518a9e35991 100644 --- a/policyengine_us/parameters/gov/states/ga/tax/income/main/joint.yaml +++ b/policyengine_us/parameters/gov/states/ga/tax/income/main/joint.yaml @@ -11,65 +11,61 @@ metadata: # Georgia transitioned to a flat tax rate, starting in 2024 - title: Official Code of Georgia Annotated | CH17 Income Taxes | O.C.G.A. § 48-7-20 (2)(C) href: https://law.justia.com/codes/georgia/2022/title-48/chapter-7/article-2/section-48-7-20-d-1/ + - title: House Bill 1015 (AS PASSED HOUSE AND SENATE), SECTION 1. (a.1)(1) + href: https://www.legis.ga.gov/legislation/66260 brackets: - threshold: 2022-01-01: 0 rate: 2022-01-01: 0.01 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 1_000 rate: 2022-01-01: 0.02 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 3_000 rate: 2022-01-01: 0.03 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 5_000 rate: 2022-01-01: 0.04 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 7_000 rate: 2022-01-01: 0.05 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 10_000 rate: 2022-01-01: 0.0575 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 diff --git a/policyengine_us/parameters/gov/states/ga/tax/income/main/separate.yaml b/policyengine_us/parameters/gov/states/ga/tax/income/main/separate.yaml index 1c3240f6433..3a723879843 100644 --- a/policyengine_us/parameters/gov/states/ga/tax/income/main/separate.yaml +++ b/policyengine_us/parameters/gov/states/ga/tax/income/main/separate.yaml @@ -1,4 +1,4 @@ -description: Georgia taxes the personal income of married couples filing separate at this rate. +description: Georgia taxes the personal income of married couples filing separately at this rate. metadata: type: marginal_rate threshold_unit: currency-USD @@ -10,64 +10,60 @@ metadata: # Georgia transitioned to a flat tax rate, starting in 2024 - title: Official Code of Georgia Annotated | CH17 Income Taxes | O.C.G.A. § 48-7-20 (2)(C) href: https://law.justia.com/codes/georgia/2022/title-48/chapter-7/article-2/section-48-7-20-d-1/ + - title: House Bill 1015 (AS PASSED HOUSE AND SENATE), SECTION 1. (a.1)(1) + href: https://www.legis.ga.gov/legislation/66260 brackets: - threshold: 2022-01-01: 0 rate: 2022-01-01: 0.01 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 500 rate: 2022-01-01: 0.02 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 1_500 rate: 2022-01-01: 0.03 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 2_500 rate: 2022-01-01: 0.04 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 3_500 rate: 2022-01-01: 0.05 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 5_000 rate: 2022-01-01: 0.0575 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 diff --git a/policyengine_us/parameters/gov/states/ga/tax/income/main/single.yaml b/policyengine_us/parameters/gov/states/ga/tax/income/main/single.yaml index 4ce5a33ab51..a4caa39e435 100644 --- a/policyengine_us/parameters/gov/states/ga/tax/income/main/single.yaml +++ b/policyengine_us/parameters/gov/states/ga/tax/income/main/single.yaml @@ -10,65 +10,61 @@ metadata: # Georgia transitioned to a flat tax rate, starting in 2024 - title: Official Code of Georgia Annotated | CH17 Income Taxes | O.C.G.A. § 48-7-20 (2)(C) href: https://law.justia.com/codes/georgia/2022/title-48/chapter-7/article-2/section-48-7-20-d-1/ + - title: House Bill 1015 (AS PASSED HOUSE AND SENATE), SECTION 1. (a.1)(1) + href: https://www.legis.ga.gov/legislation/66260 brackets: - threshold: 2022-01-01: 0 rate: 2022-01-01: 0.01 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 750 rate: 2022-01-01: 0.02 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 2_250 rate: 2022-01-01: 0.03 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 3_750 rate: 2022-01-01: 0.04 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 5_250 rate: 2022-01-01: 0.05 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 7_000 rate: 2022-01-01: 0.0575 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 diff --git a/policyengine_us/parameters/gov/states/ga/tax/income/main/surviving_spouse.yaml b/policyengine_us/parameters/gov/states/ga/tax/income/main/surviving_spouse.yaml index b1e6b0ca73a..555d0f1c366 100644 --- a/policyengine_us/parameters/gov/states/ga/tax/income/main/surviving_spouse.yaml +++ b/policyengine_us/parameters/gov/states/ga/tax/income/main/surviving_spouse.yaml @@ -1,75 +1,71 @@ -description: Georgia taxes the personal income of widow filers at this rate. +description: Georgia taxes the personal income of surviving spouses at this rate. metadata: type: marginal_rate threshold_unit: currency-USD rate_unit: /1 - label: Georgia income tax rate joint filers + label: Georgia income tax rate surviving spouse filers reference: - title: Department of Revenue - Tax Tables & Georgia Tax Rate Schedule href: https://dor.georgia.gov/tax-tables-georgia-tax-rate-schedule # Georgia transitioned to a flat tax rate, starting in 2024 - title: Official Code of Georgia Annotated | CH17 Income Taxes | O.C.G.A. § 48-7-20 (2)(C) href: https://law.justia.com/codes/georgia/2022/title-48/chapter-7/article-2/section-48-7-20-d-1/ + - title: House Bill 1015 (AS PASSED HOUSE AND SENATE), SECTION 1. (a.1)(1) + href: https://www.legis.ga.gov/legislation/66260 brackets: - threshold: 2022-01-01: 0 rate: 2022-01-01: 0.01 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 1_000 rate: 2022-01-01: 0.02 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 3_000 rate: 2022-01-01: 0.03 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 5_000 rate: 2022-01-01: 0.04 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 7_000 rate: 2022-01-01: 0.05 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 - threshold: 2022-01-01: 10_000 rate: 2022-01-01: 0.0575 - 2024-01-01: 0.0549 - 2025-01-01: 0.0539 - 2026-01-01: 0.0529 - 2027-01-01: 0.0519 - 2028-01-01: 0.0509 - 2029-01-01: 0.0499 + 2024-01-01: 0.0539 + 2025-01-01: 0.0529 + 2026-01-01: 0.0519 + 2027-01-01: 0.0509 + 2028-01-01: 0.0499 From d05160da016a5c2e4267c776b467eadee46451f3 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Thu, 14 Nov 2024 17:48:26 +0000 Subject: [PATCH 21/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f54c4714eab..e7ecb01e023 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.142.0] - 2024-11-14 17:44:55 + +### Added + +- Georgia 2024 income tax rate update. + ## [1.141.0] - 2024-11-13 16:46:23 ### Added @@ -10185,6 +10191,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.142.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.141.0...1.142.0 [1.141.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.1...1.141.0 [1.140.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.0...1.140.1 [1.140.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.139.2...1.140.0 diff --git a/changelog.yaml b/changelog.yaml index 58ae6c7a6e8..b6284e9f2c7 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8634,3 +8634,8 @@ - Los Angeles County expectant parent payment. - Los Angeles County infant supplement. date: 2024-11-13 16:46:23 +- bump: minor + changes: + added: + - Georgia 2024 income tax rate update. + date: 2024-11-14 17:44:55 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 2e5aa2eefb4..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: minor - changes: - added: - - Georgia 2024 income tax rate update. diff --git a/setup.py b/setup.py index 199d821eec2..f8d1d0262c4 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.141.0", + version="1.142.0", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 6cd1f5b0c922ab6d6ac0833f0b988dfc57ef0adc Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Thu, 14 Nov 2024 15:11:35 -0500 Subject: [PATCH 22/35] Missing Mississippi 2023 income tax bracket threshold (#5325) Fixes #5324 --- changelog_entry.yaml | 4 ++++ .../gov/states/ms/tax/income/rate.yaml | 2 +- .../ms_income_tax_before_credits_indiv.yaml | 17 +++++++++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..af2551ab658 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + fixed: + - Mississippi missing 2023 income tax bracket thresholds. diff --git a/policyengine_us/parameters/gov/states/ms/tax/income/rate.yaml b/policyengine_us/parameters/gov/states/ms/tax/income/rate.yaml index 6c67a55ea44..1adecc913c3 100644 --- a/policyengine_us/parameters/gov/states/ms/tax/income/rate.yaml +++ b/policyengine_us/parameters/gov/states/ms/tax/income/rate.yaml @@ -26,7 +26,7 @@ brackets: 2017-01-01: 10_000 2018-01-01: 5_000 2022-01-01: 10_000 - 2024-01-01: .inf + 2023-01-01: .inf rate: 2017-01-01: 0.05 2018-01-01: 0.04 diff --git a/policyengine_us/tests/policy/baseline/gov/states/ms/tax/income/ms_income_tax_before_credits_indiv.yaml b/policyengine_us/tests/policy/baseline/gov/states/ms/tax/income/ms_income_tax_before_credits_indiv.yaml index 2e8fd7aa14f..6ca2261149e 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/ms/tax/income/ms_income_tax_before_credits_indiv.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/ms/tax/income/ms_income_tax_before_credits_indiv.yaml @@ -69,3 +69,20 @@ ms_taxable_income_indiv: 4_000 output: ms_income_tax_before_credits_indiv: 0 + + +- name: High earner in 2023 + period: 2023 + input: + state_code: MS + ms_taxable_income_indiv: 1_000_000 + output: + ms_income_tax_before_credits_indiv: 49_500 + +- name: Income over top threshold in 2023 + period: 2023 + input: + state_code: MS + ms_taxable_income_indiv: 12_000 + output: + ms_income_tax_before_credits_indiv: 100 From 6863f33809028aabdca40dd06afcfc5eda758ac6 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Thu, 14 Nov 2024 20:15:41 +0000 Subject: [PATCH 23/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e7ecb01e023..8e50c7e0399 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.142.1] - 2024-11-14 20:12:06 + +### Fixed + +- Mississippi missing 2023 income tax bracket thresholds. + ## [1.142.0] - 2024-11-14 17:44:55 ### Added @@ -10191,6 +10197,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.142.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.0...1.142.1 [1.142.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.141.0...1.142.0 [1.141.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.1...1.141.0 [1.140.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.0...1.140.1 diff --git a/changelog.yaml b/changelog.yaml index b6284e9f2c7..d1bd0258d7e 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8639,3 +8639,8 @@ added: - Georgia 2024 income tax rate update. date: 2024-11-14 17:44:55 +- bump: patch + changes: + fixed: + - Mississippi missing 2023 income tax bracket thresholds. + date: 2024-11-14 20:12:06 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index af2551ab658..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - fixed: - - Mississippi missing 2023 income tax bracket thresholds. diff --git a/setup.py b/setup.py index f8d1d0262c4..d1b24b3e17c 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.142.0", + version="1.142.1", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 6a65ee7c34fc8adfac3a81dba28d6786dc95d9cb Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Fri, 15 Nov 2024 14:20:58 -0500 Subject: [PATCH 24/35] Fix the New York working families tax credit logic to properly account for filers with both older and younger dependents (#5202) * Refactoring EITC to consider childless filers and exclude children under 17 from households with older children after 2029 * full refactor and change tests * more tests * format --- changelog_entry.yaml | 4 + .../contrib/states/ny/wftc/amount/max.yaml | 11 +- .../contrib/states/ny/wftc/amount/min.yaml | 2 +- .../states/ny/wftc/child_age_threshold.yaml | 4 +- .../contrib/states/ny/wftc/eitc/match.yaml | 11 +- .../wftc/exemptions/child_age_threshold.yaml | 2 +- .../states/ny/wftc/reduction/married.yaml | 13 +- .../states/ny/wftc/reduction/single.yaml | 17 +- .../ny/wftc/ny_working_families_tax_credit.py | 56 +- .../ny/ny_working_families_tax_credit.yaml | 515 +++--------------- 10 files changed, 146 insertions(+), 489 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..15fdb885fc3 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + fixed: + - Refactor the New York Working Families Tax Credit. diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/max.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/max.yaml index 8eb9c124760..f044a184366 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/max.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/max.yaml @@ -13,9 +13,8 @@ metadata: href: https://legislation.nysenate.gov/pdf/bills/2023/S277C values: - 2024-01-01: 0 -# 2024: 550 -# 2025: 800 -# 2026: 1,000 -# 2027: 1,200 -# 2028: 1,600 + 2025-01-01: 550 + 2026-01-01: 800 + 2027-01-01: 1_000 + 2028-01-01: 1_200 + 2029-01-01: 1_600 diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/min.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/min.yaml index 22ae429968c..1ef9b509d25 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/min.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/amount/min.yaml @@ -13,4 +13,4 @@ metadata: href: https://legislation.nysenate.gov/pdf/bills/2023/S277C values: - 2024-01-01: 0 # 100 + 2024-01-01: 100 diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/child_age_threshold.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/child_age_threshold.yaml index 21b92f00836..857b293d6ec 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/child_age_threshold.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/child_age_threshold.yaml @@ -8,10 +8,10 @@ metadata: href: https://legislation.nysenate.gov/pdf/bills/2023/S277C values: - 2024-01-01: 0 # 17 + 2025-01-01: 16 + 2028-01-01: 17 # The age threshold is applied to is applied to different provisions of the Working Families Tax Credit # at different time periods # The Working Families defines child dependents as defined in 26 USC §24(c)(1) with the exception # of the age threshold and student dependents - diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/eitc/match.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/eitc/match.yaml index 7659f5527a9..e470dbe8e16 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/eitc/match.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/eitc/match.yaml @@ -8,9 +8,8 @@ metadata: href: https://legislation.nysenate.gov/pdf/bills/2023/S277C values: - 2024-01-01: 0 -# 2025: 25% -# 2026: 20% -# 2027: 15% -# 2028: 10% -# 2029: 0 + 2025-01-01: 0.25 + 2026-01-01: 0.20 + 2027-01-01: 0.15 + 2028-01-01: 0.10 + 2029-01-01: 0 diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/exemptions/child_age_threshold.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/exemptions/child_age_threshold.yaml index 2653fae1d8f..175cb48f4c6 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/exemptions/child_age_threshold.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/exemptions/child_age_threshold.yaml @@ -8,4 +8,4 @@ metadata: href: https://legislation.nysenate.gov/pdf/bills/2023/S277C values: - 2024-01-01: 0 # 18 + 2025-01-01: 18 diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/married.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/married.yaml index 4ab337c08d1..fe90f13e2b4 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/married.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/married.yaml @@ -11,19 +11,18 @@ metadata: brackets: - threshold: - 2024-01-01: 0 + 2025-01-01: 0 rate: - 2024-01-01: 0 + 2025-01-01: 0 - threshold: values: - 2024-01-01: 0 - # 2025: 110,000 - # 2028: 90,000 - # 2029: 50,000 + 2025-01-01: 110_000 + 2028-01-01: 90_000 + 2029-01-01: 50_000 uprating: parameter: gov.irs.uprating rounding: type: downwards interval: 50 rate: - 2024-01-01: 0 # 0.02 + 2025-01-01: 0.02 diff --git a/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/single.yaml b/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/single.yaml index 1c53b63e0ec..6d46410db4e 100644 --- a/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/single.yaml +++ b/policyengine_us/parameters/gov/contrib/states/ny/wftc/reduction/single.yaml @@ -11,21 +11,20 @@ metadata: brackets: - threshold: - 2024-01-01: 0 + 2025-01-01: 0 rate: - 2024-01-01: 0 + 2025-01-01: 0 - threshold: values: - 2024-01-01: 0 - # 2025: 75,000 - # 2026: 65,000 - # 2027: 55,000 - # 2028: 45,000 - # 2029: 25,000 + 2025-01-01: 75_000 + 2026-01-01: 65_000 + 2027-01-01: 55_000 + 2028-01-01: 45_000 + 2029-01-01: 25_000 uprating: parameter: gov.irs.uprating rounding: type: downwards interval: 50 rate: - 2024-01-01: 0 # 0.02 + 2025-01-01: 0.02 diff --git a/policyengine_us/reforms/states/ny/wftc/ny_working_families_tax_credit.py b/policyengine_us/reforms/states/ny/wftc/ny_working_families_tax_credit.py index aa879a39906..c96190d4eeb 100644 --- a/policyengine_us/reforms/states/ny/wftc/ny_working_families_tax_credit.py +++ b/policyengine_us/reforms/states/ny/wftc/ny_working_families_tax_credit.py @@ -64,7 +64,7 @@ def formula(person, period, parameters): is_dependent = person("is_tax_unit_dependent", period) age = person("age", period) p = parameters(period).gov.contrib.states.ny.wftc - age_eligible = age < p.child_age_threshold + age_eligible = age <= p.child_age_threshold return is_dependent & age_eligible class eitc_younger_children_count(Variable): @@ -86,18 +86,12 @@ class eitc_younger_maximum(Variable): unit = USD def formula(tax_unit, period, parameters): - younger_child_count = tax_unit( - "eitc_younger_children_count", period - ) - older_child_count = tax_unit("eitc_older_children_count", period) - child_count = older_child_count + younger_child_count + child_count = tax_unit("eitc_younger_children_count", period) eitc = parameters(period).gov.irs.credits.eitc # We will reduce the maximum credit amount by the amount for self # as it is attributed to the younger children EITC # We also need to reduce it by the amount attributed to the younger children - base_credit = eitc.max.calc(child_count) - amount_for_older = eitc.max.calc(older_child_count) - return base_credit - amount_for_older + return eitc.max.calc(child_count) class eitc_younger_phase_in_rate(Variable): value_type = float @@ -200,8 +194,15 @@ def formula(tax_unit, period, parameters): demographic_eligible = tax_unit( "eitc_younger_demographic_eligible", period ) + no_older_children = ( + tax_unit("eitc_older_children_count", period) == 0 + ) # Define eligibility before considering separate filer limitation. - eligible = demographic_eligible & investment_income_eligible + eligible = ( + demographic_eligible + & investment_income_eligible + & no_older_children + ) # This parameter is true if separate filers are eligible. if eitc.eligibility.separate_filer: return eligible @@ -241,7 +242,7 @@ def formula(person, period, parameters): student = person("is_full_time_student", period) student_age_eligible = age < p_irs.student p_ref = parameters(period).gov.contrib.states.ny.wftc - older_student_age_eligible = p_ref.child_age_threshold <= age + older_student_age_eligible = p_ref.child_age_threshold < age age_eligible = student_age_eligible & older_student_age_eligible return is_dependent & student & age_eligible @@ -264,7 +265,11 @@ class eitc_older_maximum(Variable): unit = USD def formula(tax_unit, period, parameters): - child_count = tax_unit("eitc_older_children_count", period) + older_child_count = tax_unit("eitc_older_children_count", period) + younger_child_count = tax_unit( + "eitc_younger_children_count", period + ) + child_count = younger_child_count + older_child_count eitc = parameters(period).gov.irs.credits.eitc # We will reduce the maximum credit amount by the amount for self # as it is attributed to the younger children EITC @@ -280,7 +285,11 @@ class eitc_older_phase_in_rate(Variable): definition_period = YEAR def formula(tax_unit, period, parameters): - child_count = tax_unit("eitc_older_children_count", period) + older_child_count = tax_unit("eitc_older_children_count", period) + younger_child_count = tax_unit( + "eitc_younger_children_count", period + ) + child_count = younger_child_count + older_child_count eitc = parameters(period).gov.irs.credits.eitc return eitc.phase_in_rate.calc(child_count) @@ -308,7 +317,11 @@ class eitc_older_phase_out_start(Variable): definition_period = YEAR def formula(tax_unit, period, parameters): - count_children = tax_unit("eitc_older_children_count", period) + older_child_count = tax_unit("eitc_older_children_count", period) + younger_child_count = tax_unit( + "eitc_younger_children_count", period + ) + count_children = younger_child_count + older_child_count eitc = parameters(period).gov.irs.credits.eitc is_joint = tax_unit("tax_unit_is_joint", period) joint_bonus = eitc.phase_out.joint_bonus.calc(count_children) @@ -325,8 +338,12 @@ class eitc_older_phase_out_rate(Variable): def formula(tax_unit, period, parameters): eitc = parameters(period).gov.irs.credits.eitc - num_children = tax_unit("eitc_older_children_count", period) - return eitc.phase_out.rate.calc(num_children) + older_child_count = tax_unit("eitc_older_children_count", period) + younger_child_count = tax_unit( + "eitc_younger_children_count", period + ) + count_children = younger_child_count + older_child_count + return eitc.phase_out.rate.calc(count_children) class eitc_older_reduction(Variable): value_type = float @@ -388,8 +405,13 @@ def formula(tax_unit, period, parameters): demographic_eligible = tax_unit( "eitc_older_demographic_eligible", period ) + younger_eitc_eligible = tax_unit("younger_eitc_eligible", period) # Define eligibility before considering separate filer limitation. - eligible = demographic_eligible & investment_income_eligible + eligible = ( + demographic_eligible + & investment_income_eligible + & ~younger_eitc_eligible + ) # This parameter is true if separate filers are eligible. if eitc.eligibility.separate_filer: return eligible diff --git a/policyengine_us/tests/policy/contrib/states/ny/ny_working_families_tax_credit.yaml b/policyengine_us/tests/policy/contrib/states/ny/ny_working_families_tax_credit.yaml index 9814c04d7f9..d6e0e763f67 100644 --- a/policyengine_us/tests/policy/contrib/states/ny/ny_working_families_tax_credit.yaml +++ b/policyengine_us/tests/policy/contrib/states/ny/ny_working_families_tax_credit.yaml @@ -1,12 +1,13 @@ - name: Single person of 30 with 30k of employemnt income - no reform period: 2025 + absolute_error_margin: 1 input: gov.contrib.states.ny.wftc.in_effect: false people: person1: age: 30 is_tax_unit_dependent: false - employment_income: 30_000 + employment_income: 8_500 tax_units: tax_unit: members: [person1] @@ -17,29 +18,21 @@ output: # ny_wftc_eligible_children: 0 # ny_working_families_tax_credit: 0 - ny_eitc: 0 + ny_eitc: 150 ny_ctc: 0 ny_exemptions: 0 -- name: Single person of 30 with 30k of employemnt income - reform +- name: Single person should have no change in 2025 with the reform period: 2025 + absolute_error_margin: 1 reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit input: gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 people: person1: age: 30 is_tax_unit_dependent: false - employment_income: 30_000 + employment_income: 8_500 tax_units: tax_unit: members: [person1] @@ -50,58 +43,20 @@ output: ny_wftc_eligible_children: 0 ny_working_families_tax_credit: 0 - ny_eitc: 0 + ny_eitc: 150 ny_ctc: 0 ny_exemptions: 0 -- name: Single parent of one child with 30k income - no reform +- name: Single person, one child, with 20k of employemnt income - reform period: 2025 - absolute_error_margin: 1 - input: - gov.contrib.states.ny.wftc.in_effect: false - people: - person1: - age: 30 - is_tax_unit_dependent: false - employment_income: 30_000 - person2: - age: 10 - is_tax_unit_dependent: true - tax_units: - tax_unit: - members: [person1, person2] - households: - household: - members: [person1, person2] - state_code: NY - output: - # ny_wftc_eligible_children: 0 - # ny_working_families_tax_credit: 0 - ny_eitc: 954.59906 - ny_ctc: 330 - ny_exemptions: 1_000 - - -- name: Single parent of one child with 30k income - w/ reform - period: 2025 - absolute_error_margin: 1 reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit input: gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.25 - gov.contrib.states.ny.wftc.amount.max: 550 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 110_000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 75_000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 people: person1: age: 30 is_tax_unit_dependent: false - employment_income: 30_000 + employment_income: 20_000 person2: age: 10 is_tax_unit_dependent: true @@ -115,85 +70,17 @@ output: ny_wftc_eligible_children: 1 ny_working_families_tax_credit: 550 - ny_eitc: 629.0825 - ny_ctc: 0 - ny_exemptions: 1_000 - -- name: Reform applied to a head of household with no income in 2025 - period: 2025 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit - input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 - people: - person1: - age: 30 - is_tax_unit_dependent: false - person2: - age: 16 - is_tax_unit_dependent: true - tax_units: - tax_unit: - members: [person1, person2] - ny_agi: 0 - filing_status: HEAD_OF_HOUSEHOLD - households: - household: - members: [person1, person2] - state_code: NY - output: - ny_wftc_eligible_children: 1 - ny_working_families_tax_credit: 800 - ny_eitc: 0 - ny_ctc: 0 - ny_exemptions: 1_000 - -- name: Head of household with income over phase-out threshold in 2025 - period: 2025 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit - input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 - people: - person1: - age: 30 - is_tax_unit_dependent: false - person2: - age: 16 - is_tax_unit_dependent: true - tax_units: - tax_unit: - members: [person1, person2] - ny_agi: 140_000 - filing_status: HEAD_OF_HOUSEHOLD - households: - household: - members: [person1, person2] - state_code: NY - output: - ny_wftc_eligible_children: 1 - ny_working_families_tax_credit: 150 - ny_eitc: 0 + is_older_child_dependent: [false, false] + eitc: 4_328 + younger_eitc: 4_328 + younger_eitc_eligible: true + older_eitc_eligible: false + older_eitc: 0 + ny_eitc: 1_007 ny_ctc: 0 ny_exemptions: 1_000 -- name: Reform does not apply, household received EITC +- name: Single person, one child, with 20k of employemnt income - no reform period: 2025 input: gov.contrib.states.ny.wftc.in_effect: false @@ -201,431 +88,179 @@ person1: age: 30 is_tax_unit_dependent: false - employment_income: 1_000 + employment_income: 20_000 person2: - age: 16 + age: 10 is_tax_unit_dependent: true tax_units: tax_unit: members: [person1, person2] - ny_agi: 30_000 - filing_status: HEAD_OF_HOUSEHOLD - ny_household_credit: 0 households: household: members: [person1, person2] state_code: NY output: - # ny_wftc_eligible_children: 0 - # ny_working_families_tax_credit: 0 - eitc: 340 - ny_eitc: 102 + eitc: 4_328 + ny_eitc: 1_223.4 ny_ctc: 330 ny_exemptions: 1_000 -- name: Reform applied to a head of household with no income in 2025, dependent over 18 +- name: Single person, one older child, with 20k of employemnt income - reform period: 2025 reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit input: gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 people: person1: age: 30 is_tax_unit_dependent: false + employment_income: 20_000 person2: age: 18 is_tax_unit_dependent: true + is_full_time_student: true tax_units: tax_unit: members: [person1, person2] - ny_agi: 0 - filing_status: HEAD_OF_HOUSEHOLD households: household: members: [person1, person2] state_code: NY output: - is_younger_child_dependent: [false, false] ny_wftc_eligible_children: 0 ny_working_families_tax_credit: 0 - ny_eitc: 0 + is_older_child_dependent: [false, true] + eitc: 4_328 + ny_eitc: 1_223.4 ny_ctc: 0 ny_exemptions: 1_000 -- name: Younger EITC fully phased out but older EITC still applicable - period: 2028 - absolute_error_margin: 1 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit +- name: Single person, one older child, with 20k of employemnt income - no reform + period: 2025 input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 + gov.contrib.states.ny.wftc.in_effect: false people: person1: age: 30 is_tax_unit_dependent: false - employment_income: 10_000 + employment_income: 20_000 person2: - age: 20 + age: 18 is_tax_unit_dependent: true - is_full_time_student: true tax_units: tax_unit: members: [person1, person2] - ny_agi: 10_000 - filing_status: HEAD_OF_HOUSEHOLD - ny_household_credit: 0 households: household: members: [person1, person2] state_code: NY output: - ny_wftc_eligible_children: 1 - ny_working_families_tax_credit: 0 - eitc_younger_children_count: 0 - # Amount for self attributed to older child EITC - younger_eitc: 0 - eitc: 3_400 - older_eitc: 3_400 - ny_eitc: 1_020 + eitc: 4_328 + eitc_maximum: 4_328 + ny_eitc: 1_223.4 ny_ctc: 0 ny_exemptions: 1_000 - -- name: Baseline test - single parent with one child in college - period: 2028 - absolute_error_margin: 1 - input: - people: - person1: - age: 30 - is_tax_unit_dependent: false - employment_income: 10_000 - person2: - age: 20 - is_tax_unit_dependent: true - is_full_time_student: true - tax_units: - tax_unit: - members: [person1, person2] - ny_household_credit: 0 - households: - household: - members: [person1, person2] - state_code: NY - output: - eitc: 3_400 - ny_eitc: 1_020 - -- name: Baseline test - single parent of two - ages 5 and 10 - 30k income +- name: Single person, two children one older and one younger, with 20k of employemnt income - reform period: 2025 - absolute_error_margin: 1 - input: - gov.contrib.states.ny.wftc.in_effect: false - people: - person1: - age: 30 - is_tax_unit_dependent: false - employment_income: 30_000 - person2: - age: 10 - is_tax_unit_dependent: true - person3: - age: 5 - is_tax_unit_dependent: true - tax_units: - tax_unit: - members: [person1, person2, person3] - households: - household: - members: [person1, person2, person3] - state_code: NY - output: - eitc: 5_751.51 - ny_eitc: 1_695.453 # 30% of federal credit - - -- name: Integration test - single parent of two - ages 5 and 10 - 30k income - period: 2025 - absolute_error_margin: 1 reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit input: gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 people: person1: age: 30 - employment_income: 30_000 - person2: - age: 10 - is_tax_unit_dependent: true - person3: - age: 5 - is_tax_unit_dependent: true - tax_units: - tax_unit: - members: [person1, person2, person3] - households: - household: - members: [person1, person2, person3] - state_code: NY - output: - younger_eitc_eligible: 1 - younger_eitc: 5_102.51 - older_eitc: 0 - ny_wftc_eligible_children: 2 - ny_eitc: 1_041.527 - ny_working_families_tax_credit: 1_600 - - -- name: Integration test - single parent of two - ages 5 and 20 (student) - 30k income - period: 2025 - absolute_error_margin: 1 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit - input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 - people: - person1: - age: 30 - employment_income: 30_000 + is_tax_unit_dependent: false + employment_income: 20_000 person2: - age: 10 + age: 16 is_tax_unit_dependent: true person3: - age: 20 + age: 17 is_tax_unit_dependent: true is_full_time_student: true tax_units: tax_unit: members: [person1, person2, person3] - ny_household_credit: 0 households: household: members: [person1, person2, person3] state_code: NY output: - younger_eitc_eligible: 1 - younger_eitc: 2_824 - eitc_older_demographic_eligible: 1 - older_eitc: 4_328 ny_wftc_eligible_children: 1 - ny_eitc: 1_891.44 - ny_working_families_tax_credit: 800 + ny_working_families_tax_credit: 550 + eitc: 7_152 + younger_eitc: 0 + eitc_younger_children_count: 1 + eitc_older_children_count: 1 + eitc_older_maximum: 7_152 + older_eitc: 7_152 + ny_eitc: 2_055.6 + ny_ctc: 0 + ny_exemptions: 2_000 -- name: Base test - single parent of two - ages 5 and 20 (student) - 30k income +- name: Single person, two children one older and one younger, with 20k of employemnt income - no reform period: 2025 - absolute_error_margin: 1 input: gov.contrib.states.ny.wftc.in_effect: false people: person1: age: 30 - employment_income: 30_000 - person2: - age: 10 - is_tax_unit_dependent: true - person3: - age: 20 - is_tax_unit_dependent: true - is_full_time_student: true - tax_units: - tax_unit: - members: [person1, person2, person3] - ny_household_credit: 0 - households: - household: - members: [person1, person2, person3] - state_code: NY - output: - ny_eitc: 2_145.6 - -- name: After 2028, only children under 18 are eligible for the NY WFTC - period: 2029 - absolute_error_margin: 1 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit - input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 18 - people: - person1: - age: 30 - employment_income: 30_000 + is_tax_unit_dependent: false + employment_income: 20_000 person2: - age: 10 + age: 16 is_tax_unit_dependent: true person3: - age: 20 + age: 17 is_tax_unit_dependent: true is_full_time_student: true tax_units: tax_unit: members: [person1, person2, person3] - ny_household_credit: 0 households: household: members: [person1, person2, person3] state_code: NY output: - ny_working_families_tax_credit: 800 - -- name: Dependent exemptions apply to all exemptions in 2025 - period: 2025 - absolute_error_margin: 1 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit - input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 - people: - person1: - age: 30 - employment_income: 30_000 - person2: - age: 10 - is_tax_unit_dependent: true - person3: - age: 25 - is_tax_unit_dependent: true - person4: - age: 23 - is_tax_unit_dependent: true - is_full_time_student: true - tax_units: - tax_unit: - members: [person1, person2, person3, person4] - ny_household_credit: 0 - households: - household: - members: [person1, person2, person3, person4] - state_code: NY - output: - ny_exemptions: 3_000 - -- name: Dependent exemptions apply to only non child dependents in 2026 - period: 2026 - absolute_error_margin: 1 - reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit - input: - gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 17 - people: - person1: - age: 30 - employment_income: 30_000 - person2: - age: 10 - is_tax_unit_dependent: true - person3: - age: 23 - is_tax_unit_dependent: true - is_full_time_student: true - person4: - age: 18 - is_tax_unit_dependent: true - tax_units: - tax_unit: - members: [person1, person2, person3, person4] - ny_household_credit: 0 - households: - household: - members: [person1, person2, person3, person4] - state_code: NY - output: - ny_exemptions_dependent: [false, false, true, true] + eitc: 7_152 + eitc_maximum: 7_152 + ny_eitc: 2_055.6 + ny_ctc: 330 ny_exemptions: 2_000 -- name: Dependent exemptions apply to older child depedents in 2028 +- name: In 2028, Single person of, two children new age restriction applies - reform period: 2028 - absolute_error_margin: 1 reforms: policyengine_us.reforms.states.ny.wftc.ny_working_families_tax_credit.ny_working_families_tax_credit input: gov.contrib.states.ny.wftc.in_effect: true - gov.contrib.states.ny.wftc.eitc.match: 0.21 - gov.contrib.states.ny.wftc.amount.max: 800 - gov.contrib.states.ny.wftc.amount.min: 150 - gov.contrib.states.ny.wftc.exemptions.child_age_threshold: 18 - gov.contrib.states.ny.wftc.reduction.married[1].threshold: 130000 - gov.contrib.states.ny.wftc.reduction.married[1].rate: 0.02 - gov.contrib.states.ny.wftc.reduction.single[1].threshold: 65000 - gov.contrib.states.ny.wftc.reduction.single[1].rate: 0.02 - gov.contrib.states.ny.wftc.child_age_threshold: 18 people: person1: age: 30 - employment_income: 30_000 + is_tax_unit_dependent: false + employment_income: 20_000 person2: - age: 10 + age: 16 is_tax_unit_dependent: true person3: age: 17 is_tax_unit_dependent: true - person4: - age: 23 - is_tax_unit_dependent: true is_full_time_student: true tax_units: tax_unit: - members: [person1, person2, person3, person4] + members: [person1, person2, person3] ny_household_credit: 0 households: household: - members: [person1, person2, person3, person4] + members: [person1, person2, person3] state_code: NY output: - ny_exemptions: 1_000 + ny_wftc_eligible_children: 2 + ny_working_families_tax_credit: 2_400 + eitc: 7_588 + eitc_younger_children_count: 2 + eitc_older_children_count: 0 + younger_eitc: 7_588 + older_eitc: 0 + ny_eitc: 758.8 + ny_ctc: 0 + ny_exemptions: 0 From 5df8ea8b4f76bb79754f12a416bad04b5801b0a9 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Fri, 15 Nov 2024 19:24:48 +0000 Subject: [PATCH 25/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8e50c7e0399..3b8c477bb6f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.142.2] - 2024-11-15 19:21:17 + +### Fixed + +- Refactor the New York Working Families Tax Credit. + ## [1.142.1] - 2024-11-14 20:12:06 ### Fixed @@ -10197,6 +10203,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.142.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.1...1.142.2 [1.142.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.0...1.142.1 [1.142.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.141.0...1.142.0 [1.141.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.140.1...1.141.0 diff --git a/changelog.yaml b/changelog.yaml index d1bd0258d7e..b484991a278 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8644,3 +8644,8 @@ fixed: - Mississippi missing 2023 income tax bracket thresholds. date: 2024-11-14 20:12:06 +- bump: patch + changes: + fixed: + - Refactor the New York Working Families Tax Credit. + date: 2024-11-15 19:21:17 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 15fdb885fc3..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - fixed: - - Refactor the New York Working Families Tax Credit. diff --git a/setup.py b/setup.py index d1b24b3e17c..8e720039771 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.142.1", + version="1.142.2", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 2643e9f14186604dae3408528349ec14bcd6fc7c Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Sat, 16 Nov 2024 15:18:22 -0500 Subject: [PATCH 26/35] Add the 2023 Arkansas inflation relief credit amount and avoid attributing the amount twice for joint filers filing separately (#5332) Fixes #5331 --- changelog_entry.yaml | 4 ++++ .../tax/income/credits/inflationary_relief/max_amount.yaml | 6 +++++- .../income/credits/ar_inflation_relief_credit_person.yaml | 2 +- ...redit_person.py => ar_inflation_relief_credit_person.py} | 5 ++++- 4 files changed, 14 insertions(+), 3 deletions(-) rename policyengine_us/variables/gov/states/ar/tax/income/credits/{ar_inflationary_relief_tax_credit_person.py => ar_inflation_relief_credit_person.py} (84%) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..f340a28996a 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + added: + - Add the 2023 Arkansas inflation relief credit amount and avoid attributing the amount twice for joint filers filing separately. diff --git a/policyengine_us/parameters/gov/states/ar/tax/income/credits/inflationary_relief/max_amount.yaml b/policyengine_us/parameters/gov/states/ar/tax/income/credits/inflationary_relief/max_amount.yaml index b5dbd402bd5..bad915cdd80 100644 --- a/policyengine_us/parameters/gov/states/ar/tax/income/credits/inflationary_relief/max_amount.yaml +++ b/policyengine_us/parameters/gov/states/ar/tax/income/credits/inflationary_relief/max_amount.yaml @@ -17,12 +17,16 @@ metadata: - filing_status JOINT: 2022-01-01: 300 + 2023-01-01: 100 SURVIVING_SPOUSE: 2022-01-01: 150 + 2023-01-01: 50 HEAD_OF_HOUSEHOLD: 2022-01-01: 150 + 2023-01-01: 50 SINGLE: 2022-01-01: 150 + 2023-01-01: 50 SEPARATE: 2022-01-01: 150 - + 2023-01-01: 50 diff --git a/policyengine_us/tests/policy/baseline/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.yaml b/policyengine_us/tests/policy/baseline/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.yaml index fb3e90d5cb6..d3ee074e898 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.yaml @@ -103,7 +103,7 @@ members: [person1, person2] state_code: AR output: - ar_inflation_relief_credit_person: 280 + ar_inflation_relief_credit_person: [140, 140] - name: Widow household with $80,000 taxable income period: 2022 diff --git a/policyengine_us/variables/gov/states/ar/tax/income/credits/ar_inflationary_relief_tax_credit_person.py b/policyengine_us/variables/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.py similarity index 84% rename from policyengine_us/variables/gov/states/ar/tax/income/credits/ar_inflationary_relief_tax_credit_person.py rename to policyengine_us/variables/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.py index 312af55fc7e..9b5c9b622a0 100644 --- a/policyengine_us/variables/gov/states/ar/tax/income/credits/ar_inflationary_relief_tax_credit_person.py +++ b/policyengine_us/variables/gov/states/ar/tax/income/credits/ar_inflation_relief_credit_person.py @@ -30,4 +30,7 @@ def formula(person, period, parameters): excess = max_(income - reduction_start, 0) increments = np.ceil(excess / increment) total_reduction_amount = increments * reduction_per_increment - return max_(max_amount - total_reduction_amount, 0) + # Attribute the maximum amount to each spouse equally when married filing jointly + joint = filing_status == filing_status.possible_values.JOINT + divisor = where(joint, 2, 1) + return max_(max_amount - total_reduction_amount, 0) / divisor From bd100029bd3db9fc529e1ab65350b680677059bb Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Sat, 16 Nov 2024 20:22:11 +0000 Subject: [PATCH 27/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 6 ++++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3b8c477bb6f..bdebc4d35b0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.142.3] - 2024-11-16 20:18:42 + +### Added + +- Add the 2023 Arkansas inflation relief credit amount and avoid attributing the amount twice for joint filers filing separately. + ## [1.142.2] - 2024-11-15 19:21:17 ### Fixed @@ -10203,6 +10209,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.142.3]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.2...1.142.3 [1.142.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.1...1.142.2 [1.142.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.0...1.142.1 [1.142.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.141.0...1.142.0 diff --git a/changelog.yaml b/changelog.yaml index b484991a278..1b1fc5ca693 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8649,3 +8649,9 @@ fixed: - Refactor the New York Working Families Tax Credit. date: 2024-11-15 19:21:17 +- bump: patch + changes: + added: + - Add the 2023 Arkansas inflation relief credit amount and avoid attributing the + amount twice for joint filers filing separately. + date: 2024-11-16 20:18:42 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index f340a28996a..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - added: - - Add the 2023 Arkansas inflation relief credit amount and avoid attributing the amount twice for joint filers filing separately. diff --git a/setup.py b/setup.py index 8e720039771..2dec84097d6 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.142.2", + version="1.142.3", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 14c8006f9a529e3868f6418d49c6f87d47849be0 Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Sat, 16 Nov 2024 15:47:23 -0500 Subject: [PATCH 28/35] Remove the child tax rebate from the list of 2023 rhode island refundable credits (#5330) Fixes #5329 --- changelog_entry.yaml | 4 ++++ .../ri/tax/income/credits/refundable.yaml | 3 +++ .../gov/states/ri/tax/income/integration.yaml | 21 +++++++++++++++++++ 3 files changed, 28 insertions(+) create mode 100644 policyengine_us/tests/policy/baseline/gov/states/ri/tax/income/integration.yaml diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..49fa1238050 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + fixed: + - Remove the child tax rebate from the list of 2023 rhode island refundable credits. diff --git a/policyengine_us/parameters/gov/states/ri/tax/income/credits/refundable.yaml b/policyengine_us/parameters/gov/states/ri/tax/income/credits/refundable.yaml index c879eabec8e..5ba2c0e240c 100644 --- a/policyengine_us/parameters/gov/states/ri/tax/income/credits/refundable.yaml +++ b/policyengine_us/parameters/gov/states/ri/tax/income/credits/refundable.yaml @@ -7,6 +7,9 @@ values: - ri_eitc - ri_property_tax_credit - ri_child_tax_rebate + 2023-01-01: + - ri_eitc + - ri_property_tax_credit metadata: reference: diff --git a/policyengine_us/tests/policy/baseline/gov/states/ri/tax/income/integration.yaml b/policyengine_us/tests/policy/baseline/gov/states/ri/tax/income/integration.yaml new file mode 100644 index 00000000000..d23407d6c7a --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/states/ri/tax/income/integration.yaml @@ -0,0 +1,21 @@ +- name: Joint filers with 81k of income each and one dependent + period: 2023 + absolute_error_margin: 1 + input: + people: + person1: + age: 30 + employment_income: 81_000 + person2: + age: 19 + employment_income: 81_000 + person3: + age: 8 + tax_units: + tax_units: + members: [person1, person2, person3] + households: + households: + state_code: RI + output: + ri_income_tax: 5_338 From e9d57c0d7e88d28dbffcb0a74c9bb86db2605801 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Sat, 16 Nov 2024 20:51:09 +0000 Subject: [PATCH 29/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bdebc4d35b0..5243863c43d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.142.4] - 2024-11-16 20:47:40 + +### Fixed + +- Remove the child tax rebate from the list of 2023 rhode island refundable credits. + ## [1.142.3] - 2024-11-16 20:18:42 ### Added @@ -10209,6 +10215,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.142.4]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.3...1.142.4 [1.142.3]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.2...1.142.3 [1.142.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.1...1.142.2 [1.142.1]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.0...1.142.1 diff --git a/changelog.yaml b/changelog.yaml index 1b1fc5ca693..38e57c383c5 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8655,3 +8655,8 @@ - Add the 2023 Arkansas inflation relief credit amount and avoid attributing the amount twice for joint filers filing separately. date: 2024-11-16 20:18:42 +- bump: patch + changes: + fixed: + - Remove the child tax rebate from the list of 2023 rhode island refundable credits. + date: 2024-11-16 20:47:40 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 49fa1238050..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - fixed: - - Remove the child tax rebate from the list of 2023 rhode island refundable credits. diff --git a/setup.py b/setup.py index 2dec84097d6..9d9cb914cef 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.142.3", + version="1.142.4", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From 4c439fadba91679a4dfbdf6ca1e0a2fcaef85f68 Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Sat, 16 Nov 2024 15:55:31 -0500 Subject: [PATCH 30/35] Populate va_agi_person and add the Virginia spouse tax adjustment to the net income tree (#5328) Fixes #5327 --- changelog_entry.yaml | 4 ++ .../gov/states/va/tax/income/integration.yaml | 30 ++++++++++++++- .../states/va/tax/income/va_agi_person.yaml | 37 +++++++++++++++++++ ..._income_tax_before_refundable_credits.yaml | 10 +++++ .../gov/states/va/tax/income/va_agi_person.py | 10 +++++ ...va_income_tax_before_refundable_credits.py | 6 ++- 6 files changed, 95 insertions(+), 2 deletions(-) create mode 100644 policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_agi_person.yaml diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..c4283261a04 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: patch + changes: + added: + - Populate va_agi_person and add the Virginia spouse tax adjustment to the net income tree. diff --git a/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/integration.yaml b/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/integration.yaml index c9b1f690442..891e1adfbd2 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/integration.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/integration.yaml @@ -136,4 +136,32 @@ output: # expected results from patched TAXSIM35 2024-05-07 version va_reduced_itemized_deductions: 37_049.81 va_itemized_deductions: 37_049.81 - va_income_tax: 18433.05 + va_income_tax: 18175.545 + +- name: Joint couple with one child, 81k income each + absolute_error_margin: 2 + period: 2023 + input: + people: + person1: + age: 38 + employment_income: 81_000 + person2: + age: 38 + employment_income: 81_000 + person3: + age: 4 + tax_units: + tax_unit: + members: [person1, person2, person3] + va_rebate: 0 + households: + household: + members: [person1, person2, person3] + state_code: VA + output: + va_taxable_income: 143_210 + va_income_tax_before_non_refundable_credits: 7_977 + va_non_refundable_credits: 0 + va_spouse_tax_adjustment: 257 + va_income_tax: 7_718 diff --git a/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_agi_person.yaml b/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_agi_person.yaml new file mode 100644 index 00000000000..23d360813f4 --- /dev/null +++ b/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_agi_person.yaml @@ -0,0 +1,37 @@ +- name: Attributing the state adjusted gross income based on federal AGI + period: 2021 + input: + people: + person1: + adjusted_gross_income_person: 10_000 + person2: + adjusted_gross_income_person: 30_000 + tax_units: + tax_unit: + members: [person1, person2] + va_agi: 30_000 + households: + household: + members: [person1, person2] + state_code: VA + output: + va_agi_person: [7_500, 22_500] + +- name: One person without income + period: 2021 + input: + people: + person1: + adjusted_gross_income_person: 10_000 + person2: + adjusted_gross_income_person: 0 + tax_units: + tax_unit: + members: [person1, person2] + va_agi: 8_000 + households: + household: + members: [person1, person2] + state_code: VA + output: + va_agi_person: [8_000, 0] diff --git a/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_income_tax_before_refundable_credits.yaml b/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_income_tax_before_refundable_credits.yaml index 0e45f598220..bde9ed1bb2f 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_income_tax_before_refundable_credits.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/va/tax/income/va_income_tax_before_refundable_credits.yaml @@ -15,3 +15,13 @@ state_code: VA output: va_income_tax_before_refundable_credits: 0 + +- name: Reduction including the spouse tax adjustment + period: 2022 + input: + va_income_tax_before_non_refundable_credits: 2_000 + va_non_refundable_credits: 900 + va_spouse_tax_adjustment: 300 + state_code: VA + output: + va_income_tax_before_refundable_credits: 800 diff --git a/policyengine_us/variables/gov/states/va/tax/income/va_agi_person.py b/policyengine_us/variables/gov/states/va/tax/income/va_agi_person.py index 21d5c53f890..2b2d5bcf0a8 100644 --- a/policyengine_us/variables/gov/states/va/tax/income/va_agi_person.py +++ b/policyengine_us/variables/gov/states/va/tax/income/va_agi_person.py @@ -10,3 +10,13 @@ class va_agi_person(Variable): # Virginia includes an individual level definition for AGI reference = "https://www.tax.virginia.gov/laws-rules-decisions/rulings-tax-commissioner/13-5" defined_for = StateCode.VA + + def formula(person, period, parameters): + total_agi = person.tax_unit("va_agi", period) + person_agi = person("adjusted_gross_income_person", period) + total_federal_agi = person.tax_unit.sum(person_agi) + + prorate = np.zeros_like(total_agi) + mask = total_federal_agi > 0 + prorate[mask] = person_agi[mask] / total_federal_agi[mask] + return total_agi * prorate diff --git a/policyengine_us/variables/gov/states/va/tax/income/va_income_tax_before_refundable_credits.py b/policyengine_us/variables/gov/states/va/tax/income/va_income_tax_before_refundable_credits.py index b832d2dd48a..df922e13639 100644 --- a/policyengine_us/variables/gov/states/va/tax/income/va_income_tax_before_refundable_credits.py +++ b/policyengine_us/variables/gov/states/va/tax/income/va_income_tax_before_refundable_credits.py @@ -17,6 +17,10 @@ def formula(tax_unit, period, parameters): "va_income_tax_before_non_refundable_credits", period ) non_refundable_credits = tax_unit("va_non_refundable_credits", period) + spouse_tax_adjustment = tax_unit("va_spouse_tax_adjustment", period) return max_( - tax_before_non_refundable_credits - non_refundable_credits, 0 + tax_before_non_refundable_credits + - non_refundable_credits + - spouse_tax_adjustment, + 0, ) From f3dfb9f986bcf56256a9f53b842d401edfd3497b Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Sat, 16 Nov 2024 20:59:16 +0000 Subject: [PATCH 31/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 6 ++++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5243863c43d..49a6fbecc0f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.142.5] - 2024-11-16 20:55:48 + +### Added + +- Populate va_agi_person and add the Virginia spouse tax adjustment to the net income tree. + ## [1.142.4] - 2024-11-16 20:47:40 ### Fixed @@ -10215,6 +10221,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.142.5]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.4...1.142.5 [1.142.4]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.3...1.142.4 [1.142.3]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.2...1.142.3 [1.142.2]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.1...1.142.2 diff --git a/changelog.yaml b/changelog.yaml index 38e57c383c5..e686c3c53db 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8660,3 +8660,9 @@ fixed: - Remove the child tax rebate from the list of 2023 rhode island refundable credits. date: 2024-11-16 20:47:40 +- bump: patch + changes: + added: + - Populate va_agi_person and add the Virginia spouse tax adjustment to the net + income tree. + date: 2024-11-16 20:55:48 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index c4283261a04..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: patch - changes: - added: - - Populate va_agi_person and add the Virginia spouse tax adjustment to the net income tree. diff --git a/setup.py b/setup.py index 9d9cb914cef..6fc7f0de7c9 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.142.4", + version="1.142.5", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From ac25a94c173408a07fc07a8d830a0808931c26eb Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Sun, 17 Nov 2024 20:37:41 -0500 Subject: [PATCH 32/35] Montana 2023 income tax rule updates (#5337) * Montana 2023 income tax rule updates Fixes #5336 * test adj. --- changelog_entry.yaml | 4 ++++ .../rent_equivalent_tax_rate.yaml | 1 - .../states/mt/tax/income/deductions/standard/cap.yaml | 8 +++++++- .../mt/tax/income/deductions/standard/floor.yaml | 7 +++++++ .../gov/states/mt/tax/income/exemptions/amount.yaml | 3 +++ .../states/mt/tax/income/main/head_of_household.yaml | 8 ++++++++ .../gov/states/mt/tax/income/main/joint.yaml | 8 ++++++++ .../gov/states/mt/tax/income/main/separate.yaml | 8 ++++++++ .../gov/states/mt/tax/income/main/single.yaml | 8 ++++++++ .../gov/states/mt/tax/income/main/widow.yaml | 10 +++++++++- .../exemptions/mt_personal_exemptions_indiv.yaml | 4 ++-- 11 files changed, 64 insertions(+), 5 deletions(-) diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..3d1e9398658 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + added: + - Montana 2023 income tax rule updates. diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/credits/elderly_homeowner_or_renter/rent_equivalent_tax_rate.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/credits/elderly_homeowner_or_renter/rent_equivalent_tax_rate.yaml index a864faccf81..420470e16b5 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/credits/elderly_homeowner_or_renter/rent_equivalent_tax_rate.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/credits/elderly_homeowner_or_renter/rent_equivalent_tax_rate.yaml @@ -17,4 +17,3 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021.pdf#page=10 - title: 2023 Form of Montana Individual Income Tax Return, Page 10, Line 17 href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/12/Form_2_2023.pdf#page=10 - diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/cap.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/cap.yaml index b2e63f58940..82593ffb059 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/cap.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/cap.yaml @@ -12,20 +12,26 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/05/Montana-Idividiual-Income-Tax-Return-Form-2-2022v6.2.pdf#page=7 - title: Montana Tax Form 2021 | Standard Deduction | Line 3 href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021.pdf#page=7 - + - title: Montana Tax Form 2023 | Exemptions | Standard Deduction Worksheet + href: https://wwwa.fileyourtaxes.com/www17/cgi-bin/static/displayBlankPDF.pl?form=MT-FORM2.pdf&year=2023 JOINT: 2021-01-01: 9_660 2022-01-01: 10_180 + 2023-01-01: 11_080 HEAD_OF_HOUSEHOLD: 2021-01-01: 9_660 2022-01-01: 10_180 + 2023-01-01: 11_080 SURVIVING_SPOUSE: 2021-01-01: 4_830 2022-01-01: 5_090 + 2023-01-01: 5_540 SINGLE: 2021-01-01: 4_830 2022-01-01: 5_090 + 2023-01-01: 5_540 SEPARATE: 2021-01-01: 4_830 2022-01-01: 5_090 + 2023-01-01: 5_540 diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/floor.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/floor.yaml index e1996bb3341..732d819b82d 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/floor.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/deductions/standard/floor.yaml @@ -12,19 +12,26 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/05/Montana-Idividiual-Income-Tax-Return-Form-2-2022v6.2.pdf#page=7 - title: Montana Tax Form 2021 | Standard Deduction | Line 5 href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021.pdf#page=7 + - title: Montana Tax Form 2023 | Exemptions | Standard Deduction Worksheet + href: https://wwwa.fileyourtaxes.com/www17/cgi-bin/static/displayBlankPDF.pl?form=MT-FORM2.pdf&year=2023 JOINT: 2021-01-01: 4_280 2022-01-01: 4_520 + 2023-01-01: 4_920 HEAD_OF_HOUSEHOLD: 2021-01-01: 4_280 2022-01-01: 4_520 + 2023-01-01: 4_920 SURVIVING_SPOUSE: 2021-01-01: 2_140 2022-01-01: 2_260 + 2023-01-01: 2_460 SINGLE: 2021-01-01: 2_140 2022-01-01: 2_260 + 2023-01-01: 2_460 SEPARATE: 2021-01-01: 2_140 2022-01-01: 2_260 + 2023-01-01: 2_460 diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/exemptions/amount.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/exemptions/amount.yaml index 282cb22bc60..a717fdccfc8 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/exemptions/amount.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/exemptions/amount.yaml @@ -2,6 +2,7 @@ description: Montana deducts this amount for each eligible exemption when comput values: 2021-01-01: 2_580 2022-01-01: 2_710 + 2023-01-01: 2_960 metadata: reference: - title: "Montana Tax Form 2021 | Exemptions | Line 16" @@ -10,6 +11,8 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/05/Montana-Idividiual-Income-Tax-Return-Form-2-2022v6.2.pdf#page=1 - title: Rule 42.15.402 - Personal Exemptions (4) (b) href: https://regulations.justia.com/states/montana/department-42/chapter-42-15/subchapter-42-15-4/rule-42-15-402/ + - title: Montana Tax Form 2023 | Exemptions | Line 16 + href: https://wwwa.fileyourtaxes.com/www17/cgi-bin/static/displayBlankPDF.pl?form=MT-FORM2.pdf&year=2023 unit: currency-USD period: year label: Montana income tax exemption amount diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/main/head_of_household.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/main/head_of_household.yaml index 1bb1878ff2a..811f106ce1c 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/main/head_of_household.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/main/head_of_household.yaml @@ -11,6 +11,8 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2022/12/Form-2-2022-Instructions.pdf#page=16 - title: 2021 Montana income tax form 2 Instructions href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021%20instructions.pdf#page=15 + - title: 2023 Montana income tax form 2 Instructions + href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/12/Form_2_2023_Instructions.pdf#page=18 # Before 2024 Montana has a consistent tax rate for each filing status # After 2024 the tax rate depends on the filing status brackets: @@ -22,6 +24,7 @@ brackets: - threshold: 2021-01-01: 3_100 2022-01-01: 3_300 + 2023-01-01: 3_600 2024-01-01: 30_750 rate: 2021-01-01: 0.02 @@ -29,6 +32,7 @@ brackets: - threshold: 2021-01-01: 5_500 2022-01-01: 5_800 + 2023-01-01: 6_300 2024-01-01: .inf rate: 2021-01-01: 0.03 @@ -36,6 +40,7 @@ brackets: - threshold: 2021-01-01: 8_400 2022-01-01: 8_900 + 2023-01-01: 9_700 2024-01-01: .inf rate: 2021-01-01: 0.04 @@ -43,6 +48,7 @@ brackets: - threshold: 2021-01-01: 11_400 2022-01-01: 12_000 + 2023-01-01: 13_000 2024-01-01: .inf rate: 2021-01-01: 0.05 @@ -50,6 +56,7 @@ brackets: - threshold: 2021-01-01: 14_600 2022-01-01: 15_400 + 2023-01-01: 16_800 2024-01-01: .inf rate: 2021-01-01: 0.06 @@ -57,6 +64,7 @@ brackets: - threshold: 2021-01-01: 18_800 2022-01-01: 19_800 + 2023-01-01: 21_600 2024-01-01: .inf rate: 2021-01-01: 0.069 diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/main/joint.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/main/joint.yaml index c75b9d337d6..519d324e3a8 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/main/joint.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/main/joint.yaml @@ -11,6 +11,8 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2022/12/Form-2-2022-Instructions.pdf#page=16 - title: 2021 Montana income tax form 2 Instructions href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021%20instructions.pdf#page=15 + - title: 2023 Montana income tax form 2 Instructions + href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/12/Form_2_2023_Instructions.pdf#page=18 # Before 2024 Montana has a consistent tax rate for each filing status # After 2024 the tax rate depends on the filing status brackets: @@ -22,6 +24,7 @@ brackets: - threshold: 2021-01-01: 3_100 2022-01-01: 3_300 + 2023-01-01: 3_600 2024-01-01: 41_000 rate: 2021-01-01: 0.02 @@ -29,6 +32,7 @@ brackets: - threshold: 2021-01-01: 5_500 2022-01-01: 5_800 + 2023-01-01: 6_300 2024-01-01: .inf rate: 2021-01-01: 0.03 @@ -36,6 +40,7 @@ brackets: - threshold: 2021-01-01: 8_400 2022-01-01: 8_900 + 2023-01-01: 9_700 2024-01-01: .inf rate: 2021-01-01: 0.04 @@ -43,6 +48,7 @@ brackets: - threshold: 2021-01-01: 11_400 2022-01-01: 12_000 + 2023-01-01: 13_000 2024-01-01: .inf rate: 2021-01-01: 0.05 @@ -50,6 +56,7 @@ brackets: - threshold: 2021-01-01: 14_600 2022-01-01: 15_400 + 2023-01-01: 16_800 2024-01-01: .inf rate: 2021-01-01: 0.06 @@ -57,6 +64,7 @@ brackets: - threshold: 2021-01-01: 18_800 2022-01-01: 19_800 + 2023-01-01: 21_600 2024-01-01: .inf rate: 2021-01-01: 0.069 diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/main/separate.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/main/separate.yaml index 5c1b855288f..a9cdb4dd734 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/main/separate.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/main/separate.yaml @@ -11,6 +11,8 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2022/12/Form-2-2022-Instructions.pdf#page=16 - title: 2021 Montana income tax form 2 Instructions href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021%20instructions.pdf#page=15 + - title: 2023 Montana income tax form 2 Instructions + href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/12/Form_2_2023_Instructions.pdf#page=18 # Before 2024 Montana has a consistent tax rate for each filing status # After 2024 the tax rate depends on the filing status brackets: @@ -22,6 +24,7 @@ brackets: - threshold: 2021-01-01: 3_100 2022-01-01: 3_300 + 2023-01-01: 3_600 2024-01-01: 20_500 rate: 2021-01-01: 0.02 @@ -29,6 +32,7 @@ brackets: - threshold: 2021-01-01: 5_500 2022-01-01: 5_800 + 2023-01-01: 6_300 2024-01-01: .inf rate: 2021-01-01: 0.03 @@ -36,6 +40,7 @@ brackets: - threshold: 2021-01-01: 8_400 2022-01-01: 8_900 + 2023-01-01: 9_700 2024-01-01: .inf rate: 2021-01-01: 0.04 @@ -43,6 +48,7 @@ brackets: - threshold: 2021-01-01: 11_400 2022-01-01: 12_000 + 2023-01-01: 13_000 2024-01-01: .inf rate: 2021-01-01: 0.05 @@ -50,6 +56,7 @@ brackets: - threshold: 2021-01-01: 14_600 2022-01-01: 15_400 + 2023-01-01: 16_800 2024-01-01: .inf rate: 2021-01-01: 0.06 @@ -57,6 +64,7 @@ brackets: - threshold: 2021-01-01: 18_800 2022-01-01: 19_800 + 2023-01-01: 21_600 2024-01-01: .inf rate: 2021-01-01: 0.069 diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/main/single.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/main/single.yaml index 4ac40416477..5e54aae8ba2 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/main/single.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/main/single.yaml @@ -11,6 +11,8 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2022/12/Form-2-2022-Instructions.pdf#page=16 - title: 2021 Montana income tax form 2 Instructions href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021%20instructions.pdf#page=15 + - title: 2023 Montana income tax form 2 Instructions + href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/12/Form_2_2023_Instructions.pdf#page=18 # Before 2024 Montana has a consistent tax rate for each filing status # After 2024 the tax rate depends on the filing status brackets: @@ -22,6 +24,7 @@ brackets: - threshold: 2021-01-01: 3_100 2022-01-01: 3_300 + 2023-01-01: 3_600 2024-01-01: 20_500 rate: 2021-01-01: 0.02 @@ -29,6 +32,7 @@ brackets: - threshold: 2021-01-01: 5_500 2022-01-01: 5_800 + 2023-01-01: 6_300 2024-01-01: .inf rate: 2021-01-01: 0.03 @@ -36,6 +40,7 @@ brackets: - threshold: 2021-01-01: 8_400 2022-01-01: 8_900 + 2023-01-01: 9_700 2024-01-01: .inf rate: 2021-01-01: 0.04 @@ -43,6 +48,7 @@ brackets: - threshold: 2021-01-01: 11_400 2022-01-01: 12_000 + 2023-01-01: 13_000 2024-01-01: .inf rate: 2021-01-01: 0.05 @@ -50,6 +56,7 @@ brackets: - threshold: 2021-01-01: 14_600 2022-01-01: 15_400 + 2023-01-01: 16_800 2024-01-01: .inf rate: 2021-01-01: 0.06 @@ -57,6 +64,7 @@ brackets: - threshold: 2021-01-01: 18_800 2022-01-01: 19_800 + 2023-01-01: 21_600 2024-01-01: .inf rate: 2021-01-01: 0.069 diff --git a/policyengine_us/parameters/gov/states/mt/tax/income/main/widow.yaml b/policyengine_us/parameters/gov/states/mt/tax/income/main/widow.yaml index 9606bc3a83e..7b42efe8a9d 100644 --- a/policyengine_us/parameters/gov/states/mt/tax/income/main/widow.yaml +++ b/policyengine_us/parameters/gov/states/mt/tax/income/main/widow.yaml @@ -11,6 +11,8 @@ metadata: href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2022/12/Form-2-2022-Instructions.pdf#page=16 - title: 2021 Montana income tax form 2 Instructions href: https://mtrevenue.gov/wp-content/uploads/mdocs/form%202%202021%20instructions.pdf#page=15 + - title: 2023 Montana income tax form 2 Instructions + href: https://mtrevenue.gov/wp-content/uploads/dlm_uploads/2023/12/Form_2_2023_Instructions.pdf#page=18 # Before 2024 Montana has a consistent tax rate for each filing status # After 2024 the tax rate depends on the filing status brackets: @@ -22,6 +24,7 @@ brackets: - threshold: 2021-01-01: 3_100 2022-01-01: 3_300 + 2023-01-01: 3_600 2024-01-01: 41_000 rate: 2021-01-01: 0.02 @@ -29,13 +32,15 @@ brackets: - threshold: 2021-01-01: 5_500 2022-01-01: 5_800 + 2023-01-01: 6_300 2024-01-01: .inf rate: 2021-01-01: 0.03 2024-01-01: 0.065 - threshold: 2021-01-01: 8_400 - 2022-01-01: 8_900 + 2022-01-01: 8_900 + 2023-01-01: 9_700 2024-01-01: .inf rate: 2021-01-01: 0.04 @@ -43,6 +48,7 @@ brackets: - threshold: 2021-01-01: 11_400 2022-01-01: 12_000 + 2023-01-01: 13_000 2024-01-01: .inf rate: 2021-01-01: 0.05 @@ -50,6 +56,7 @@ brackets: - threshold: 2021-01-01: 14_600 2022-01-01: 15_400 + 2023-01-01: 16_800 2024-01-01: .inf rate: 2021-01-01: 0.06 @@ -57,6 +64,7 @@ brackets: - threshold: 2021-01-01: 18_800 2022-01-01: 19_800 + 2023-01-01: 21_600 2024-01-01: .inf rate: 2021-01-01: 0.069 diff --git a/policyengine_us/tests/policy/baseline/gov/states/mt/tax/income/exemptions/mt_personal_exemptions_indiv.yaml b/policyengine_us/tests/policy/baseline/gov/states/mt/tax/income/exemptions/mt_personal_exemptions_indiv.yaml index e2f348beb85..24ecdb2cbe9 100644 --- a/policyengine_us/tests/policy/baseline/gov/states/mt/tax/income/exemptions/mt_personal_exemptions_indiv.yaml +++ b/policyengine_us/tests/policy/baseline/gov/states/mt/tax/income/exemptions/mt_personal_exemptions_indiv.yaml @@ -1,5 +1,5 @@ - name: Four exemptions total - period: 2023 + period: 2022 input: is_tax_unit_head: true is_blind: false @@ -9,7 +9,7 @@ mt_personal_exemptions_indiv: 5_420 - name: No exemptions for the dependent - period: 2023 + period: 2022 input: is_tax_unit_head: false is_blind: false From 1479433215f1b6e1f6ba2c5411db7ee6078c74ef Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Mon, 18 Nov 2024 01:41:26 +0000 Subject: [PATCH 33/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 49a6fbecc0f..88d2a19535f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.143.0] - 2024-11-18 01:37:58 + +### Added + +- Montana 2023 income tax rule updates. + ## [1.142.5] - 2024-11-16 20:55:48 ### Added @@ -10221,6 +10227,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.143.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.5...1.143.0 [1.142.5]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.4...1.142.5 [1.142.4]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.3...1.142.4 [1.142.3]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.2...1.142.3 diff --git a/changelog.yaml b/changelog.yaml index e686c3c53db..35da04b58ef 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8666,3 +8666,8 @@ - Populate va_agi_person and add the Virginia spouse tax adjustment to the net income tree. date: 2024-11-16 20:55:48 +- bump: minor + changes: + added: + - Montana 2023 income tax rule updates. + date: 2024-11-18 01:37:58 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 3d1e9398658..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: minor - changes: - added: - - Montana 2023 income tax rule updates. diff --git a/setup.py b/setup.py index 6fc7f0de7c9..72f88a5de72 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.142.5", + version="1.143.0", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme, From b99520aabff9546cba9ff10fc70601c699b3fb21 Mon Sep 17 00:00:00 2001 From: Pavel Makarchuk <110687043+PavelMakarchuk@users.noreply.github.com> Date: Sun, 17 Nov 2024 21:10:55 -0500 Subject: [PATCH 34/35] SALT deduction phase-out reform (#5335) * SALT deduction phase-out reform Fixes #5334 * format * agi instead of earned income --- changelog_entry.yaml | 4 ++ .../gov/contrib/salt_phase_out/in_effect.yaml | 8 +++ .../gov/contrib/salt_phase_out/rate.yaml | 18 +++++++ policyengine_us/reforms/reforms.py | 5 ++ .../reforms/salt_phase_out/__init__.py | 3 ++ .../salt_phase_out/salt_phase_out_reform.py | 49 +++++++++++++++++ .../salt_phase_out/salt_phase_out_reform.yaml | 53 +++++++++++++++++++ 7 files changed, 140 insertions(+) create mode 100644 policyengine_us/parameters/gov/contrib/salt_phase_out/in_effect.yaml create mode 100644 policyengine_us/parameters/gov/contrib/salt_phase_out/rate.yaml create mode 100644 policyengine_us/reforms/salt_phase_out/__init__.py create mode 100644 policyengine_us/reforms/salt_phase_out/salt_phase_out_reform.py create mode 100644 policyengine_us/tests/policy/contrib/salt_phase_out/salt_phase_out_reform.yaml diff --git a/changelog_entry.yaml b/changelog_entry.yaml index e69de29bb2d..06f83f605d8 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -0,0 +1,4 @@ +- bump: minor + changes: + added: + - SALT deduction phase-out reform. diff --git a/policyengine_us/parameters/gov/contrib/salt_phase_out/in_effect.yaml b/policyengine_us/parameters/gov/contrib/salt_phase_out/in_effect.yaml new file mode 100644 index 00000000000..a926a2903a2 --- /dev/null +++ b/policyengine_us/parameters/gov/contrib/salt_phase_out/in_effect.yaml @@ -0,0 +1,8 @@ +description: The SALT deduction is phased out based on earnings, if this is true. +metadata: + unit: bool + period: year + label: SALT deduction phase out in effect + +values: + 0000-01-01: false diff --git a/policyengine_us/parameters/gov/contrib/salt_phase_out/rate.yaml b/policyengine_us/parameters/gov/contrib/salt_phase_out/rate.yaml new file mode 100644 index 00000000000..f36f8b1d1f1 --- /dev/null +++ b/policyengine_us/parameters/gov/contrib/salt_phase_out/rate.yaml @@ -0,0 +1,18 @@ +description: The SALT deduction is phased out at this rate, based on earnings. + +brackets: + - threshold: + 0000-01-01: 0 + rate: + 0000-01-01: 0 + - threshold: + 0000-01-01: 0 + rate: + 0000-01-01: 0 + +metadata: + label: SALT deduction phase out rate + type: marginal_rate + threshold_unit: currency-USD + rate_unit: /1 + period: year diff --git a/policyengine_us/reforms/reforms.py b/policyengine_us/reforms/reforms.py index ef42e5e1dc1..486632ed99c 100644 --- a/policyengine_us/reforms/reforms.py +++ b/policyengine_us/reforms/reforms.py @@ -53,6 +53,9 @@ from .tax_exempt.tax_exempt_reform import ( create_tax_exempt_reform, ) +from .salt_phase_out.salt_phase_out_reform import ( + create_salt_phase_out_reform, +) from policyengine_core.reforms import Reform @@ -126,6 +129,7 @@ def create_structural_reforms_from_parameters(parameters, period): parameters, period ) tip_income_tax_exempt = create_tax_exempt_reform(parameters, period) + salt_phase_out = create_salt_phase_out_reform(parameters, period) reforms = [ afa_reform, @@ -153,6 +157,7 @@ def create_structural_reforms_from_parameters(parameters, period): repeal_dependent_exemptions, harris_capital_gains, tip_income_tax_exempt, + salt_phase_out, ] reforms = tuple(filter(lambda x: x is not None, reforms)) diff --git a/policyengine_us/reforms/salt_phase_out/__init__.py b/policyengine_us/reforms/salt_phase_out/__init__.py new file mode 100644 index 00000000000..ced78e371e7 --- /dev/null +++ b/policyengine_us/reforms/salt_phase_out/__init__.py @@ -0,0 +1,3 @@ +from .salt_phase_out_reform import ( + create_salt_phase_out_reform, +) diff --git a/policyengine_us/reforms/salt_phase_out/salt_phase_out_reform.py b/policyengine_us/reforms/salt_phase_out/salt_phase_out_reform.py new file mode 100644 index 00000000000..1242600d176 --- /dev/null +++ b/policyengine_us/reforms/salt_phase_out/salt_phase_out_reform.py @@ -0,0 +1,49 @@ +from policyengine_us.model_api import * + + +def create_salt_phase_out() -> Reform: + class salt_deduction(Variable): + value_type = float + entity = TaxUnit + label = "SALT deduction" + unit = USD + documentation = "State and local taxes plus real estate tax deduction from taxable income." + definition_period = YEAR + reference = "https://www.law.cornell.edu/uscode/text/26/164" + + def formula(tax_unit, period, parameters): + salt_amount = add( + tax_unit, + period, + ["state_and_local_sales_or_income_tax", "real_estate_taxes"], + ) + p = parameters( + period + ).gov.irs.deductions.itemized.salt_and_real_estate + cap = p.cap[tax_unit("filing_status", period)] + p_ref = parameters(period).gov.contrib.salt_phase_out + income = tax_unit("adjusted_gross_income", period) + phase_out = p_ref.rate.calc(income) + capped_salt = min_(cap, salt_amount) + return max_(0, capped_salt - phase_out) + + class reform(Reform): + def apply(self): + self.update_variable(salt_deduction) + + return reform + + +def create_salt_phase_out_reform(parameters, period, bypass: bool = False): + if bypass: + return create_salt_phase_out() + + p = parameters(period).gov.contrib.salt_phase_out + + if p.in_effect: + return create_salt_phase_out() + else: + return None + + +salt_phase_out_reform = create_salt_phase_out_reform(None, None, bypass=True) diff --git a/policyengine_us/tests/policy/contrib/salt_phase_out/salt_phase_out_reform.yaml b/policyengine_us/tests/policy/contrib/salt_phase_out/salt_phase_out_reform.yaml new file mode 100644 index 00000000000..d07738fe4bc --- /dev/null +++ b/policyengine_us/tests/policy/contrib/salt_phase_out/salt_phase_out_reform.yaml @@ -0,0 +1,53 @@ +- name: Single filer with income below reduction amount + period: 2024 + reforms: policyengine_us.reforms.salt_phase_out.salt_phase_out_reform.salt_phase_out_reform + input: + gov.contrib.salt_phase_out.in_effect: true + gov.contrib.salt_phase_out.rate[1].threshold: 100_000 + gov.contrib.salt_phase_out.rate[1].rate: 0.1 + people: + person1: + real_estate_taxes: 10_000 + tax_units: + tax_unit: + members: [person1] + filing_status: SINGLE + adjusted_gross_income: 100_000 + output: + salt_deduction: 10_000 + +- name: Single filer with income above reduction amount + period: 2024 + reforms: policyengine_us.reforms.salt_phase_out.salt_phase_out_reform.salt_phase_out_reform + input: + gov.contrib.salt_phase_out.in_effect: true + gov.contrib.salt_phase_out.rate[1].threshold: 100_000 + gov.contrib.salt_phase_out.rate[1].rate: 0.1 + people: + person1: + real_estate_taxes: 10_000 + tax_units: + tax_unit: + members: [person1] + filing_status: SINGLE + adjusted_gross_income: 120_000 + output: + salt_deduction: 8_000 + +- name: Fully phased out + period: 2024 + reforms: policyengine_us.reforms.salt_phase_out.salt_phase_out_reform.salt_phase_out_reform + input: + gov.contrib.salt_phase_out.in_effect: true + gov.contrib.salt_phase_out.rate[1].threshold: 100_000 + gov.contrib.salt_phase_out.rate[1].rate: 1 + people: + person1: + real_estate_taxes: 10_000 + tax_units: + tax_unit: + members: [person1] + filing_status: SINGLE + adjusted_gross_income: 500_000 + output: + salt_deduction: 0 From 339e54d242b30f21bd4692bb50c05bc143e12708 Mon Sep 17 00:00:00 2001 From: "Github Actions[bot]" Date: Mon, 18 Nov 2024 02:14:48 +0000 Subject: [PATCH 35/35] Update PolicyEngine US --- CHANGELOG.md | 7 +++++++ changelog.yaml | 5 +++++ changelog_entry.yaml | 4 ---- setup.py | 2 +- 4 files changed, 13 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 88d2a19535f..38825796b70 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.144.0] - 2024-11-18 02:11:15 + +### Added + +- SALT deduction phase-out reform. + ## [1.143.0] - 2024-11-18 01:37:58 ### Added @@ -10227,6 +10233,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 +[1.144.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.143.0...1.144.0 [1.143.0]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.5...1.143.0 [1.142.5]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.4...1.142.5 [1.142.4]: https://github.com/PolicyEngine/policyengine-us/compare/1.142.3...1.142.4 diff --git a/changelog.yaml b/changelog.yaml index 35da04b58ef..ca5f49d8148 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -8671,3 +8671,8 @@ added: - Montana 2023 income tax rule updates. date: 2024-11-18 01:37:58 +- bump: minor + changes: + added: + - SALT deduction phase-out reform. + date: 2024-11-18 02:11:15 diff --git a/changelog_entry.yaml b/changelog_entry.yaml index 06f83f605d8..e69de29bb2d 100644 --- a/changelog_entry.yaml +++ b/changelog_entry.yaml @@ -1,4 +0,0 @@ -- bump: minor - changes: - added: - - SALT deduction phase-out reform. diff --git a/setup.py b/setup.py index 72f88a5de72..0bfbeb29bf9 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name="policyengine-us", - version="1.143.0", + version="1.144.0", author="PolicyEngine", author_email="hello@policyengine.org", long_description=readme,