hass-fpl
hass-fpl copied to clipboard
Missing projectedKWH key
When trying to add the integration I get the following error:
File "/config/custom_components/fpl/fplapi.py", line 313, in __getDataFromEnergyService
data["projectedKWH"] = r["CurrentUsage"]["projectedKWH"]
KeyError: 'projectedKWH'
It seems this may be related to an error on my account maybe? But might require better error handling: This is the content of r["CurrentUsage"]:
{'accountNumber': '...', 'premiseNumber': '...', 'exceptionDetails': {'requestStatus': 'Failed', 'resultCode': 'ex022', 'resultInfo': 'Processing Error'}, 'billDiff': '', 'previousBillRead': '', 'currentBillRead': '', 'todayMeterRead': '', 'previousBillAmount': '16.96', 'delMtrReading': '43026', 'recMtrReading': '', 'nextBillDate': 'May 04, 2022'}