-
Notifications
You must be signed in to change notification settings - Fork 32
Tax free childcare #1004
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Tax free childcare #1004
Changes from 52 commits
Commits
Show all changes
65 commits
Select commit
Hold shift + click to select a range
adf96a0
Implement tax free childcare
vahid-ahmadi ee24d61
Parameterize values
vahid-ahmadi 12d24be
Reformatting to pass the tests
vahid-ahmadi 235fd08
Reformatting with black
vahid-ahmadi b3b1967
Reformatting with black
vahid-ahmadi 55ce6c3
Format code with black
vahid-ahmadi 9952ed9
Format code with black using 79-char line length
vahid-ahmadi d6b22e5
Fix YAML structure
vahid-ahmadi b06a47c
Fix age condition YAML file
vahid-ahmadi 90eb823
Fix age condition YAML file
vahid-ahmadi 0c871a5
Fix other YAML files
vahid-ahmadi b28b5f8
Edit parameterization
vahid-ahmadi ff1f456
Fix formatting
vahid-ahmadi d3ad685
Edit age in YAML files
vahid-ahmadi 5c6d359
Replace if with where
vahid-ahmadi e0221f8
Format with black
vahid-ahmadi fc83a03
Edit for test passing
vahid-ahmadi 4421154
Edit format with black
vahid-ahmadi b4e8d1a
Edit format of benefit py file
vahid-ahmadi cf7f6e6
Edit child as not being boolean
vahid-ahmadi d4ff3b2
Change if to where
vahid-ahmadi 0058402
Change disability definition
vahid-ahmadi 37c7228
Solve .values problem
vahid-ahmadi af96f3a
Edit .values error
vahid-ahmadi e96bc2e
Edit vectorization problem
vahid-ahmadi 153c2f6
Change folder from hmrc to dwp
vahid-ahmadi c9fbd0c
Use is_disabled_for_benefits variable
vahid-ahmadi a2f73d2
Add .astype(bool) to fix error
vahid-ahmadi a061877
Fix bitwise AND operation error
vahid-ahmadi a9ca8a7
Add .astype(bool) to conditions
vahid-ahmadi c7c6762
Add unit tests
vahid-ahmadi 59e1b78
Reformat with black
vahid-ahmadi cebaace
Fix the folders
vahid-ahmadi c1a5cf0
Fix the folders
vahid-ahmadi 49ec556
Merge branch 'tax-free-childcare-new' of https://github.com/policyeng…
vahid-ahmadi 4a5cad5
Implement free childcare program
vahid-ahmadi 4432db2
Format with black
vahid-ahmadi c7c1998
Change tests
vahid-ahmadi 789f676
Edit format based on Pavel's comments
vahid-ahmadi 9fc1b53
Edit tax-free childcare based on Pavel's comments
vahid-ahmadi a15d5a2
Reform with Black
vahid-ahmadi c1bb0e1
Remove redundant files
vahid-ahmadi df9f458
Edit files based on Pavel's comments
vahid-ahmadi d295f33
Format with black
vahid-ahmadi cb6ce03
Edit ‘adjusted_net_income’ and ‘is_blind’ parameters
vahid-ahmadi 6b4656e
Format with black
vahid-ahmadi 7c5f76d
Edit codes based on Max's comments
vahid-ahmadi 060d9f5
Reslove a conflict
vahid-ahmadi e029a0b
Apply Max's comments
vahid-ahmadi 536a410
Apply Max's comments
vahid-ahmadi b4d8890
Edit parameter in py code
vahid-ahmadi 2956ae2
Add the benefit to the list of benefits
vahid-ahmadi 5d45260
Apply Max's comments
vahid-ahmadi 9fe23a3
Edit law part
vahid-ahmadi a707e07
Edit law part
vahid-ahmadi 6899c77
Merge branch 'tax-free-childcare-new' of https://github.com/policyeng…
vahid-ahmadi d227246
Merge branch 'master' into tax-free-childcare-new
vahid-ahmadi a5ff04c
Edit benefit file for now
vahid-ahmadi 9df3baf
Apply Nikhil's comments
vahid-ahmadi bd13fa9
Format with black
vahid-ahmadi d436430
Update policyengine_uk/parameters/gov/hmrc/tax_free_childcare/income/…
nikhilwoodruff f1f5f13
Edit the description of countable income sources
vahid-ahmadi 1fc794a
Merge branch 'tax-free-childcare-new' of https://github.com/policyeng…
vahid-ahmadi cde37ba
Add TFC to gov_spending
vahid-ahmadi 593adcf
Edit name of the variable tax_free_childcare
vahid-ahmadi File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/age/disability.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| description: The HMRC department extends the tax-free childcare program eligibility to children with disabilities up to this age threshold. | ||
| metadata: | ||
| unit: year | ||
| period: year | ||
| label: Tax-free childcare disability age limit | ||
| reference: | ||
| - title: Childcare Payments Act 2014 - c. 28 - section 14 | ||
| href: https://www.legislation.gov.uk/ukpga/2014/28/notes/division/6/4/1 | ||
| - title: Tax-free childcare guidance | ||
| href: https://www.gov.uk/tax-free-childcare?step-by-step-nav=d78aeaf6-1747-4d72-9619-f16efb4dd89d | ||
| values: | ||
| 2015-01-01: 17 | ||
12 changes: 12 additions & 0 deletions
12
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/age/standard.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| description: The HMRC department extends the tax-free childcare program eligibility to children up to this age threshold. | ||
| metadata: | ||
| unit: year | ||
| period: year | ||
| label: Tax-free childcare standard age limit | ||
| reference: | ||
| - title: Childcare Payments Act 2014 - c. 28 - section 14 | ||
| href: https://www.legislation.gov.uk/ukpga/2014/28/notes/division/6/4/1 | ||
| - title: Tax-free childcare guidance | ||
| href: https://www.gov.uk/tax-free-childcare?step-by-step-nav=d78aeaf6-1747-4d72-9619-f16efb4dd89d | ||
| values: | ||
| 2015-01-01: 12 |
12 changes: 12 additions & 0 deletions
12
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/contribution/disabled_child.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| description: The HMRC department provides tax-free childcare contribution up to this yearly amount for households with disabled children. | ||
| metadata: | ||
| unit: currency-GBP | ||
| period: year | ||
| label: Tax-free childcare disabled child yearly limit | ||
| reference: | ||
| - title: Childcare Payments Act 2014 - c. 28 - section 19 | ||
| href: https://www.legislation.gov.uk/ukpga/2014/28/notes/division/6/5/5 | ||
| - title: Tax-free childcare guidance | ||
| href: https://www.gov.uk/tax-free-childcare?step-by-step-nav=d78aeaf6-1747-4d72-9619-f16efb4dd89d | ||
| values: | ||
| 2015-01-01: 4_000 |
12 changes: 12 additions & 0 deletions
12
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/contribution/standard_child.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| description: The HMRC department provides tax-free childcare contribution up to this yearly amount for households with children under standard eligibility. | ||
| metadata: | ||
| unit: currency-GBP | ||
| period: year | ||
| label: Tax-free childcare standard yearly limit | ||
| reference: | ||
| - title: Childcare Payments Act 2014 - c. 28 - section 19 | ||
| href: https://www.legislation.gov.uk/ukpga/2014/28/notes/division/6/5/5 | ||
| - title: Tax-free childcare guidance | ||
| href: https://www.gov.uk/tax-free-childcare?step-by-step-nav=d78aeaf6-1747-4d72-9619-f16efb4dd89d | ||
| values: | ||
| 2015-01-01: 2_000 |
13 changes: 13 additions & 0 deletions
13
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/disqualifying_benefits.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| description: HMRC limits Tax-Free Childcare to benefit units that do not receive any of these programs. | ||
| metadata: | ||
| reference: | ||
| - title: The Childcare Payments (Eligibility) Regulations 2015 - Part 16 and 18 | ||
| href: https://www.legislation.gov.uk/ukdsi/2015/9780111127063 | ||
| period: year | ||
| unit: program | ||
| label: Tax-free childcare disqualifying benefits | ||
| values: | ||
| 2015-01-01: | ||
| - working_tax_credit | ||
| - child_tax_credit | ||
| - universal_credit |
12 changes: 12 additions & 0 deletions
12
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/income_limit.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| description: The HMRC department limits tax-free childcare eligibility to households where individual adjusted income does not exceed this yearly threshold. | ||
| metadata: | ||
| unit: currency-GBP | ||
| period: year | ||
| label: Tax-free childcare maximum adjusted income threshold | ||
| reference: | ||
| - title: The Childcare Payments (Eligibility) Regulations 2015 - Regulation 15 | ||
| href: https://www.legislation.gov.uk/uksi/2015/448/regulation/15#commentary-key-e27c923eee152accd495af8425536e29 | ||
| - title: Tax-free childcare guidance | ||
| href: https://www.gov.uk/tax-free-childcare?step-by-step-nav=d78aeaf6-1747-4d72-9619-f16efb4dd89d | ||
| values: | ||
| 2015-01-01: 100_000 |
14 changes: 14 additions & 0 deletions
14
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/investment_income_types.yaml
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| description: HMRC excludes certain investment income types when determining eligibility for Tax-Free Childcare, including pension, savings, dividend, and property income | ||
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| metadata: | ||
| reference: | ||
| - title: The Childcare Payments (Eligibility) Regulations 2015 - Part 16 and 18 | ||
nikhilwoodruff marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| href: https://www.legislation.gov.uk/ukdsi/2015/9780111127063 | ||
| period: year | ||
| unit: currency-GBP | ||
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| label: none | ||
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| values: | ||
| 2015-01-01: | ||
| - private_pension_income | ||
| - savings_interest_income | ||
| - dividend_income | ||
| - property_income | ||
10 changes: 10 additions & 0 deletions
10
policyengine_uk/parameters/gov/hmrc/tax_free_childcare/minimum_weekly_hours.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| description: Claimants must work sufficient hours to earn the equivalent of 16 hours per week at National Minimum Wage. | ||
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| metadata: | ||
| period: year | ||
| unit: hour | ||
| label: Minimum weekly working hours threshold at National Minimum Wage | ||
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| reference: | ||
| - title: The Childcare Payments (Eligibility) (Amendment) Regulations 2016 - regulation 3 | ||
| href: https://www.legislation.gov.uk/uksi/2016/793/regulation/3/made | ||
| values: | ||
| 2016-01-01: 16 | ||
31 changes: 31 additions & 0 deletions
31
...s/policy/baseline/gov/hmrc/tax_free_childcare/tax_free_childcare_age_child_condition.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| - name: Under standard age limit - eligible | ||
| period: 2025 | ||
| input: | ||
| age: 10 | ||
| is_disabled_for_benefits: false | ||
| output: | ||
| tax_free_childcare_child_age_eligible: true | ||
|
|
||
| - name: Over standard age limit and not disabled - ineligible | ||
| period: 2025 | ||
| input: | ||
| age: 12 | ||
| is_disabled_for_benefits: false | ||
| output: | ||
| tax_free_childcare_child_age_eligible: false | ||
|
|
||
| - name: Over standard age but under disability limit and disabled - eligible | ||
| period: 2025 | ||
| input: | ||
| age: 15 | ||
| is_disabled_for_benefits: true | ||
| output: | ||
| tax_free_childcare_child_age_eligible: true | ||
|
|
||
| - name: Over disability age limit and disabled - ineligible | ||
| period: 2025 | ||
| input: | ||
| age: 17 | ||
| is_disabled_for_benefits: true | ||
| output: | ||
| tax_free_childcare_child_age_eligible: false |
36 changes: 36 additions & 0 deletions
36
...tests/policy/baseline/gov/hmrc/tax_free_childcare/tax_free_childcare_benefits_amount.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| # Tests for tax_free_childcare | ||
| - name: Eligible standard child | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_eligible: true | ||
| is_child: true | ||
| is_disabled_for_benefits: false | ||
| output: | ||
| tax_free_childcare_benefits_amount: 2000 | ||
|
|
||
| - name: Eligible disabled child | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_eligible: true | ||
| is_child: true | ||
| is_disabled_for_benefits: true | ||
| output: | ||
| tax_free_childcare_benefits_amount: 4000 | ||
|
|
||
| - name: Not eligible due to not being child | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_eligible: true | ||
| is_child: false | ||
| is_disabled_for_benefits: false | ||
| output: | ||
| tax_free_childcare_benefits_amount: 0 | ||
|
|
||
| - name: Not eligible despite being disabled child | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_eligible: false | ||
| is_child: true | ||
| is_disabled_for_benefits: true | ||
| output: | ||
| tax_free_childcare_benefits_amount: 0 |
51 changes: 51 additions & 0 deletions
51
..._uk/tests/policy/baseline/gov/hmrc/tax_free_childcare/tax_free_childcare_eligibility.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,51 @@ | ||
| # Tests for tax_free_childcare_overall_eligible | ||
| - name: All conditions met | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_child_age_eligible: true | ||
| tax_free_childcare_meets_income_requirements: true | ||
| tax_free_childcare_program_eligible: true | ||
| tax_free_childcare_work_condition: true | ||
| output: | ||
| tax_free_childcare_eligible: true | ||
|
|
||
| - name: Fails age condition only | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_child_age_eligible: false | ||
| tax_free_childcare_meets_income_requirements: true | ||
| tax_free_childcare_program_eligible: true | ||
| tax_free_childcare_work_condition: true | ||
| output: | ||
| tax_free_childcare_eligible: false | ||
|
|
||
| - name: Fails income condition only | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_child_age_eligible: true | ||
| tax_free_childcare_meets_income_requirements: false | ||
| tax_free_childcare_program_eligible: true | ||
| tax_free_childcare_work_condition: true | ||
| output: | ||
| tax_free_childcare_eligible: false | ||
|
|
||
| - name: Fails work condition only | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_child_age_eligible: true | ||
| tax_free_childcare_meets_income_requirements: true | ||
| tax_free_childcare_program_eligible: true | ||
| tax_free_childcare_work_condition: false | ||
| output: | ||
| tax_free_childcare_eligible: false | ||
|
|
||
| - name: Fails all conditions | ||
| period: 2025 | ||
| input: | ||
| tax_free_childcare_child_age_eligible: false | ||
| tax_free_childcare_meets_income_requirements: false | ||
| tax_free_childcare_program_eligible: false | ||
| tax_free_childcare_work_condition: false | ||
| output: | ||
| tax_free_childcare_eligible: false | ||
|
|
91 changes: 91 additions & 0 deletions
91
...ests/policy/baseline/gov/hmrc/tax_free_childcare/tax_free_childcare_income_condition.yaml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,91 @@ | ||
| # Tests for age under 18 bracket (threshold: £1,331 quarterly) | ||
| - name: Under threshold for age 15 with low income and no other income sources - ineligible | ||
| period: 2025 | ||
| input: | ||
| age: 15 | ||
| total_income: 5000 | ||
vahid-ahmadi marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| private_pension_income: 0 | ||
| savings_interest_income: 500 | ||
| dividend_income: 0 | ||
| property_income: 0 | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: false | ||
|
|
||
| # Tests for age 18-20 bracket (threshold: £1,788 quarterly) | ||
| - name: Under threshold for age 19 - ineligible | ||
| period: 2025 | ||
| input: | ||
| age: 19 | ||
| total_income: 7000 # £1,750 quarterly | ||
| private_pension_income: 0 | ||
| savings_interest_income: 0 | ||
| dividend_income: 0 | ||
| property_income: 0 | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: false | ||
|
|
||
| - name: At threshold for age 18 - eligible | ||
| period: 2025 | ||
| input: | ||
| age: 18 | ||
| total_income: 4152 | ||
| private_pension_income: 0 | ||
| savings_interest_income: 0 | ||
| dividend_income: 0 | ||
| property_income: 0 | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: false | ||
|
|
||
| # Tests for age 21+ bracket (threshold: £2,379 quarterly) | ||
| - name: Under threshold for age 22 - ineligible | ||
| period: 2025 | ||
| input: | ||
| age: 22 | ||
| total_income: 9000 # £2,250 quarterly | ||
| private_pension_income: 0 | ||
| savings_interest_income: 0 | ||
| dividend_income: 0 | ||
| property_income: 0 | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: false | ||
|
|
||
| - name: age 18 - eligible | ||
| period: 2025 | ||
| input: | ||
| age: 18 | ||
| total_income: 9516 # £2,379 quarterly | ||
| private_pension_income: 0 | ||
| savings_interest_income: 0 | ||
| dividend_income: 0 | ||
| property_income: 0 | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: true | ||
|
|
||
| # Tests with investment income | ||
| - name: Above threshold but with investment income making eligible income below threshold - ineligible | ||
| period: 2025 | ||
| input: | ||
| age: 22 | ||
| total_income: 12000 | ||
| private_pension_income: 3000 | ||
| savings_interest_income: 500 | ||
| dividend_income: 1000 | ||
| property_income: 500 | ||
| # Net eligible income: 7000 (£1,750 quarterly) | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: false | ||
|
|
||
|
|
||
| # Test age boundary cases | ||
| - name: over 100k | ||
| period: 2025 | ||
| input: | ||
| age: 18 | ||
| total_income: 217152 | ||
| adjusted_net_income: 217152 | ||
| private_pension_income: 0 | ||
| savings_interest_income: 100 | ||
| dividend_income: 0 | ||
| property_income: 0 | ||
| output: | ||
| tax_free_childcare_meets_income_requirements: false | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.