Repository navigation
Conversation
…e was attained Since 1 April 2021, SI 2006/214 Sch 3 para 1 (as amended by SI 2021/188; NI: SR 2006/406 Sch 4 para 1) gives the lower pension-age personal allowance to a single claimant or lone parent who attained pensionable age on or after that date, and to a couple both of whom did: £238.00 and £363.25 a week in 2026-27, against £256.00 and £383.35 for earlier cohorts. PolicyEngine applied the higher rate to everyone. - state_pension_age_date: the day each person attains State Pension age, as a YYYYMMDD number, from the Pensions Act 1995 timetable. state_pension_age now derives from it (same results; the timetable logic lives in one place). - housing_benefit_attained_pension_age_before_cutoff and the cutoff and lower-rate parameters (2021-22 to 2026-27 from SI 2021/188 and the Up-rating Orders 2022-2026). - England's pensioner Council Tax Reduction has the same split (SI 2012/2885 Sch 2 para 1, amended by SI 2021/29); Scotland and Wales keep one rate. - YAML boundary tests, a differential test of the attainment day against the statute for every birth date, and property tests of the cohort rule. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Explain why the mixed-age couple gap cannot arise for pension-age Housing Benefit in law, and why PolicyEngine gives such units the lower rate; add the same note for England's CTR rows (2) and (5). - Cite where "pensionable age" is defined (SSCBA 1992 s.122(1), applied by the Interpretation Act 1978 s.11) and why dates are compared as integers. - CTR reads the country from the benefit unit's household, as the CTR award formula does. - Test the lower rates and cutoff against the statute's table for 2021-22 to 2026-27, and England's CTR rate for a mixed-age couple. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Response to the independent review (Opus, subfleet job 20260930-083145-review-1913), addressed in f159ff4:
Tests after the changes: the cohort property file (40), #1899's attainment-date differential (13 years), and the HB, CTR, PC and SPA YAML folders (130 in the last run) all pass. |
Para 17(1) and 9(1) add £17.10 where net earnings "equal or exceed" the other disregards, the childcare charges and £17.10. Net earnings are float32, so exactly £1,149.20 (£5 + £17.10 a week) was held as £1,149.19995 and failed the test. The comparison is now in pence, and new cases pin £1,149.20 (single, 30 hours) and £2,189.20 (lone parent, 16 hours) as granted and a penny below each as not. The end-to-end pension-age cases are aged 72 and set the applicable amount (£256 x 52) as an input. SI 2006/214 Sch 3 para 1(1) gives £256 only to a claimant who reached pensionable age before 1 April 2021, and £238 to one who reached it later; #1913 models that split. The working-age case asserts housing_benefit_entitlement, which #1910's 2026 abolition scaling does not change. The disabled-worker case is labelled as a model limitation: the disability premium also brings in Sch 4 para 3's £20 in place of £5, which is not modelled. A new case pins the is_adult proxy counting an 18-year-old young person's earnings and hours (the law excludes them) until #1896 replaces it. The net earnings documentation names the provisions that set the tax deducted (213 regs 36(3) and 39(1); 214 regs 36(2) and 40(1)), calls the proportional attribution a lower bound for employees, and says what the proxy counts. The changelog fragment is a bullet. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Reviewed: not ready (stacked on #1899, no CI). The code itself is approve-with-nits. The split matches the law. HB has the (b) and (c) rates in SI 2006/214 Sch 3 para 1, and Northern Ireland's SR 2006/406 Sch 4 Part I has the same rates. England's CTR splits the same way (SI 2012/2885 Sch 2 para 1, amended by SI 2021/29 for schemes from 2021-22). Scotland (SSI 2012/319 Sch 1 para 2) and Wales (WSI 2013/3029 Sch 2 para 1) keep the single £256 / £383.35 rate.
Verified: I read the current Sch 3 para 1 HB text and the England, Scotland, Wales and NI equivalents, and checked the SI 2021/29 and SI 2021/188 commencement. Tests at f159ff4: 32 new YAML; 77 pytest (cohorts and State Pension age); 174 YAML across the HB, CTR and Pension Credit folders. All pass. CI: none reported. |
|
Follow-up review (GPT-6.1 Sol, subfleet job 20260930-114706-rereview2-1925-1913) at f159ff4:
Plan once #1899 and #1925 have merged:
The current impact table already uses a base that includes #1925's rates (stated in the body). |
… household Main's new Pension Credit carer-income and England CTR tests use pensioners aged 70 in 2026, who reached State Pension age after 1 April 2021 and so get the lower allowance under this PR. Their arithmetic assumes the higher rate, so they now use pensioners aged 72 (State Pension age reached in 2019). The reported household's £47.68 relied on a £365.20 income disregard that main's Housing Benefit earnings-disregard fix (#1908) removed: with no earnings there is no disregard. Its HB at the lower rate is now nil; a council-tenant case with £12,000 rent shows the 608.40 gap. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
state_pension_age.py takes main's version (birth_instant and the shared pensionable-age helper). The HB and CTR applicable amounts keep this PR's cohort amounts under main's pension_age_regulations and pensioner switches. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e_pension_age state_pension_age_date now takes the day of birth from birth_instant, as state_pension_age does, so a given date_of_birth is respected. A differential test checks that the age implied by the attainment date is state_pension_age. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main now puts a mixed-age couple entitled to Universal Credit in the working-age tables (HB reg 5; CTR pensioner test). The mixed-age cohort tests set the pension-age switch, as for a protected couple with no Universal Credit. Main's new England CTR tests with pensioners aged 70 now use pensioners aged 72, who reached State Pension age in 2019, since their arithmetic assumes the higher allowance. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- test_housing_benefit_pension_age_cohorts: the property tests now set the pension-age HB and CTR switches from the statute, so a mixed-age couple that main would put on Universal Credit still tests the cohort rule. - test_state_pension_credit_qualifying_age: from April 2021, England's pension-age CTR allowance can be either rate, so the consumer check accepts the lower rate too (SI 2012/2885 Sch 2 para 1). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…cohorts council_tax_reduction_applicable_amount takes main's is_council_tax_reduction_lone_parent and single definitions, with this PR's cohort amounts after them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… fixes - test_housing_benefit_pension_age_cohorts: STATUTE_HIGHER_RATES holds SI 2006/214 Sch 3 para 1(1)(b)/(2)(b) for 2021-22 to 2026-27, now that #1925 set them to the published amounts, so both rates are hard-coded from law. - From #1925's review: the rates fixture header and test docstring say 2026-27 has only its own edition so far (and name UC's 2021-22 exception), and a CTR test comment shows 7,199.40 and 1,173.56. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
vahid-ahmadi
left a comment
There was a problem hiding this comment.
Fine once main is merged in and CI's Test job is green. The law and the code are right.
@MaxGhenis, round 2, at 7e2c1f0d. Since my 1 October review (at f159ff4), #1899, #1925, #1909 and #1938 have all merged, and the branch now sits on main. My round-1 items 1, 2 and 5 are resolved:
- the branch has a real base and CI runs;
- the #1909 and #1938 fixtures are on main with 72-year-olds;
- the 2025 lower couple rate (£346.60) now matches main's minimum guarantee.
-
should (CI). The Test job at this head fails one case:
test_dataframe_dataset.py::test_an_exported_frame_loads_back_and_exports_itself. The re-exported frame has 38 columns, where 18 were expected: it gains*_id__2026to*_id__2029. The same example also fails on the base commit (main4dfc979f) without this PR. It passes on main714b1438and on this head merged with main, so this comes from the base, not this PR.git merge-treeagainst main is clean. Merging main in and re-running CI should clear it. -
nit (still open from round 1)
housing_benefit_attained_pension_age_before_cutoff.py:7-14. In the household calculator a whole age with nomonths_since_last_birthdayplaces the birthday at the middle of the year of age. So a woman aged 71 in 2026 gets an attainment date of 6 April 2021 and the lower rate (£238.00), although about half that cohort attained before the cutoff.state_pension_age_datementionsmonths_since_last_birthday; this variable's documentation should say the whole-age result too. -
nit (still open from round 1)
council_tax_reduction_applicable_amount.py:46-48. "as for Housing Benefit" reads as if the law settles it. For England's CTR it doesn't. SI 2012/2885 reg 3 has no 2019-style mixed-age bar, so a pensioner couple where one member is under pensionable age and the other attained it after 1 April 2021 is a real case. Sch 2 para 1 rows (2) and (5) don't cover it. Say the lower rate is a modelling choice. -
nit.
docs/book/programs/gov/dwp/housing-benefit.ipynbis also changed by #1910 and #2089. Whichever merges second will need a notebook merge.
What I checked
- I read SI 2012/2885 Sch 2 para 1 as revised (SI 2026/27 amounts: rows (1)/(4) £256.00/£238.00, rows (2)/(5) £383.35/£363.25).
- I checked the
aged_from_cutoffvalues for 2021-22 to 2026-27 against main's minimum guarantee for those years. They match. - I hand-checked by date of birth:
- The YAML boundary cases: 71 years and 6.19 months at 6 October 2026 is born 31 March 1955, so State Pension age at 66 falls on 31 March 2021.
- The council tenant: 0.65 × (256 − 238) × 52 = £608.40, which equals £3,418.70 − £2,810.30.
- I set up a fresh uv env at this head and ran:
- The 9 changed YAML files: 123 passed.
- The 4 changed pytest files plus the dataframe test: 1,424 passed, 66 skipped, and 1 failed (the item 1 case).
ruff checkandruff format --checkon the 8 changed Python files: clean.
- I ran the same YAML (123 passed) and the cohort and published-rates pytests (1,337 passed) on this head merged with main
714b1438. - I made
housing_benefit_attained_pension_age_before_cutoffalways true. 11 of the 22 new HB and CTR allowance cases then fail, so the tests catch the change. - I ran the dataframe case on the base
4dfc979f, on this head, on main and on the merged tree (item 1). - No overlap with #1820, #1855, #1864, #2184, #2187, #2189, #2193 or #2382.
- I couldn't check: CI after a main merge, or a dataset re-run of the impact table.
🤖 Generated with Claude Code
test_state_pension_credit_qualifying_age keeps main's HB benefit-cap check and this PR's two-rate England CTR check. 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: 4 (thresholds in Notes
Moves flagged for review
Spending by benefit and service
Caseloads
Government balance, each component counted once
Model totals
Household income totals
Poverty rates
People in poverty
Inequality
Mean household net income in each side's own deciles
Standard reform costings (change in gov_balance)
Household net income by decileMean change in household net income per household, and as a share of the decile's base income; households stay in the base run's deciles.
No change in any year: receipts by tax head; components the model counts twice; population; standard reforms: change in each reform's target. Checks failing on both base and head (1)
Counted-once checkEach of 84 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
Components the model counts twice: 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
|
Summary
Since 1 April 2021 the pension-age Housing Benefit personal allowance has had two rates. The rate depends on when the claimant, or a couple's members, attained State Pension age. PolicyEngine UK applied the higher rate to every pension-age benefit unit, so it overstated the applicable amount by £18.00 a week (£20.10 for a couple) in 2026-27 for everyone who reached State Pension age on or after that date.
Source: SI 2006/214 Sch 3 para 1, as amended by SI 2021/188, with amounts set by the Social Security Benefits Up-rating Order 2026 (SI 2026/148). The Northern Ireland regulations, SR 2006/406 Sch 4 para 1, carry the same rates. The lower rate equals the Pension Credit standard minimum guarantee. SI 2021/188's explanatory note describes the gap as the "savings credit uplift", kept only for people who already had it.
Reported example (2026): a 70-year-old with a £30,000 State Pension. The report's figures (£656.08 at the higher rate, £47.68 at the lower) included a £365.20 income disregard that
mainhas since removed (#1908: with no earnings there is no earnings disregard). Onmain's income rules, with £9,000 private rent, HB is £418.70 at the higher rate and nil here. As a council tenant with £12,000 rent, HB is £3,418.70 at the higher rate and £2,810.30 here. The difference is 0.65 × (256 − 238) × 52 = £608.40.Builds on #1899 (merged), which sets State Pension age from date of birth: the cohort test needs the day each person attained State Pension age. The DWP rates PR #1925 (merged) set the 2025-26 higher rates to the enacted £244.40 / £366.00.
Changes
state_pension_age_date(new, Person): the day the person attains State Pension age, written as a YYYYMMDD number. It reads the date of birth asstate_pension_agedoes (birth_instant, so a givendate_of_birthis used) and applies the same timetable, using integer date arithmetic so no rounding can move a day.state_pension_ageitself is unchanged (main's version).housing_benefit_attained_pension_age_before_cutoff(new, BenUnit): whether any member attained State Pension age before the cutoff.gov.dwp.housing_benefit.allowances:pension_age_cutoff: 20210401.{single,couple,lone_parent}.aged_from_cutoff: the (c) rates for 2021-22 to 2026-27, each year cited to its source. 2021-22 comes from SI 2021/188 reg 2(3). 2022-23 to 2025-26 come from the point-in-time Sch 3, set by the Up-rating Orders SI 2022/292, 2023/316, 2024/242 and 2025/295. 2026-27 comes from SI 2026/148.agedrates.housing_benefit_applicable_amountpicks the (b) or (c) rate per unit.council_tax_reduction_applicable_amount) reuses the HB allowances:This PR doesn't touch the existing
agedfiles. Their 2025-26 values and references are corrected in the companion DWP rates PR, #1925.Invariants (tested)
For every pension-age single person or couple, in every year:
reference_attainment_day. Otherwise it's the lower rate. This is checked for single people of each sex born every fifth day from 1938, and on both sides of 1 April 1955, in each year 2019-2030. It is also checked for random singles and couples, mixed-age included, under Hypothesis.state_pension_age_dateequals the statute's day for every birth date in Set State Pension age from date of birth, including the rise to 67 #1899's differential set, in each of its 13 years. It is also invariant to the year the person is placed from. The age it implies equalsstate_pension_age(a differential test in 2021, 2026 and 2030).YAML tests cover:
mainnow puts a mixed-age couple on Universal Credit in the working-age tables);mainwhose arithmetic assumes the higher rate (Pension Credit carer income, England CTR, including the claimant-family and Carer Support Payment cases) now use pensioners aged 72, who reached State Pension age in 2019, so they keep testing what they were written for.state_pension_age_dateat each rule of the timetable, including rule (7A).Impact (Enhanced FRS 2024-25)
These are two real runs over the same dataset, fiscal years 2025-26 to 2030-31, on policyengine-core 3.33.2:
main(4dfc979, which includes the DWP rates fix #1925, so the 2025-26 higher rates are the enacted £244.40 / £366.00) and this PR (7e2c1f0). Nothing is scaled or interpolated.The allowance only changes HB for a claim on the taper. In 2026-27, 215k pension-age HB units are in the later cohort; about 27k of them get less HB, and the other 187k get the same HB at either rate. In the microdata, #1899 spreads birthdays within each year of age, so 48.4% of 71-year-olds in 2026-27 attained State Pension age before 1 April 2021. The statute implies 48%: those born 7 October 1954 to 31 March 1955. Totals grow as later cohorts make up more of the pension-age population. Pension-age HB levels on this dataset await the HB calibration rebuild after #1901 (policyengine-uk-data#490), and the size of this change scales with those levels.
Axiom
axiom: uk/regulation/uksi/2006/214/schedule/3 queued TheAxiomFoundation/rulespec-uk#108 | uk/regulation/uksi/2012/2885/schedule/2 queued TheAxiomFoundation/rulespec-uk#378uk/policies/housing_benefit_composed_entitlement_pipeline.yaml) encodes only the (b) rates, from 2026-04-01, and has no cohort input. rulespec-uk#108 is now dispatch-ready with the verbatim law, required outputs and companion tests.🤖 Generated with Claude Code
Reproducer:
policyengine_uk/tests/policy/baseline/finance/benefit/family/housing_benefit/housing_benefit_pension_age_personal_allowance.yaml,policyengine_uk/tests/policy/baseline/gov/dwp/pension_credit/pension_credit_carer_income.yaml::Housing Benefit and Council Tax Reduction no longer fall where Guarantee Credit used to end for a couple whose partner receives Carer's Allowance,policyengine_uk/tests/policy/baseline/gov/dwp/pension_credit/pension_credit_carer_income.yaml::Net income rises where Guarantee Credit now ends for a couple whose partner receives Carer's Allowance,policyengine_uk/tests/policy/baseline/gov/dwp/pension_credit/pension_credit_carer_income.yaml::Pension-age Housing Benefit counts Carer Support Payment but not the Scottish Carer Supplement,policyengine_uk/tests/policy/baseline/gov/dwp/state_pension_age_date.yaml,policyengine_uk/tests/policy/baseline/gov/local_authorities/council_tax_reduction/claimant_family_scheme.yaml::Oxford, working-age head and pension-age sharer each claim under their own scheme