From 5f29b239f0629533b2e5b1135a808844a580c1d5 Mon Sep 17 00:00:00 2001 From: Tony Locke Date: Tue, 15 Oct 2024 10:49:58 +0100 Subject: [PATCH] MM Parser: Ignore kWh NOCHARGE --- chellow/e/bill_parsers/mm.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/chellow/e/bill_parsers/mm.py b/chellow/e/bill_parsers/mm.py index 41f719f22..10899b0ee 100644 --- a/chellow/e/bill_parsers/mm.py +++ b/chellow/e/bill_parsers/mm.py @@ -172,7 +172,8 @@ def _handle_0461(headers, pre_record, record): mpan_core = parse_mpan_core(parts["mpan_core"]) headers["mpan_core"] = mpan_core units = CONSUMPTION_UNITS_LOOKUP[parts["units"].strip()] - if units == "kWh": + register_code = parts["register_code"].strip() + if units == "kWh" and not register_code.startswith("NOCHARGE"): headers["kwh"] += Decimal(parts["quantity"]) prev_read_date_str = parts["prev_read_date"].strip()