jhbruhn / ics-adapter

tiny rust program to convert ics calendars to a custom format
2 stars 1 forks source link

Does not work with Outlook.com #1

Closed tomm1ed closed 11 months ago

tomm1ed commented 11 months ago

Published a calendar from outlook.com, shows nothing on ePaper screen and following error in log: calendar_1 | Invalid timestamp

(Running the docker image)

When downloading ICS manually from the http://[ip:3000/get?url the ICS only contains: []

jhbruhn commented 11 months ago

Huh, that's weird. Are you able to provide me with an ics file from outlook.com so I can reproduce the problem?

tomm1ed commented 11 months ago

Huh, that's weird. Are you able to provide me with an ics file from outlook.com so I can reproduce the problem?

Of course: https://outlook.live.com/owa/calendar/00000000-0000-0000-0000-000000000000/0d8acfa3-32d3-4832-93ee-71951a683c6e/cid-6362260AA37FF94A/calendar.ics

Should show 3 events for today. According to https://icalendar.org/validator.html everything is in order: Results File Size: 93 lines, 2599 bytes Number of events found: 3 Number of timezones found: 1 Success! No errors found.

However my screen just shows the title plus current date.

jhbruhn commented 11 months ago

Alright, it seems that Outlook uses a non-standard ID-system for timezones, which leads to the more complex parsing which the library I am using (and no other library for rust I found) does not support. It is in the icalendar spec, just not very user-friendly.

I added a workaround for your specific timezone, would you mind checking whether that works for you? Maybe outlook.com sends out icalendar files which are region based. It says "W. European Standard Time" for me, which seems to be Europe/London or GMT. Does that make sense?

tomm1ed commented 11 months ago

Appears to work like a charm :)

image

Leave it to Microsoft to implement a spec in their own special way

jhbruhn commented 11 months ago

Yay! I'll close this for now, although different time zones will require code changes.