Closed Bug 1266797 Opened 9 years ago Closed 2 years ago

Wrong first occurrence for MONTHLY rule with BYMONTHDAY greater than the last day of the month

Categories

(Calendar :: Internal Components, defect)

defect
Not set
normal

Tracking

(thunderbird_esr102 fixed)

RESOLVED FIXED
107 Branch
Tracking Status
thunderbird_esr102 --- fixed

People

(Reporter: bv1578, Assigned: darktrojan)

References

Details

Attachments

(2 files, 1 obsolete file)

This is reproducible with both libical and ical.js Steps to reproduce: - create an event on any day of a month with less than 31 (or 30) days; - select Repeat: "Custom" -> "Monthly" -> In the daypicker "Recur on day(s)" set "31" and deselect the day of the start date; - save and close; --> the event starts on the day of the start date, but misses the first recurrence on the 31 of the next month, instead it is moved on an early day of the month. For example starting in February, the first occurrence is the the 3th (or the 2nd) of March instead of the 31st of March.
Attached patch patch-icaljs-libical-tests-v1.patch (obsolete) (deleted) — Splinter Review
The issue is caused by the assignment of BYMONTHDAYs negative or greater than the last day of the month to the date "last.day", along with the automatic normalization in ical.js. I opened a pull request for ical.js on GitHub: https://github.com/mozilla-comm/ical.js/pull/232 This patch includes ical.js part and tests for this bug and bug 386516 as well because ical.js still had that bug and an explicit test was missing. I also added a few test that should be in the tests list.
Assignee: nobody → bv1578
Status: NEW → ASSIGNED
Attachment #8749385 - Flags: review?(philipp)
Sorry for the delay on this, but I'm going to have to take a closer look at this one. Hope to get to that soon! Just wanted to let you know I haven't forgotten!
Blocks: 890565
Comment on attachment 8749385 [details] [diff] [review] patch-icaljs-libical-tests-v1.patch Removing the review request because it needs to take a deeper look to wrong formatted rules apart from those ones "standard" identified by the parser.
Attachment #8749385 - Flags: review?(philipp)
Assignee: bv1578 → nobody
Status: ASSIGNED → NEW

Has this also been fixed with the ical.js changes in bug 1789362?

Flags: needinfo?(geoff)

For negative values yes, otherwise no. Now that I'm aware of it I think I could fix it in a fairly similar way, so I'll leave the NI open.

Assignee: nobody → geoff
Status: NEW → ASSIGNED
Flags: needinfo?(geoff)
Version: Lightning 4.0.7.2 → unspecified
No longer blocks: 890565

Pushed by geoff@darktrojan.net:
https://hg.mozilla.org/comm-central/rev/56e2951ec642
Fix recurrence iteration where there is a BYMONTHDAY rule greater than the number of days in the start month. r=#thunderbird-reviewers,mkmelin

Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 107 Branch

This needs a follow-up patch to mention the pull request in comment 6 in the header referring to the upstream source.

Flags: needinfo?(rob)
Status: RESOLVED → REOPENED
Flags: needinfo?(rob)
Resolution: FIXED → ---

Pushed by thunderbird@calypsoblue.org:
https://hg.mozilla.org/comm-central/rev/be2044f63ec8
Follow-up: Include PR information in reference to upstream source. r=darktrojan DONTBUILD

Status: REOPENED → RESOLVED
Closed: 2 years ago2 years ago
Resolution: --- → FIXED
Attachment #8749385 - Attachment is obsolete: true

Comment on attachment 9296927 [details]
Bug 1266797 - Fix recurrence iteration where there is a BYMONTHDAY rule greater than the number of days in the start month. r=#thunderbird-reviewers

[Approval Request Comment]
Regression caused by (bug #): ical.js
User impact if declined: events recur on the wrong day, that's quite bad
Testing completed (on c-c, etc.): in 107b1
Risk to taking this patch (and alternatives if risky): low

Attachment #9296927 - Flags: approval-comm-esr102?

Comment on attachment 9296927 [details]
Bug 1266797 - Fix recurrence iteration where there is a BYMONTHDAY rule greater than the number of days in the start month. r=#thunderbird-reviewers

[Triage Comment]
Approved for esr102

Attachment #9296927 - Flags: approval-comm-esr102? → approval-comm-esr102+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: