KoljaWindeler / ics

Integration that displays the next event of an ics link (support reoccuring events)
50 stars 13 forks source link

Wrong date picked #3

Closed PatMei closed 4 years ago

PatMei commented 4 years ago

Hello Kolja,

I use the following trashcalendar: https://awido.cubefour.de/Customer/awb-duerkheim/KalenderICS.aspx?oid=00000000-0000-0000-0001-000000000706&jahr=2020

It shows me a date (example startswith: Papier) in few month (Monday, 13.07.2020 (113)) but next time for paper will be in a week. Hope you can reproduce the error ;)

Cheers, PatMei

KoljaWindeler commented 4 years ago

hi, yes I can reproduce the error ... the reason is the very strange format of that ICS file. The events are completely out of order. I'll have a look how to fix it. Might take some time. Kolja

KoljaWindeler commented 4 years ago

Hi again, I've fixed the sorting in commit https://github.com/KoljaWindeler/ics/commit/52a2add16ef8c3ed642b7e6932757d1b88eaaa5a could you have a look? Thanks Kolja

PatMei commented 4 years ago

Looks good 👍 Thank you for your work! Can you also change the calculation? It is still one day leftfor picking up trash, but today is the day. Setting it to "0" or "Today".

Unbenannt

KoljaWindeler commented 4 years ago

Ha, tricky. That was sadly a bug introduced by the date handling. Thats fixed now. I hope that all of you see this before adding complex logic that relies on the state. Thanks for mentioning it.

PatMei commented 4 years ago

So far, it is working :) thank you very much for caring about!

Cheers, PatMei