Repository navigation
Give children and couples who cannot share a bedroom their own bedrooms in the LHA size criteria - #2080
Give children and couples who cannot share a bedroom their own bedrooms in the LHA size criteria#2080MaxGhenis wants to merge 3 commits into
Conversation
…ms in the LHA size criteria UC Regs 2013 Sch 4 para 12(6), (6A), (8), (9)(c)-(d) and HB Regs 2006 / HB (SPC) Regs 2006 reg 13D(3)(za), (zb), (ba) and closing words. A child who cannot share is taken out of the children's pairing and has a room of their own; a couple one of whom cannot share has a bedroom each. Housing Benefit allows these bedrooms only where the dwelling has them (num_bedrooms; assumed where not reported). New input cannot_reasonably_share_bedroom_due_to_disability. In force from 4 December 2013 (children) and 1 April 2017 (couples); attendance allowance only at the higher rate before 27 January 2025 (SI 2025/3). Fixes #2069. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The property generator now flags none, the first or both adults of a couple, so the Housing Benefit count of one further bedroom per occupier couple, however many members qualify, is exercised. Adds the matching YAML case for a non-dependant couple. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Coordination with #2084 (UC claim by a member of a couple as a single person, UC Regs 2013 reg 3(3)). UC Sch 4 para 12's disabled person condition applies where a renter "would ... be expected to share a bedroom with a joint renter". Where a member of a couple claims UC as a single person, the other member is not a joint renter. They are not a non-dependant either (Sch 4 para 9(2)(b)), and the renter has one bedroom (para 10(1)(a)). So that couple gets no extra room for not being able to share. That PR adds |
Invariant 8 always builds a couple from another family and flags one or both members: the couple's own claim gains one bedroom under each scheme, and the household head's family one Housing Benefit bedroom when the couple are occupiers it counts. A mutation that counted a bedroom per qualifying member survived the reference test's 25 examples; this test pins it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
#2062 is now on This PR still adds formulas that read the raw flag:
Each needs to read the resolved head instead:
|
juaristi22
left a comment
There was a problem hiding this comment.
Program review
Base repository: PolicyEngine/policyengine-uk
PR number: 2080
Reviewed head SHA: 4e7cfd7
Merge base SHA: 1f3ce21
Mode: full
Scope: All 18 changed disability cannot-share LHA bedroom paths and affected UC/HB category, rent-cap and award dependencies; inherited parent audit and private impact excluded
Source manifest: /private/tmp/policyengine-command-runs/881387a1b745/pr2080-hb1141-review-20261027-review-sources.json
Review status: PARTIAL
Source Documents
- authorized-1.original — cached original.
- authorized-4.original — cached original.
- authorized-5.original — cached original.
- authorized-6.original — cached original.
- authorized-9.original — cached original.
- authorized-11.original — cached original.
- authorized-18.original — cached original.
- authorized-19.original — cached original.
- authorized-1.original — cached original.
- authorized-2.original — cached original.
- authorized-3.original — cached original.
- authorized-4.original — cached original.
- authorized-pdf-1.original — cached original.
Critical
None.
Should Address
None.
Suggestions
None.
Evidence Gaps
- CODE G1 — Exact-head execution remains unverified: captured matching-head CI is null, and local imports, collection, 27 new YAML cases, eight properties and affected UC/HB final-award regressions were NOT RUN. Static parameter/date/entity/oracle traces do not establish their combined runtime behavior. Qualified matching-head CI or focused integrated execution is needed; author-reported results are not reviewer execution.
- POLICY-G1 — Historical UC AFIP inclusion for 2017–24 remains unresolved: the broad regulation 2 attendance-allowance definition must be reconciled with the former paragraph 12(6A) higher-rate qualifier. The acquired amendment and current DWP guidance do not conclusively settle that historical interaction; the older-guidance URL redirected to a current edition. This is missing qualification, not a confirmed wrong rule.
- Role checks incomplete: pr2080-hb1141-review-20261027-review-code.md; see recovered report.
- Role checks incomplete: pr2080-hb1141-review-20261027-review-policy.md; see recovered report.
Notes
- No introduced implementation or policy defect was confirmed in the reviewed change. The scheme-specific child/couple allocation, HB physical-bedroom proviso, principal dates and neutral defaults have source-supported static results. The two material checks above prevent approval.
- The pre-effect parameter-access question was resolved by CODE using the owned UK backdating helper: earliest leaves are supplied from 2015, while the in-effect masks stay false. No supported-2015/16 exception was established; this is not an additional finding or evidence gap. No model execution or pre-2015 support is claimed.
- The inherited Scottish working-age CTR adoption-mask issue already reported on PR2030 is parent context. This review does not relabel it an introduced PR2080 defect or certify the whole stack. Private survey judgement/bedroom coverage, default assumptions, Scottish benefit mapping, upper-bound population counts, calibration and adoption remain unverified.
- Eight exact prior official originals/derivatives were reused with explicit hash/applicability qualification; five genuinely missing official originals were acquired. Old PR2030 originals and its closed source window remain unchanged. Current guidance is not backdated to 2024.
- The 62.730-second scope phase includes dispatch/coordinator overhead and missed its 60-second aim; original wall time and role/source clocks are retained. Parallel review timing includes dispatch overhead and overlaps the scope phase; these spans must not be summed. The first cleanup inspection guessed a receipt key and stopped before any git command; normal cleanup then completed using the actual schema.
- Generic partial-role aliases added by the assembler refer to the two specific material gaps above. They are not four distinct missing checks.
Validation Summary
Local tests, country/Core imports, collection, model execution and environment work: NOT RUN. Exact-head hosted CI was null. CODE inspected all 18 paths, all 927 YAML lines and the 692-line property module, traced final UC/HB award consumers and parsed 12 changed Python files as AST. POLICY bound 13 official originals/full-text derivatives (8 reuses, 5 new); source window 179.231236/300s CLOSED and manifest checker0. One official DWP PDF was fully text-extracted, with relevant pages inspected and physical page22 rendered; its current edition does not establish historical 2024 guidance. Both roles finished within 600s. Snapshot removed normally after both DONE; hub retained. No private/log/artifact reads, author edits or issue work.
Timing
setup seconds: 75.15s; scope seconds: 62.73s; parallel review seconds: 462.02s; policy role seconds: 348.07s; code role seconds: 423.94s; adjudication seconds: 0.00s; consolidation cleanup seconds: 85.93s; elapsed seconds: 663.58s; source acquisition window seconds: 179.23s
Review Severity
COMMENT. Open findings: 0 critical, 0 should address, 0 suggestions.
Fixes #2069. Stacked on #2016 (
lha-nondep-children-foster-rooms), which is stacked on #2010 → #2006 → #1896. CI runs once it is retargeted tomain.What changes
The LHA size criteria now give bedrooms to children and couples who cannot share a bedroom because of disability. Until now both the UC and HB variables documented these rooms as "not modelled".
New input.
cannot_reasonably_share_bedroom_due_to_disability(Person, default false) records the decision maker's or local authority's judgement. For a child it means the child cannot share with another child; for a member of a couple, with the other member.Children who cannot share (
is_child_who_cannot_share_bedroom): under 16, on the DLA care component at the middle or highest rate, and flagged.bedrooms_for_childrengains acannot_sharemask. Each counted child so marked has a room of their own, and the other children are paired as before. A room is therefore added only where the child would otherwise share.Couples, one of whom cannot share (
is_member_of_couple_who_cannot_share_bedroom): the claimant or partner of a couple, on attendance allowance, AFIP, DLA care at the middle or highest rate, or PIP daily living, and flagged.HB dwelling condition (13D(3), closing words). These bedrooms count only so far as the dwelling has bedrooms beyond the entitlement if everyone could share, including the (3A)/(3B) rooms. The dwelling's bedrooms come from
num_bedrooms. When it is 0, the default meaning "not reported", the room is assumed. The FRS's BEDROOM6 is always 1-6, but the released enhanced FRS does not carry it.Variables
LHA_cannot_share_bedrooms(UC) is included inLHA_additional_bedrooms.housing_benefit_LHA_cannot_share_bedrooms(HB) is added inhousing_benefit_LHA_allowed_bedrooms, after a new helperhousing_benefit_bedrooms_if_able_to_share.Dates
receives_higher_rate_attendance_allowance.Law checked
Revised texts were fetched from legislation.gov.uk on 2026-10-01, and the amending SIs were read as made (2013/2828, 2017/213, 2025/3). Notes and quotes:
~/reviews/lha-disabled-cannot-share-2026-10-01/law/LAW.md(local).legislation.gov.uk's revised text of 13D(3) has editorial errors in both HB instruments:
The model follows the amending SIs.
Judgement calls
num_bedrooms, so in the microsimulation the HB condition never binds.Invariants (property tests in
tests/test_lha_bedroom_young_people_properties.py)The brute-force reference (invariant 5) now covers the new rules:
num_bedroomsdrawn from {unreported, 1..6}.New properties:
Invariants 1-4 (from #2010/#2016) now run on populations that include children and couples who cannot share.
Tests
YAML:
LHA_cannot_share_bedroom.yaml, 26 cases.Policy YAML: the new file passes (27 cases). Every case sets the new input, which the base does not have. The full family suite and the policy suite run before this leaves draft.
Property tests: all 7 then-existing properties pass at b2942e3; invariant 8 (4e7cfd7) passes (exit 0; the host was heavily loaded, so the run took ~25 minutes). This also answers Count other families' children and add the foster and overnight-care bedrooms in the LHA size criteria #2016's request to run its properties on a merge of its 1f3ce21 head. Mutation checks: four deliberately broken copies of the code (scratch copies), each run against invariants 5-8. Every one fails at least one property:
The couple mutant survived the reference test's 25 examples, so invariant 8 was added to pin that effect exactly.
Impact
Three real microsimulation runs of the released enhanced FRS 2024-25 (uk-data 1.57.4; h5 sha256 03fe15e40a4c), year 2026. All figures are aggregates. A cell backed by fewer than 10 distinct survey households is suppressed, and so is any figure that would reveal such a cell by subtraction.
As the data stand, nothing changes. The survey does not record the cannot-share judgement, so the new input is false for everyone.
num_bedrooms, so the HB dwelling condition never binds in the microsimulation.Upper bound. A third run gives every person the judgement, so the rooms go to everyone with a qualifying benefit. It shows how far the rule could reach. It is not an estimate: in practice the decision maker or local authority grants the judgement case by case.
Scripts:
~/reviews/lha-disabled-cannot-share-2026-10-01/impact/(dump_sim.pywith anallmode,compare.py,cannot_share_extra.py; outputsefrs_compare_upper_2026.out,efrs_extra_upper_2026.out).axiom: TheAxiomFoundation/rulespec-uk#411 queued (addendum TheAxiomFoundation/rulespec-uk#411 (comment)) | TheAxiomFoundation/rulespec-uk#406 queued (addendum TheAxiomFoundation/rulespec-uk#406 (comment); pointer on TheAxiomFoundation/rulespec-uk#357)
🤖 Generated with Claude Code