chellow 1716906655.0.0__py3-none-any.whl → 1716928285.0.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of chellow might be problematic. Click here for more details.

@@ -73,7 +73,7 @@ CHARGE_UNITS_LOOKUP = {
73
73
  ELEMENT_LOOKUP = {
74
74
  "10ANNUAL": "standing",
75
75
  "20RS0108": "unrestricted",
76
- "9WANNUAL": "site_fee",
76
+ "9WANNUAL": "site-fee",
77
77
  "20RS0123": "day",
78
78
  "30RS0123": "night",
79
79
  "90ANNUAL": "duos-fixed",
@@ -123,7 +123,7 @@ def _handle_0460(headers, pre_record, record):
123
123
  breakdown[f"{element_name}-days"] += Decimal(parts["days"])
124
124
 
125
125
 
126
- CONSUMPTION_UNITS_LOOKUP = {"KWH": "kwh", "KVA": "kva", "KVARH": "kvarh", "KW": "kw"}
126
+ CONSUMPTION_UNITS_LOOKUP = {"KWH": "kWh", "KVA": "kVA", "KVARH": "kVArh", "KW": "kW"}
127
127
 
128
128
  REGISTER_CODE_LOOKUP = {"DAY": "00040", "NIGHT": "00206", "SINGLE": "00001"}
129
129
 
@@ -150,7 +150,7 @@ def _handle_0461(headers, pre_record, record):
150
150
  mpan_core = parse_mpan_core(parts["mpan_core"])
151
151
  headers["mpan_core"] = mpan_core
152
152
  units = CONSUMPTION_UNITS_LOOKUP[parts["units"].strip()]
153
- if units == "kwh":
153
+ if units == "kWh":
154
154
  headers["kwh"] += Decimal(parts["quantity"])
155
155
 
156
156
  prev_read_date_str = parts["prev_read_date"].strip()
@@ -181,14 +181,14 @@ def _handle_0470(headers, pre_record, record):
181
181
  def _handle_1455(headers, pre_record, record):
182
182
  parts = _chop_record(record, ccl_kwh=13, unknown_1=8, ccl_rate=15, ccl_gbp=13)
183
183
  bd = headers["breakdown"]
184
- bd["ccl_kwh"] += Decimal(parts["ccl_kwh"])
185
- if "ccl_rate" in bd:
186
- ccl_rates = bd["ccl_rate"]
184
+ bd["ccl-kwh"] += Decimal(parts["ccl_kwh"])
185
+ if "ccl-rate" in bd:
186
+ ccl_rates = bd["ccl-rate"]
187
187
  else:
188
- ccl_rates = bd["ccl_rate"] = set()
188
+ ccl_rates = bd["ccl-rate"] = set()
189
189
 
190
190
  ccl_rates.add(Decimal(parts["ccl_rate"]) / Decimal("100"))
191
- bd["ccl_gbp"] += Decimal(parts["ccl_gbp"]) / Decimal("100")
191
+ bd["ccl-gbp"] += Decimal(parts["ccl_gbp"]) / Decimal("100")
192
192
 
193
193
 
194
194
  def _handle_1460(headers, pre_record, record):
chellow/models.py CHANGED
@@ -567,7 +567,7 @@ class RegisterRead(Base, PersistentClass):
567
567
  try:
568
568
  return RegisterRead.UNITS_STR[units_str]
569
569
  except KeyError:
570
- raise BadRequest("The units '" + str(units_str) + " isn't recognized.")
570
+ raise BadRequest(f"The units '{units_str}' isn't recognized.")
571
571
 
572
572
  __tablename__ = "register_read"
573
573
  id = Column(Integer, primary_key=True)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: chellow
3
- Version: 1716906655.0.0
3
+ Version: 1716928285.0.0
4
4
  Summary: Web Application for checking UK energy bills.
5
5
  Project-URL: Homepage, https://github.com/WessexWater/chellow
6
6
  Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
@@ -5,7 +5,7 @@ chellow/commands.py,sha256=ESBe9ZWj1c3vdZgqMZ9gFvYAB3hRag2R1PzOwuw9yFo,1302
5
5
  chellow/dloads.py,sha256=5SmP-0QPK6xCkd_wjIWh_8FAzN5OxNHCzyEQ1Xb-Y-M,5256
6
6
  chellow/edi_lib.py,sha256=alu20x9ZX06iPfnNI9dEJzuP6RIf4We3Y_M_bl7RrcY,51789
7
7
  chellow/general_import.py,sha256=l3EHq9zG9Vfl5Ee6XTVrC1nusXo4YGGB4VBmZ_JaJR8,65798
8
- chellow/models.py,sha256=uS4GHh4RF6yD7aSsN4nOC3hdNakHUjW1nVzrhM_79mQ,242736
8
+ chellow/models.py,sha256=l2bFiDgU_Wv6jpyRjAlOKMbO2AEMtka-dTigNFENNeY,242727
9
9
  chellow/national_grid.py,sha256=uxcv0qisHPyzw9AVIYPzsRqwt2XPAcZL-SBR12qcrS0,4364
10
10
  chellow/proxy.py,sha256=cVXIktPlX3tQ1BYcwxq0nJXKE6r3DtFTtfFHPq55HaM,1351
11
11
  chellow/rate_server.py,sha256=fg-Pf_9Hk3bXmC9riPQNGQxBvLvBa_WtNYdwDCjnCSg,5678
@@ -51,7 +51,7 @@ chellow/e/bill_parsers/gdf_csv.py,sha256=ZfK3Oc6oP28p_P9DIevLNB_zW2WLcEJ3Lvb1gL3
51
51
  chellow/e/bill_parsers/haven_csv.py,sha256=0uENq8IgVNqdxfBQMBxLTSZWCOuDHXZC0xzk52SbfyE,13652
52
52
  chellow/e/bill_parsers/haven_edi.py,sha256=YGPHRxPOhje9s32jqPHHELni2tooOYj3cMC_qaZVPq4,16107
53
53
  chellow/e/bill_parsers/haven_edi_tprs.py,sha256=ZVX9CCqUybsot_Z0BEOJPvl9x5kSr7fEWyuJXvZDcz4,11841
54
- chellow/e/bill_parsers/mm.py,sha256=faCT5ZiMSDgIg5iiqXuL7c_t3PJBaVGvrndxr17A-bw,8528
54
+ chellow/e/bill_parsers/mm.py,sha256=5ChR3uVImZ6pJe_wZFeDkA06uxcVlyWWizwKJnMR_gg,8528
55
55
  chellow/e/bill_parsers/nonsettlement_dc_stark_xlsx.py,sha256=yogXTuQHGRL7IiqvRWr2C9V24ez1j9Yx0128UygPE_k,4723
56
56
  chellow/e/bill_parsers/settlement_dc_stark_xlsx.py,sha256=gKeYMdUO4bVycV8n1lWs5AIfF3bHZLkM6tkasD4rhHs,6239
57
57
  chellow/e/bill_parsers/sse_edi.py,sha256=L85DOfNkqexeEIEr8pCBn_2sHJI-zEaw6cogpE3YyYM,15204
@@ -364,6 +364,6 @@ chellow/templates/g/supply_note_edit.html,sha256=6UQf_qbhFDys3cVsTp-c7ABWZpggW9R
364
364
  chellow/templates/g/supply_notes.html,sha256=WR3YwGh_qqTklSJ7JqWX6BKBc9rk_jMff4RiWZiF2CM,936
365
365
  chellow/templates/g/unit.html,sha256=KouNVU0-i84afANkLQ_heJ0uDfJ9H5A05PuLqb8iCN8,438
366
366
  chellow/templates/g/units.html,sha256=p5Nd-lAIboKPEOO6N451hx1bcKxMg4BDODnZ-43MmJc,441
367
- chellow-1716906655.0.0.dist-info/METADATA,sha256=0u8nBykmCixKsJ9gwZ2VIgj-2Ho1X5kTgovATHvJiuQ,12205
368
- chellow-1716906655.0.0.dist-info/WHEEL,sha256=zEMcRr9Kr03x1ozGwg5v9NQBKn3kndp6LSoSlVg-jhU,87
369
- chellow-1716906655.0.0.dist-info/RECORD,,
367
+ chellow-1716928285.0.0.dist-info/METADATA,sha256=lq5aS6s7xy1rEuw15YFDiVcv3oNv-OeA3IM1cyaKgqc,12205
368
+ chellow-1716928285.0.0.dist-info/WHEEL,sha256=zEMcRr9Kr03x1ozGwg5v9NQBKn3kndp6LSoSlVg-jhU,87
369
+ chellow-1716928285.0.0.dist-info/RECORD,,