mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-12 13:29:04 +00:00
Forcing-function guards so a lodged-but-unmapped code surfaces loudly instead of silently taking a wrong-but-plausible default (the class that hid single glazing as U=2.5 until this session). Four silent fallbacks converted to raise on PRESENT-but-unmapped codes, while keeping the legitimate ABSENT (None) defaults: - _api_glazing_transmission: unmapped glazing_type -> UnmappedApiCode (was None -> u_window all-None default 2.5). - _api_cascade_glazing_type: unmapped glazing_type -> UnmappedApiCode (was pass-through -> wrong g-value slot). - seasonal_efficiency: a lodged code/category resolving in neither _SPACE_EFF_BY_CODE nor the category/room-heater fallbacks -> UnmappedSapCode (was blind 0.80 gas-boiler default, which 'catastrophically misrates heat pumps and storage' per the table comment). Data-free calls keep 0.80. - water_heating_efficiency: WHC in no SAP 10.2 Table 4a HW row -> UnmappedSapCode (was blind 0.78). Absent code keeps 0.78. Zero current-corpus impact (909 computed / 0 raises, 56.66% within-0.5 unchanged) — the code/efficiency tables are complete for today's data, so these are guards for the ongoing audit + future data refreshes. Verified the WHC table already covers 908 (multi-point gas) and 950 (HW heat network), so those are NOT unmapped-code bugs. 8 AAA tests, goldens + gate green, pyright net-zero. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| tests | ||
| __init__.py | ||
| demand.py | ||
| ecf.py | ||
| envelope.py | ||
| rdsap_uvalues.py | ||
| sap_efficiencies.py | ||
| schema.py | ||
| transform.py | ||
| ucl.py | ||
| ventilation.py | ||