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

ValueError: RRULE UNTIL values must be specified in UTC when DTSTART is timezone-aware #388

Open
VPanteleev-S7 opened this issue May 22, 2023 · 3 comments

Comments

@VPanteleev-S7
Copy link

I got this error when parsing a file generated by an Apple product (possibly iCloud).

Here is a reduced calendar file which reproduces the issue:

BEGIN:VCALENDAR
BEGIN:VTIMEZONE
BEGIN:STANDARD
DTSTART:19230916T030000
RRULE:FREQ=YEARLY;UNTIL=19240921T020000Z;BYMONTH=9;BYMONTHDAY=16,17,18,19
TZOFFSETFROM:+0100
TZOFFSETTO:+0000
END:STANDARD
END:VTIMEZONE
END:VCALENDAR

Code to reproduce:

from ics import Calendar
with open("test.ics", "r") as f:
	calendar = Calendar(f.read())

I don't know much about calendar files, but looking at UNTIL=19240921T020000Z, that already looks like UTC to me.

@N-Coder
Copy link
Member

N-Coder commented Jun 18, 2023

I assume this is using ics.py v0.7 as it is probably a problem with arrow, could you retry with v0.8 (from GitHub or the current PyPi Alpha release)?

@VPanteleev-S7
Copy link
Author

Still fails after pip install git+https://github.com/ics-py/ics-py, with the same error message.

@N-Coder
Copy link
Member

N-Coder commented Jun 19, 2023

Then this probably also happens when you directly pass this to dateutils ical vtimezone parser? In v0.8 we are no longer wrapping the whole dateutil vtimezone parser, but we still use dateutil functions for working with rrules. So it might be possible to come up with a work-around for this, but I don't yet quite see what is going wrong here (and unfortunately also don't have the time to investigate further). If the same happens with the dateutil ical vtimezone parser, maybe opening an issue there would be the best way to go.

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

2 participants