Skip to content

Fix DST-aware UTC conversion for EXDATE and RRULE UNTIL in iCal export#11553

Open
MrKrisKrisu wants to merge 1 commit into
ILIAS-eLearning:release_11from
MrKrisKrisu:ics
Open

Fix DST-aware UTC conversion for EXDATE and RRULE UNTIL in iCal export#11553
MrKrisKrisu wants to merge 1 commit into
ILIAS-eLearning:release_11from
MrKrisKrisu:ics

Conversation

@MrKrisKrisu
Copy link
Copy Markdown

The EXDATE and RRULE UNTIL timestamps were created by combining the target date with the UTC time of the DTSTART timestamp. When DTSTART falls in CET but the target date falls in CEST (or vice versa), the resulting UTC timestamp differs by one hour. Therefore, calendar clients that compare occurrences in UTC would not match the exception and display the excluded date anyway.

The fix involves constructing a proper datetime from the target date and the event's local start time in the user's configured time zone, and then converting to UTC.

Example:

  • Series begins at 2026-03-18 08:15 Europe/Berlin
  • Remove single date at 2026-03-25 -> workes because same timezone
  • Remove single date at 2026-05-27 -> doesn't work because of DST

Other Example: Series begins in DST (now)

  • Series begins at 2026-04-01 08:15 Europe/Berlin (->DST!)
  • Remove single date at 2026-05-27 -> workes because same timezone

Screenshot with both examples from Thunderbird BEFORE my change:

Screenshot From 2026-05-15 10-51-34

Screenshot with both examples from Thunderbird AFTER my change:

Screenshot From 2026-05-15 10-59-14

@mjansenDatabay mjansenDatabay added bugfix php Pull requests that update Php code labels May 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix php Pull requests that update Php code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants