Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Fetch failed for source Odense Renovation #3254

Open
4 of 7 tasks
yoali11 opened this issue Dec 21, 2024 · 0 comments
Open
4 of 7 tasks

[Bug]: Fetch failed for source Odense Renovation #3254

yoali11 opened this issue Dec 21, 2024 · 0 comments

Comments

@yoali11
Copy link

yoali11 commented Dec 21, 2024

I Have A Problem With:

A specific source

What's Your Problem

It seems like the API endpoint for Odense Renovation has changed, since the API endpoint used by this integration does not work anymore.

Ie. the following link
https://mit.odenserenovation.dk/api/Calendar/GetCalendarByAddress?addressNo=133517 returns:
{"Message":"No HTTP resource was found that matches the request URI 'https://mit.odenserenovation.dk/api/Calendar/GetCalendarByAddress?addressNo=133517'."}

I've already sent Odense Renovation an email to ask if there exists another endpoint that can be used.

Source (if relevant)

No response

Logs

I manually replaced correct addressNo to XXXXXX in the log before pasting here:

This error originated from a custom integration.

Logger: custom_components.waste_collection_schedule.waste_collection_schedule.source_shell
Source: custom_components/waste_collection_schedule/waste_collection_schedule/source_shell.py:160
integration: Waste Collection Schedule (documentation)
First occurred: 20 December 2024 at 15:24:21 (2 occurrences)
Last logged: 01:04:59

fetch failed for source Odense Renovation: Traceback (most recent call last): File "/config/custom_components/waste_collection_schedule/waste_collection_schedule/source_shell.py", line 158, in fetch entries: Iterable[Collection] = self._source.fetch() ~~~~~~~~~~~~~~~~~~^^ File "/config/custom_components/waste_collection_schedule/waste_collection_schedule/source/odenserenovation_dk.py", line 44, in fetch response.raise_for_status() ~~~~~~~~~~~~~~~~~~~~~~~~~^^ File "/usr/local/lib/python3.13/site-packages/requests/models.py", line 1024, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 404 Client Error: Not Found for url: https://mit.odenserenovation.dk/api/Calendar/GetCalendarByAddress?addressNo=XXXXXX&startDate=2024-12-20T15%3A24%3A21.571789&endDate=2025-12-20T15%3A24%3A21.571793&noCache=False
fetch failed for source Odense Renovation: Traceback (most recent call last): File "/config/custom_components/waste_collection_schedule/waste_collection_schedule/source_shell.py", line 158, in fetch entries: Iterable[Collection] = self._source.fetch() ~~~~~~~~~~~~~~~~~~^^ File "/config/custom_components/waste_collection_schedule/waste_collection_schedule/source/odenserenovation_dk.py", line 44, in fetch response.raise_for_status() ~~~~~~~~~~~~~~~~~~~~~~~~~^^ File "/usr/local/lib/python3.13/site-packages/requests/models.py", line 1024, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 404 Client Error: Not Found for url: https://mit.odenserenovation.dk/api/Calendar/GetCalendarByAddress?addressNo=XXXXXX&startDate=2024-12-21T01%3A04%3A59.354880&endDate=2025-12-21T01%3A04%3A59.354885&noCache=False

Relevant Configuration

No response

Checklist Source Error

  • Use the example parameters for your source (often available in the documentation) (don't forget to restart Home Assistant after changing the configuration)
  • Checked that the website of your service provider is still working
  • Tested my attributes on the service provider website (if possible)
  • I have tested with the latest version of the integration (master) (for HACS in the 3 dot menu of the integration click on "Redownload" and choose master as version)

Checklist Sensor Error

  • Checked in the Home Assistant Calendar tab if the event names match the types names (if types argument is used)

Required

  • I have searched past (closed AND opened) issues to see if this bug has already been reported, and it hasn't been.
  • I understand that people give their precious time for free, and thus I've done my very best to make this problem as easy as possible to investigate.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant