pippyn / Home-Assistant-Sensor-Afvalbeheer

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

MaxRetryError #508

Open blowk opened 1 month ago

blowk commented 1 month ago

I haven't to be able to run this and getting the following error:

Error occurred while fetching data: ConnectionError(MaxRetryError("HTTPSConnectionPool(host='api.recycleapp.be', port=443): Max retries exceeded with url: /api/app/v1/access-token (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fe6efee7e00>: Failed to establish a new connection: [Errno -2] Name does not resolve'))"))

Does anyone else has the same problem? Do we need to change the access-token?

pippyn commented 1 month ago

What is your config?

blowk commented 1 month ago

Hi

  wastecollector: RecycleApp
  resources:
    - restafval
    - papier
    - pmd
  postcode: 8500
  streetname: Budastraat 
  streetnumber: 52
  builtinicons: 1
  builtiniconsnew: 1
  upcomingsensor: 1
  dutch: 1
  dateformat: '%d-%m-%Y'

The address is an example. It was working before, but today I got this message and wasn't be able to get it right.

pippyn commented 1 month ago

There is definitely an issue with the RecycleApp API. I'll look for an solution asap.

jessedobbelaere commented 1 month ago

Came here to post the same 🙇 Thanks for checking it out!

XalaTheShepard commented 1 month ago

Thanks for looking into the issue 🙂

Christophe999s commented 1 month ago

In the file /homeassistant/custom_components/afvalbeheer/API.py, change line 1149 to self.main_url = 'https://www.recycleapp.be/api/app/v1/' api.recycleapp.be doesn't resolve anymore, but the api seems to work fine using www.recycleapp.be Back up and running for me

Screenshot 2024-09-18 at 08 44 03
pippyn commented 1 month ago

Fixed in v5.4.2