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

feat(dav): Add VTIMEZONE data when creating personal calendar #36522

Closed

Conversation

tcitworld
Copy link
Member

@tcitworld tcitworld commented Feb 3, 2023

The personal calendar created at the user's first login does not hold a timezone property. This leads to reminders being sent using server time instead of the user's timezone, since the calendar has no tz information.
See nextcloud/calendar#4778 for extra context.

The vtimezone ICS data comes from the @nextcloud/calendar-js library, https://github.com/nextcloud/calendar-js/tree/main/resources/timezones, which uses a python script to generate the vtimezone files from the data produced by https://github.com/libical/vzic (which in turn uses data from IANA's tzdata).

A few months ago, Mozilla switched to using
https://hg.mozilla.org/comm-central/rev/2b430305eaf46970d62e9569e1800d5c4be9071c ICU4C directly (see icu::VTimeZone::createVTimeZoneByID), and seems to produce data dynamically instead (with a cache). This allows them to avoid manual intervention to refresh data, and they say it also includes more valid timezones. See https://bugzilla.mozilla.org/show_bug.cgi?id=1794029

In any case, we need a proper way to update the timezone database regularly (this data is already 4 years old).

TODO

  • Fix tests
  • Check other uses of createCalendar

Checklist

The personal calendar created at the user's first login does not hold a timezone property.
This leads to reminders being sent using server time instead of the user's timezone,
since the calendar has no tz information.
See nextcloud/calendar#4778 for extra context.

The vtimezone ICS data comes from the @nextcloud/calendar-js library,
https://github.com/nextcloud/calendar-js/tree/main/resources/timezones,
which uses a python script to generate the vtimezone files from the data
produced by https://github.com/libical/vzic (which in turn uses data
from IANA's tzdata).

A few months ago, Mozilla switched to using
https://hg.mozilla.org/comm-central/rev/2b430305eaf46970d62e9569e1800d5c4be9071c
ICU4C directly (see icu::VTimeZone::createVTimeZoneByID), and seems to
produce data dynamically instead (with a cache). This allows them to
avoid manual intervention to refresh data, and they say it also includes
more valid timezones. See https://bugzilla.mozilla.org/show_bug.cgi?id=1794029

In any case, we need a proper way to update the timezone database
regularly (this data is already 4 years old).

Signed-off-by: Thomas Citharel <[email protected]>
@tcitworld tcitworld added 3. to review Waiting for reviews feature: caldav Related to CalDAV internals labels Feb 3, 2023
@tcitworld tcitworld added this to the Nextcloud 26 milestone Feb 3, 2023
@tcitworld tcitworld requested review from ArtificialOwl, icewind1991 and blizzz and removed request for a team February 3, 2023 14:17
@tcitworld tcitworld added 2. developing Work in progress and removed 3. to review Waiting for reviews labels Feb 7, 2023
@skjnldsv skjnldsv mentioned this pull request Feb 23, 2023
@blizzz blizzz mentioned this pull request Mar 7, 2023
@blizzz blizzz modified the milestones: Nextcloud 26, Nextcloud 27 Mar 9, 2023
This was referenced May 3, 2023
@blizzz blizzz mentioned this pull request May 17, 2023
@blizzz blizzz modified the milestones: Nextcloud 27, Nextcloud 28 May 23, 2023
@skjnldsv skjnldsv mentioned this pull request Nov 1, 2023
@blizzz blizzz mentioned this pull request Nov 6, 2023
This was referenced Nov 10, 2023
@blizzz blizzz mentioned this pull request Nov 20, 2023
5 tasks
@blizzz blizzz modified the milestones: Nextcloud 28, Nextcloud 29 Nov 23, 2023
This was referenced Mar 12, 2024
This was referenced Mar 20, 2024
@skjnldsv skjnldsv mentioned this pull request Mar 28, 2024
81 tasks
@skjnldsv skjnldsv modified the milestones: Nextcloud 29, Nextcloud 30 Mar 28, 2024
This was referenced Jul 30, 2024
This was referenced Aug 5, 2024
@skjnldsv skjnldsv mentioned this pull request Aug 13, 2024
@skjnldsv skjnldsv closed this Aug 14, 2024
@skjnldsv skjnldsv removed this from the Nextcloud 30 milestone Aug 14, 2024
@skjnldsv skjnldsv deleted the add-vtimezone-data-when-creating-personal-calendar branch August 30, 2024 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2. developing Work in progress feature: caldav Related to CalDAV internals
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants