Skip to content

Commit 864b6cf

Browse files
authored
Merge pull request #1054 from PolicyEngine/universal-free-childcare
Edit age condition in universal childcare
2 parents f32131f + 4b3e28c commit 864b6cf

File tree

4 files changed

+16
-5
lines changed

4 files changed

+16
-5
lines changed

changelog_entry.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
- bump: patch
2+
changes:
3+
fixed:
4+
- Bug in universal childcare entitlement.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
description: The Department for Education limits universal childcare entitlement in England to children younger than this age.
2+
metadata:
3+
unit: year
4+
label: universal childcare entitlement child's maximum age
5+
reference:
6+
- title: Childcare Act 2006 - Section 7.19
7+
href: https://www.legislation.gov.uk/ukpga/2006/21/section/19
8+
values:
9+
2015-01-01: 5

policyengine_uk/parameters/gov/dfe/universal_childcare_entitlement/min_age.yaml

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
description: The Department for Education limits universal childcare entitlement in England to children this age or older.
22
metadata:
3-
type: single_amount
4-
threshold_unit: year
5-
amount_unit: hour
3+
unit: year
64
label: universal childcare entitlement child's minimum age
75
reference:
86
- title: Childcare (Early Years Provision Free of Charge) (Extended Entitlement) Regulations 2016 - Regulation 35(3)

policyengine_uk/variables/gov/dfe/universal_childcare_entitlement/universal_childcare_entitlement_eligible.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ def formula(person, period, parameters):
1616

1717
age = person("age", period)
1818
p = parameters(period).gov.dfe.universal_childcare_entitlement
19-
meets_min_age = age >= p.min_age
19+
meets_age_condition = (age >= p.min_age) & (age < p.max_age)
2020
not_compulsory_age = ~person("is_of_compulsory_school_age", period)
2121
# Section 7 of the Childcare Act 2006
2222
# The regulation above limits free early years provision to children under compulsory school age.
23-
return in_england & meets_min_age & not_compulsory_age
23+
return in_england & meets_age_condition & not_compulsory_age

0 commit comments

Comments
 (0)