Waste Collection Schedule Framework

Like described in the Breaking Changes section, the only affected sources are vejle_dk, favrskovforsyning_dk and highland_gov_uk

1 Like

agree with @paddy0174 thanks for all your hard work with this integration. was the first integration I installed when I started and still going strong.

1 Like

Thanks for your help with this. Tried it with my details using Broxtowe Council in the UK and it didnt work “the source returned an empty responce…”.

Happy to share exact postcode and UPRN privately if it helps to test.

I had this message the first time, but it disappeared and just worked when I tried to investigate, and I cannot reproduce it. Not sure what happened there.

(fixed another issue with Broxtowe not related with this issue and seem to not affect your address) broxtowe skip date if not parsable instead of fail compleatly + reformatting by 5ila5 · Pull Request #2254 · mampfes/hacs_waste_collection_schedule · GitHub

Very strange, I came back to it again a few hours later and it works. I even restarted the hub last time and that didnt make any difference .

Thanks!

Hi,
I am trying to get this integration to work, and I have been searching with no luck, how to generate the ICS file.
My local waste collection provider only provides a beautiful printable PDF file once a year. I actually spend some minutes each end december to put all dates into an Excel file, to produce a CSV I import into my Outlook calendar.
I would like to find some sample and simple ICS file so I can generate my own file once a year.
Someone could help me ?
Thanks!

If your service provider only offers a PDF there is no good way for us to directly integrate it in this integration. Here is an example ICS file.

What seems to be the problem with your Outlook calendar? Can’t you export the ICS file from there? Sorry, no Outlook user here. :slight_smile:

In theory it goes like this:

  • Export the ICS file
  • Safe it under the www folder in your HA config folder
  • Include it in your config of waste_collection_schedule

You can find more info on that here:

I’ve been using this integration for quite a while but the changes in the latest version (2.0.1) have broken my configuration. I’ve tried to re-add the integration via the UI but it gives an error that the date is not formated correctly (I think it may not be pulling in data). When I try via the new YAML config, the calendar is created but does not pull in any dates. I’m using the following yaml:

waste_collection_schedule:
  sources:
    - name: republicservices_com
      args:
        street_address: !secret street_address
        method: 1

For the time being, I’ve reverted to the previous version and restored my old YAML config.

That has nothing to do with the update but with an update on republic services side,
It is already fixed in the master version

more details: [Bug]: fetch failed for Republic Services · Issue #2420 · mampfes/hacs_waste_collection_schedule · GitHub

Thanks. I was wondering why rolling back to a previous version wasn’t helping.

Hey people,

i have a problem with the integration and cards.
I used to live in Stuttgart where i did not have any problems since the switch to UI integration. As german the “DaysTo” Sensor said as it sould “in x Tagen”
Now as i switched to Aichach-Friedberg it sais “in x days”, alternatively i can select the “DaysTo” directly in the Tile Card (second picture) but then only the number is displayed. That would be fine for me if i could use that to work with and convert it into “in x Tagen, morgen, heute” (tomorrow, today)

My second try was to do it with a mushroom template card but there just nothing is displayed when i use ‘{ values.daysTo }’ (picture 3)

grafik

can anyone help me out with that?

I think you need to change the value template of the sensors (settings → integrations → WCS → customize (next to your source) → select sensors to customize → update value template

1 Like

Sorry for the late response.
Your suggestion worked on first try due to your explanation.
Thanks so much

Hi there,
I have installed waste-collection-schedule since one year now, running without problems. Since 09-09-2024 it stopped working, displaying values as “unknown”. Error in logs I could find:

Dieser Fehler wurde von einer benutzerdefinierten Integration verursacht
Logger: waste_collection_schedule.source_shell
Quelle: custom_components/waste_collection_schedule/waste_collection_schedule/source_shell.py:136
Integration: waste_collection_schedule (Dokumentation)
Erstmals aufgetreten: 9. September 2024 um 12:51:35 (3 Vorkommnisse)
Zuletzt protokolliert: 04:25:36
fetch failed for source ICS: Traceback (most recent call last): File “/config/custom_components/waste_collection_schedule/waste_collection_schedule/source_shell.py”, line 134, in fetch entries = self._source.fetch() ^^^^^^^^^^^^^^^^^^^^ File “/config/custom_components/waste_collection_schedule/waste_collection_schedule/source/ics.py”, line 170, in fetch return self.fetch_file(self._file) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/config/custom_components/waste_collection_schedule/waste_collection_schedule/source/ics.py”, line 201, in fetch_file return self._convert(f.read()) ^^^^^^^^^^^^^^^^^^^^^^^ File “/config/custom_components/waste_collection_schedule/waste_collection_schedule/source/ics.py”, line 204, in _convert dates = self._ics.convert(data) ^^^^^^^^^^^^^^^^^^^^^^^ File “/config/custom_components/waste_collection_schedule/waste_collection_schedule/service/ICS.py”, line 38, in convert events: List[Any] = icalevents.events( ^^^^^^^^^^^^^^^^^^ File “/usr/local/lib/python3.12/site-packages/icalevents/icalevents.py”, line 57, in events found_events += parse_events( ^^^^^^^^^^^^^ File “/usr/local/lib/python3.12/site-packages/icalevents/icalparser.py”, line 394, in parse_events elif e.end >= f and e.start <= t and is_not_exception(e.start): ^^^^^^^^^^ TypeError: can’t compare datetime.datetime to datetime.date

Ich sehe, dass der Datumsvergleich in die Hose geht, aber wie repariere ich das?

Gruß SD

I am trying to set this up for use with Republic Services as the source. I have tried configuring it via GUI (my preferred) and YAML but end up with the same result. Either way I do it, I end up getting a calendar created with 3 entries for today (Trash, Recycle and Yard) and then Recycle set for every other week as it should. The Trash should be every week and yard is a few weeks in the fall but the Trash and Yard waste just show up for the initial week its setup in as seen here:

Here’s what I have tried in yaml:
waste_collection_schedule:
sources:
- name: republicservices_com
args:
street_address: “My Address Here”
method: 2

How do I need to configure this add on so it shows up correctly in HA? I very new to HA and was told it is very simple to setup and use but I am finding the learning curve a bit steeper than I expected as I start to set it up. Any help is appreciated.

Hello Dengao,

I come from the VG Betzdorf-Gebhardshain.

Have you solved the problem?

So far I have been using my own ics calendar, which I change at the turn of the year. You only have to do this once a year, but I wanted to save myself the trouble in the future and query the Awido calendar directly.

I have changed the configuration.yaml accordingly.

After restarting HAOS, however, no sensor values ​​are displayed.

As I had previously created a backup, I was able to restore it and returned to the settings that worked as before.

Is there anything special to watch out for?

Where are the sensor values ​​queried in the AWIDO solution?

If you find the time, I would be happy to hear from you.

Best wishes from Scheuerfeld

The error TypeError: can’t compare datetime.datetime to datetime.date

Resulted from a faulty version of the pyton librabry icalevents. This should already be fixed by updating to WCS 2.2.0, which excluded this version of icalevents as dependency.

This might be expected behavior. The retrieved data differs hugely by region/address using republic services, Some addresses only show the next collection of a bin type and no collection further in the future, So I guess a few days later It should show the next collections.

These are the dates we get from the API used by the republic services website

They list the pickups well into the future (I looked forward into 2026) in my area if I look at the schedule via their website. I have been trying to get it to work for about 3 weeks before posting here for help and no matter how I configure it, it always displays the way I stated above, Recycle is populated correctly through Dec 2024 so it’s processing that schedule correctly, but Trash or Yard Waste only displayed for the initial week.