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

fix(caldav): Fix reminder timezone drift for all-day events #36192

Conversation

ChristophWurst
Copy link
Member

@ChristophWurst ChristophWurst commented Jan 17, 2023

Contributes to nextcloud/calendar#4778

Summary

All day events contain no timezone information. Yet reminders are specified relative to the event start. Each calendar has an optional timezone. If it's set, we should use that to determine the correct UTC timestamp for the reminder. As a fallback we should use UTC.

Ref https://www.rfc-editor.org/rfc/rfc4791#section-5.2.2

  The CALDAV:calendar-timezone property is used to
  specify the time zone the server should rely on to resolve "date"
  values and "date with local time" values (i.e., floating time) to
  "date with UTC time" values.  The server will require this
  information to determine if a calendar component scheduled with
  "date" values or "date with local time" values overlaps a CALDAV:
  time-range specified in a CALDAV:calendar-query REPORT.

TODO

  • Test all day events when calendar has timezone set
  • Test all day events when calendar does not have timezone set
  • Test event when calendar has timezone set
  • Test event when calendar does not have timezone set

Checklist

@blizzz blizzz mentioned this pull request Feb 1, 2023
@ChristophWurst ChristophWurst added bug 3. to review Waiting for reviews feature: dav feature: caldav Related to CalDAV internals and removed 2. developing Work in progress labels Feb 8, 2023
@ChristophWurst ChristophWurst marked this pull request as ready for review February 8, 2023 13:32
@ChristophWurst
Copy link
Member Author

/backport to stable25

@ChristophWurst
Copy link
Member Author

/backport to stable24

Copy link
Contributor

@miaulalala miaulalala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

Copy link
Member

@st3iny st3iny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and works. Nice one!

Setting the calendar timezone is not possible from our UI yet, right?

@ChristophWurst
Copy link
Member Author

Setting the calendar timezone is not possible from our UI yet, right?

Correct. Coming with nextcloud/calendar#4935 hopefully

@ChristophWurst ChristophWurst force-pushed the fix/caldav-reminders/fix-timezone-drift-all-day-reminders branch from bbe17e6 to b5f7afd Compare February 9, 2023 14:19
@ChristophWurst ChristophWurst changed the title fix(CalDAV reminders): Fix timezone drift for all-day events fix(caldav): Fix reminder timezone drift for all-day events Feb 9, 2023
@ChristophWurst ChristophWurst added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Feb 9, 2023
@tcitworld tcitworld mentioned this pull request Feb 9, 2023
5 tasks
@ChristophWurst ChristophWurst merged commit 7aa7868 into master Feb 9, 2023
@ChristophWurst ChristophWurst deleted the fix/caldav-reminders/fix-timezone-drift-all-day-reminders branch February 9, 2023 18:28
@ChristophWurst
Copy link
Member Author

/backport to stable24

@Luncheon3462
Copy link

I’m just an end user, not a dev but running NC 26.0.3. The time zone drift for all day event reminders still occurs for me. Doesn’t matter if I use the personal calendar that is automatically created or a new calendar that I create. My time zone is set correctly in the nc calendar app settings app. Is this expected still?

Luncheon3462

This comment was marked as off-topic.

@st3iny
Copy link
Member

st3iny commented Jul 31, 2023

@Luncheon3462 That is unfortunate. Please open a new issue and follow the bug template so that we can track and investigate the issue.

@Luncheon3462
Copy link

Luncheon3462 commented Jul 31, 2023

@st3iny I'll do my best. Not a developer or github user. Only created an account to let you, @ChristophWurst @tcitworld @miaulalala know that the bug may still be present. I also posted on the nextcloud forum, and at least one other person is reporting the same. That thread is at https://help.nextcloud.com/t/calendar-timezone-bug-36192/167212

@Luncheon3462
Copy link

@st3iny i did my best. see report at #39640.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish backport-request bug feature: caldav Related to CalDAV internals feature: dav
Projects
Development

Successfully merging this pull request may close these issues.

5 participants