Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/uprate-electricity-and-gas-consumption.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Uprate `electricity_consumption` and `gas_consumption`. Both variables declare CPI uprating, but were absent from `uprating_indices.yaml`, so they returned identical values in every year while every other consumption variable on the same index rose. This also restores the documented identity `domestic_energy_consumption == electricity_consumption + gas_consumption`, which held in the base year but diverged thereafter because only the combined variable was uprated.
2 changes: 2 additions & 0 deletions policyengine_uk/data/uprating_indices.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,14 @@ gov.economic_assumptions.yoy_growth.obr.consumer_price_index:
- communication_consumption
- domestic_energy_consumption
- education_consumption
- electricity_consumption

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Four more dataset columns declare uprating but are missing from this list, and I measured them flat 2024 → 2027 on the same dataset:

  • water_and_sewerage_charges (declares indices.ofwat.water_bills) — 375.34 in both years
  • housing_service_charges (indices.obr.lagged_average_earnings) — 91.89
  • pension_contributions_via_salary_sacrifice (indices.obr.average_earnings) — 417.07
  • rail_usage (gov.dft.rail.ridership_index) — 483.10

Also savings_interest_income declares indices.ons.household_interest_income, but this file applies per_capita.gdp to it.

Since the class attribute is never read, the durable fix is a code-health test (natural home: policyengine_uk/tests/code_health/) asserting that every variable declaring uprating appears in this file under the matching index. Two of the four above point at indices that may have no yoy_growth parameter yet, so they probably need their own PR — but the guard would make the gap visible instead of silent.

- esa_contrib_reported
- esa_income_reported
- food_and_non_alcoholic_beverages_consumption
- free_school_fruit_veg
- free_school_meals
- free_school_milk
- gas_consumption
- health_consumption
- household_furnishings_consumption
- housing_benefit_reported
Expand Down
Loading