Repository navigation
Conversation
Parliament lists maternity allowance among the welfare benefits the cap covers (Welfare Reform Act 2012 s.96(10)(i)); UC Regs 2013 regs 79-80 and HB Regs 2006 regs 75A and 75C count the claimant's and partner's own awards at the amount each scheme counts as income, which is all of it. benefit_cap_welfare_benefits left it out, so a capped family's Universal Credit fell by the allowance before the cap and the cap's reduction fell by the same amount. Add maternity_allowance to CLAIMANT_OR_PARTNER_BENEFITS, correct the documentation (the model has no variable for bereavement allowance, widow's pension or widowed mother's allowance), and add YAML cases and Hypothesis properties: exchange with another counted benefit, coefficient one, a reference written from the regulations, and the whole-model pound-for-pound response inside the cap. Fixes #2784. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The comments, case names and changelog now say that DWP and councils count the claimant's and partner's allowance, and that Parliament lists it among the welfare benefits regulations may cap. No test value changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Councils disregard £15 a week of widowed parent's allowance (HB Regs 2006 Sch 5 para 16(b)) and any tax paid on incapacity benefit (Sch 5 para 1), so the Housing Benefit exchange now draws only contribution-based JSA or ESA and severe disablement allowance, and the written reference sums only the benefits each scheme counts at the award. The Universal Credit exchange keeps all five (UC Regs 2013 regs 66(1)(b), 80(1), (4)). Invariant 4 now holds only where the award absorbs the whole reduction at both amounts, and a named test for a mother of 16 shows what happens once the cap takes Universal Credit to nil. Three YAML cases check the final award input, the 2024-25 year and an entered joint claimant who is not the Housing Benefit partner. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PolicyEngine changed its calculation; DWP and councils counted the allowance all along. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The comments and docstrings now give the counting, exempting and paying to DWP and councils rather than to the cap or the scheme, and two YAML case names and the mother-of-16 test name follow. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… power Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…notes The docstring now says Universal Credit plus the allowance holds still only while the award absorbs the whole excess, no protected floor limits the reduction and DWP deducts the same for debts, and that the tests' families carry no debt deductions. Comments give the Secretary of State and the Treasury their instruments, and DWP its exemptions. The changelog splits its first sentence. No code, input or expected value changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Aggregate impact on certified data: passBase Checks: 0 broken by this change, 1 failing on both sides, 0 fixed. Moves flagged for review: 0 (thresholds in Notes
Moves flagged for reviewNone. Spending by benefit and service
Caseloads
Standard reform costings (change in gov_balance)
Standard reforms: change in each reform's target
Household net income by decileNo household's net income changes in any year. No change in any year: receipts by tax head; government balance, each component counted once; model totals; household income totals; population; poverty rates; people in poverty; inequality; mean household net income in each side's own deciles. Checks failing on both base and head (1)
Counted-once checkEach of 92 components was raised by £1 per unit in 2026-27, and every head of its totals was read household by household: its own head must rise by exactly £1, no other tax head may move, no other benefit may rise, and the model's own total must move by what its heads moved. A head that breaks a rule is measured again twice: with every other head held at its baseline value, and with every other head held at its value after the first £1 while the component rises again. It fails where either still shows the response. 0 failed; 0 were skipped.
Provenance
Dataset: Receipts by tax head: head levels
Spending by benefit and service: head levels
Caseloads: head levels
Government balance, each component counted once: head levels
Model totals: head levels
Household income totals: head levels
Population: head levels
Poverty rates: head levels
People in poverty: head levels
Inequality: head levels
Mean household net income in each side's own deciles: head levels
Standard reform costings (change in gov_balance): head levels
Standard reforms: change in each reform's target: head levels
|
juaristi22
left a comment
There was a problem hiding this comment.
Reviewed 55e015e104f3ad0bc1c07b41e367ef78bb256511. No findings.
Maternity Allowance now enters the cap once for the claimant or partner, with non-dependants excluded. The existing UC income deduction and both final award paths remain consistent with the statutory totals.
93 focused tests passed, including all new properties. A native issue-family check confirms that £6,000 of allowance replaces £6,000 of final UC and leaves household net income unchanged where the full cap reduction applies; the HB case pays £8,753. The documented work-history exemption limitations remain outside this change.
The official provisions and the Maternity Allowance addendum to the queued parity work are covered. Required checks passed at this exact head.
Fixes #2784
What and why
Parliament lists maternity allowance among the welfare benefits whose total the Secretary of State may cap by regulations (Welfare Reform Act 2012 s.96(1), (10)(i)). DWP counts the claimant's and partner's own awards when it caps Universal Credit (UC Regs 2013 regs 79(1), 80(1)), and councils count them when they cap Housing Benefit (HB Regs 2006 reg 75A). Each uses the amount it counts as income (UC reg 80(4); HB reg 75C(4)). DWP counts Maternity Allowance in full as unearned income (UC reg 66(1)(b)(viii)), and councils disregard none of it under HB reg 40 and Schedule 5. DWP and councils grant no cap exemption solely for Maternity Allowance receipt (UC regs 82 and 83; HB regs 75E and 75F).
benefit_cap_welfare_benefitsleft the allowance out, although the model's Universal Credit means test already counted it as unearned income. As the allowance reduced Universal Credit before the cap, the model cut its cap deduction pound for pound until the deduction reached nil. A capped family kept the allowance on top of its capped benefits, up to the size of that deduction.This PR adds
maternity_allowancetoCLAIMANT_OR_PARTNER_BENEFITSinpolicyengine_uk/variables/gov/dwp/benefit_cap_welfare_benefits.py. The model now adds the claimant's and partner's allowance to the total and leaves a non-dependent adult's out, as it does their other benefits. It reads one total for both caps, so it also includes the allowance when it calculates the council's Housing Benefit reduction. The variable's documentation now names the three s.96(10) benefits the model has no variable for: bereavement allowance, widow's pension and widowed mother's allowance.The Secretary of State included Maternity Allowance in UC reg 79(4)(g) as made and in HB reg 75G through SI 2012/2994. Parliament moved the list into s.96(10) in 2016. DWP and councils have counted the allowance since each cap began in 2013, so this fix needs no start date of its own.
In the issue's example, a lone parent of 30 with children of 1, 4 and 7 rents privately for £1,500 a month in Tyneside in 2026-27 and receives £6,000 of Maternity Allowance.
mainuniversal_credit_pre_benefit_capbenefit_cap_welfare_benefitsuc_benefit_cap_reductionuniversal_creditWithout the allowance, the model on both branches takes £5,088.84 off the family's £23,840.64 and pays £18,751.80. With it, the model on this branch pays £12,751.80, so Universal Credit and the allowance together come to the same £18,751.80. On
mainthe model pays £17,840.64, and the family keeps £23,840.64.A woman on Maternity Allowance under s.35 has worked in at least 26 of the 66 weeks before her expected week of confinement (SSCBA 1992 s.35(1)(b)). DWP or a council can then exempt her family for a time under one of two work exceptions, which the model leaves out: the UC grace period (reg 82(1)(b)) and the HB 39-week period (reg 75E(3)).
is_uc_benefit_cap_exempt_earningsandis_housing_benefit_benefit_cap_exempt_working_tax_creditdocument that gap. This PR doesn't add them. Where DWP or a council would leave a family's award uncapped during one of those periods, the model still caps it, and now counts the allowance too.A population estimate would need the Enhanced FRS. The model's reduction changes only for a family that DWP or the council wouldn't exempt under a modelled exception, in which the claimant or partner receives Maternity Allowance and the total with the allowance exceeds the limit.
Invariants
The Hypothesis tests in
policyengine_uk/tests/test_benefit_cap_maternity_allowance_properties.pycheck these for each family Hypothesis draws, on Universal Credit or on Housing Benefit alone, whether a single claimant, either member of a couple, or a non-dependent adult receives the allowance.test_a_mother_of_16_keeps_more_allowance_once_dwp_cuts_her_award_to_nilchecks the edge where the reduction uses up the award. For a mother of 40 with 16 children who owns her home outside London, DWP works out a maximum award of £64,030.56 a year, and she receives £15,368.60 of Child Benefit. With £6,000 of allowance DWP pays her £651.40; with £7,000 it pays nil, because the £57,379.16 reduction exceeds her £57,030.56 award. Universal Credit plus the allowance rises from £6,651.40 to £7,000.Test plan
policyengine_uk/tests/policy/baseline/gov/dwp/benefit_cap/benefit_cap_capped_total.yaml. DWP counts the claimant's allowance and a partner's, and leaves a non-dependent adult's out. A council counts the claimant's allowance when it caps Housing Benefit for a family without Universal Credit. The model works out the issue family's whole Universal Credit award with and without the allowance. Three more cases hold the award before the cap fixed. DWP counts a claimant's £3,000 award rather than the £999 she reported, and counted the allowance in 2024-25. DWP also counts an entered joint claimant's allowance when the council does not treat her as the Housing Benefit partner.ruff format --checkandruff check(0.17.2) on the changed Python files,ruff check --select F811,F821 policyengine_uk, andgit diff --check.changelog.d/2784.fixed.md; the repository's.github/check_changelog_fragments.pypasses it againstmain.Results
benefit_cap_capped_total.yaml: 19 passed.test_benefit_cap_maternity_allowance_properties.py: 5 passed at this head in CI, the four properties (25, 25, 25 and 20 examples) and the mother of 16.Each of seven changes to the fix fails the new tests:
mainAt 4524a28, whose production code this head keeps, the YAML tests in
policyengine_uk/tests/policy/baseline/gov/dwp/benefit_cap/and the nine other YAML files that mention Maternity Allowance passed 318 of 318. Those files cover Universal Credit unearned income and the childcare work condition, the Carer's Allowance overlap, Pension Credit income, the extended childcare and Tax-Free Childcare work conditions, and the Housing Benefit and Council Tax Reduction non-dependant income files.test_disable_simulated_benefits_benefit_cap.py, whose reference imports the changed list, passed 6 of 6 in 1,193 s. This head changes only tests, test comments and the changelog, so those files read the same code.Five property files that give nobody Maternity Allowance didn't finish within the local 25-minute limit:
test_benefit_cap_uc_and_hb_properties.py,test_benefit_cap_specified_benefits_properties.py,test_benefit_cap_lha_scheme_split_properties.py,test_benefit_cap_and_ctr_pension_age_properties.pyandtest_reported_legacy_award_screening.py.The other Python tests that mention Maternity Allowance didn't finish within that limit either:
test_uc_unearned_benefits_properties.py(which checks that Universal Credit after the cap never rises with the allowance for a family already receiving it),test_income_concepts_properties.py,test_uc_incapacity_income.py,test_uc_childcare_work_condition_properties.py,test_carer_overlapping_benefits_properties.py,test_council_tax_reduction_pension_credit_properties.py,test_pension_credit_prescribed_benefits_properties.py,test_wales_childcare_offer_income_sources.py,test_disable_simulated_benefits_winter_heating.pyandtest_program_registry.py. CI runs the full suite.CI passes all of these at this head.
#2812 tracks the £15 a week of widowed parent's allowance that councils disregard, which
benefit_cap_welfare_benefitsstill counts in full.Merging with other branches
git merge-tree --write-tree --name-onlyfinds no conflict between this head and each of:mainat 2da212a; #2007 at 02cc089;fix-2562-esa-abolitionat 509842c;fix-2120-uc-carer-awardsat 4613ac6; #2647 at c98c879; #2756 at c346627; and #2776 at 1d4a3e4.The newer #2007 head 95fbf30 on
hub/2007-r5conflicts with this head in one place, thedocumentationstring ofbenefit_cap_welfare_benefits. Whichever PR lands second keeps both changes to that string.Whichever of this PR and #2007 lands second updates #2007's case
A non-dependant family's Universal Credit counts after the benefit cap. Once the cap counts the non-dependant partner's £6,000 of Maternity Allowance, DWP cuts that family's Universal Credit to £10,890.20, and the council's non-dependant deductions from the claimant's Housing Benefit and Council Tax Reduction fall. The case's comment already works out these figures. The second PR moves them into all three expectations,universal_credit[£0.00, £10,890.20],housing_benefit_non_dep_deductions[£6,232.20, £0.00] andcouncil_tax_reduction_non_dep_deductions[£691.60, £0.00], and rewrites the comment, which still describes a cap that leaves the allowance out.Reproducer
Reproducer: policyengine_uk/tests/test_benefit_cap_maternity_allowance_properties.py::test_total_rises_by_the_couples_allowance_and_never_falls; policyengine_uk/tests/policy/baseline/gov/dwp/benefit_cap/benefit_cap_capped_total.yaml::DWP counts the claimant's own Maternity Allowance in the capped total
axiom: TheAxiomFoundation/rulespec-uk#425 queued
uk/regulations/uksi/2013/376/66.yamlclassifies the allowance as unearned income, and the queued work derives the welfare-benefit total and supplies it to81.yaml, which takestotal_welfare_benefits_entitled_in_reference_periodas an input. An addendum for #425 carries this PR's cases, each in its native assessment period or benefit week. The encoder operator needs approval for a billed signed-encoder run, and must verify the pinned corpus selectors and ingest any missing provisions.🤖 Generated with Claude Code