Closed Bug 1770984 Opened 2 years ago Closed 2 years ago

accepting event with secondly frequency recurrence freezes Thunderbird GUI interactions

Categories

(Calendar :: General, defect, P1)

Thunderbird 91

Tracking

(thunderbird_esr91 affected, thunderbird102 fixed)

RESOLVED FIXED
103 Branch
Tracking Status
thunderbird_esr91 --- affected
thunderbird102 --- fixed

People

(Reporter: gh, Assigned: lasana)

Details

Attachments

(1 file, 1 obsolete file)

Steps to reproduce:

I manually crafted an .ics calendar invitation according to the RFC 5545 standard with a recurrence rule set to FREQ=SECONDLY (event recurrence = every second)

I also added a recurring VALARM 30 minutes before event which gets repeated every 15 minutes. Note: the first date on my event was about 40 minutes in the future when I accepted it.

(see attachment for example .ics file)

Actual results:

When sending that invitation to my email and accepting it through Thunderbird into my CalDAV server it was properly added to my CalDAV server, however now when trying to use Thunderbird it hangs up and the full UI is unusable.

It seems like everything keeps working before you accept the invite however. The MINUTELY frequency might also be affected, although I did not test that one.

Expected results:

Thunderbird should probably ignore secondly events or only show them once or with some minimum frequency instead of having the UI being essentially bricked.

note: Thunderbird actually doesn't completely lock up, just every UI interaction (click or other) takes about a minute and loading of things is terribly slow, while animations all look fine and smooth.

I can confirm this, the application becomes more or less unusable with 100% CPU usage. Seems to happen with both icaljs or libical. I ran into this on 91 as well.

Severity: -- → S1
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P1

I recommend anyone looking at this NOT try opening the attached event some of my profiles are now unusable because they hang at startup.
Wayne can we restrict the attachment visibility? It's still useful for testing.

Flags: needinfo?(vseerror)
Flags: needinfo?(vseerror)

We attempt to create an occurrence for every second of the recurrence rule. This results in a massive array of objects that is created anytime getOccurrences() is called. I'm going to set a maximum amount of recurrences to return for sanity sake and also add a test for this.

Assignee: nobody → lasana
Status: NEW → ASSIGNED
Attachment #9279605 - Attachment is obsolete: true

I made the ical.js and libical recurrence rule objects return null for getNextOccurrence() and an empty list for getNextOccurrence(). SECONDLY and MINUTELY generate a lot of items in the calendar view that we don't really have space for and you can't actually create an event with those frequencies in the UI, thus not really supported anyway. The first occurrence of the event still shows so the user isn't left wondering whether the event was added or not but they won't see the other occurrences.

Target Milestone: --- → 103 Branch

Pushed by mkmelin@iki.fi:
https://hg.mozilla.org/comm-central/rev/3e1e759eee6d
Do not support "SECONDLY" or "MINUTELY" recurring events. r=mkmelin

Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED

Comment on attachment 9279943 [details]
Bug 1770984 - Do not support "SECONDLY" or "MINUTELY" recurring events. r=#thunderbird-reviewers

[Approval Request Comment]
Regression caused by (bug #): none
User impact if declined: Users accepting these events in TB can end up stuck in an infinite loop preventing usage of the application.
Testing completed (on c-c, etc.): trunk
Risk to taking this patch (and alternatives if risky):
Moderate risk, some C++ code modified for libical but nothing too adventurous and there are tests. Risk of not fixing this is greater.

Attachment #9279943 - Flags: approval-comm-beta?

Comment on attachment 9279943 [details]
Bug 1770984 - Do not support "SECONDLY" or "MINUTELY" recurring events. r=#thunderbird-reviewers

[Triage Comment]
Approved for beta

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

Attachment

General

Creator:
Created:
Updated:
Size: