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

Drop RULES with UNTIL before DTSTART #38

Closed
rfc2822 opened this issue May 30, 2022 · 2 comments · Fixed by #45
Closed

Drop RULES with UNTIL before DTSTART #38

rfc2822 opened this issue May 30, 2022 · 2 comments · Fixed by #45
Assignees
Labels
enhancement New feature or request

Comments

@rfc2822
Copy link
Member

rfc2822 commented May 30, 2022

From time to time, events with an RRULE whose UNTIL is before the DTSTART of the event appear, like:

DTSTART: 2022/05/31 13:00
RRULE: … UNTIL 2022/05/31 12:59

Such events are invalid and sometimes cause problems when they're uploaded again to the server (because the server reject them, which is OK).

Thus such RRULEs should be dropped, both when they're received from the server and when they're found in the calendar provider.

@rfc2822 rfc2822 self-assigned this May 31, 2022
@rfc2822 rfc2822 added the enhancement New feature or request label May 31, 2022
@devvv4ever
Copy link
Member

This Event was sent by a user:

BEGIN:VCALENDAR
VERSION:2.0
PRODID:DAVx5/3.3.7-ose ical4j/3.0.20 (org.withouthat.acalendarplus)
BEGIN:VEVENT
DTSTAMP:20220530T071034Z
UID:6f367bbe-c3d3-4bdd-ac69-xxxxxxxxxx.1596835176176
SEQUENCE:1
SUMMARY:XXX
DESCRIPTION:XXX
DTSTART;VALUE=DATE:20200912
DTEND;VALUE=DATE:20200913
RRULE:FREQ=YEARLY;UNTIL=20220911T235959Z;BYMONTH=9;BYMONTHDAY=12
CLASS:PUBLIC
STATUS:CONFIRMED
TRANSP:TRANSPARENT
CREATED:20200807T211937Z
END:VEVENT
END:VCALENDAR

@dilyanpalauzov
Copy link

https://datatracker.ietf.org/doc/html/rfc5545#page-41 says:

The value of the UNTIL rule part MUST have the same value type as the "DTSTART" property. Furthermore, if the "DTSTART" property is specified as a date with local time, then the UNTIL rule part MUST also be specified as a date with local time.

In the above example the first problem is that DTSTART has value type DATE, while UNTIL has value type DATE-TIME.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
3 participants