pippyn / Home-Assistant-Sensor-Afvalbeheer

Provides Home Assistant sensors for multiple Dutch and Belgium waste collectors
Apache License 2.0
286 stars 87 forks source link

stopped working suddnely? #423

Closed dawauz closed 10 months ago

dawauz commented 11 months ago

Hi, it worked long time very good but, but suddenly it stopped working.

Deze fout is ontstaan door een aangepaste integratie.

Logger: homeassistant
Source: custom_components/afvalbeheer/API.py:468
Integration: Afvalbeheer (documentation)
First occurred: 28 november 2023 om 17:50:39 (1 occurrences)
Last logged: 28 november 2023 om 17:50:39

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/config/custom_components/afvalbeheer/API.py", line 143, in async_update
    await self.collector.update()
  File "/config/custom_components/afvalbeheer/API.py", line 501, in update
    r = await self.hass.async_add_executor_job(self.__get_data)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/afvalbeheer/API.py", line 468, in __get_data
    for address in json_response_data["customData"]["addresses"]:
                   ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
KeyError: 'customData'

Wat could this be, how to solve?

pippyn commented 11 months ago

I'm sorry to hear it stopped working. Can you also give me your config?

dawauz commented 11 months ago

Well, I restarted home-assistant and its working again.