Model/datatypes/epc/schema
Khalim Conn-Kowlessar 361abc1202 fix(mapper): handle 'ND' multiple_glazing_type on RdSAP-Schema-20.0.0
`_synthesise_20_0_0_sap_windows` passed `schema.multiple_glazing_type`
straight into `_api_cascade_glazing_type`, which raised UnmappedApiCode on
the "ND" (Not Defined) string that the 20.0.0 corpus lodges alongside the
1-8 integer codes — failing the mapper-coverage guard on every ND-glazed
20.0.0 cert. Mirror the existing 18.0/19.0/17.x seams: route integer codes
through the cascade, fall the "ND" string back to the DG-modal default
(cascade code 2 → daylight g_L 0.80). Also corrects the 20.0.0 schema
field type `int` → `Union[int, str]` to match the data (as 18.0 already
does), which keeps the isinstance guard pyright-clean.

Pre-existing failure (present before this branch's recent commits), not in
the handover regression gate. Fixes all 15 RdSAP-Schema-20.0.0 ND certs;
test_mapper_corpus 6002/6002 pass. pyright net-zero.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-15 06:43:55 +00:00
..
tests Slice 44: flat_roof_insulation_thickness mapper fix — surface lodged value on SapBuildingPart 2026-05-24 15:28:10 +00:00
__init__.py first draft dataclasses with loading tests 2026-04-10 11:33:17 +00:00
common.py first draft dataclasses with loading tests 2026-04-10 11:33:17 +00:00
helpers.py slice 10.5: PhotovoltaicArray on SAP10 schema + EpcPropertyData 2026-05-16 16:00:25 +00:00
rdsap_schema_17_0.py Map RdSAP-Schema-17.0 certs to EpcPropertyData 🟩 2026-06-12 12:45:19 +00:00
rdsap_schema_17_1.py Dispatch and map RdSAP-Schema-17.1 certs end-to-end 🟩 2026-06-11 12:21:17 +00:00
rdsap_schema_18_0.py Map Not-Defined glazing code to a valid type for windowless 18.0 certs 🟩 2026-06-11 11:55:46 +00:00
rdsap_schema_19_0.py Map RdSAP-Schema-19.0 certs to EpcPropertyData 🟩 2026-06-12 12:29:36 +00:00
rdsap_schema_20_0_0.py fix(mapper): handle 'ND' multiple_glazing_type on RdSAP-Schema-20.0.0 2026-06-15 06:43:55 +00:00
rdsap_schema_21_0_0.py fix(fabric): honour the gov-EPC lodged per-element U-values (RdSAP §5.1) 2026-06-11 13:51:26 +00:00
rdsap_schema_21_0_1.py fix(fabric): honour the gov-EPC lodged per-element U-values (RdSAP §5.1) 2026-06-11 13:51:26 +00:00