Closed Bug 1630485 Opened 2 years ago Closed 2 years ago

Intermittent comm/calendar/test/browser/browser_todayPane.js | uncaught exception - TypeError: can't access property "currentTask", this.tree is null at modifyItems@chrome://calendar/content/calendar-task-tree-view.js:88:19


(Calendar :: Calendar Frontend, defect, P5)



(Not tracked)

Thunderbird 77.0


(Reporter: intermittent-bug-filer, Assigned: darktrojan)


(Keywords: intermittent-failure)


(2 files)

I don't know how we end up with a tree view not attached to a tree, the only explanations I have are that somehow the tree's been removed from the DOM or a new view has been set on it. I can't see how that either of those are possible.

I also can't see why this test is only failing after 16:00 UTC, but it seems that is the case. I can't test this patch properly right now if that really is the case.

Assignee: nobody → geoff
Attachment #9140929 - Flags: review?(paul)

This patch moves browser_timezones.js into a folder of its own. I suspect it is part of the problem with browser_todayPane.js, for two reasons: the weird "this only happens at certain times of day" thing, and because the failure doesn't seem to happen on debug builds, and browser_timezones.js doesn't run on debug builds.

Ideally I'd land these patches separately to confirm one or the other fixes this bug.

Attachment #9140930 - Flags: review?(paul)
Comment on attachment 9140929 [details] [diff] [review]

Review of attachment 9140929 [details] [diff] [review]:

r+ LGTM. Strange bug. One suggestion for the comment, if you think it would help.

::: calendar/base/content/calendar-task-tree.js
@@ +458,5 @@
>          operation: null,
>          onOperationComplete(opCalendar, status, operationType, id, dateTime) {
> +          if (!this.tree.mTreeView.tree) {
> +            // Looks like we've been disconnected from the DOM, there's no point in continuing.

Maybe add this bug number to the comment?
Attachment #9140929 - Flags: review?(paul) → review+
Comment on attachment 9140930 [details] [diff] [review]

Review of attachment 9140930 [details] [diff] [review]:

r+ LGTM.  (As an aside this test always causes trouble when I run it locally.  It intermittently fails to select some of the timezones in the event timezone dialog menu, gets stuck.  I have it on my list to try and fix that.)

::: calendar/test/browser/timezones/browser_timezones.js
@@ -50,5 @@
>  ];
>  add_task(async function testTimezones1_SetGMT() {
>    Services.prefs.setStringPref("calendar.timezone.local", "Europe/London");
> -  await setCalendarView("day");

Can you say more about why this change?  Just curious.  Also, you could drop the "async" from the function.
Attachment #9140930 - Flags: review?(paul) → review+
Keywords: leave-open

(In reply to Paul Morris [:pmorris] from comment #4)

  • await setCalendarView("day");

Can you say more about why this change? Just curious.

The test will always start in the day view, unless we add more tests to this folder. It was insurance that we were in the right view to begin with. Also, the setCalendarView function is in the head.js file of the folder this used to be in, which we can't easily use from here.

I'm going to check this patch in but not the other, to see if it makes a difference by itself.

Pushed by
Move browser_timezones.js to a folder of its own. r=pmorris
Pushed by
Stop trying to refresh a task tree that no longer exists. r=pmorris
Closed: 2 years ago
Keywords: leave-open
Resolution: --- → FIXED
Target Milestone: --- → 77
You need to log in before you can comment on or make changes to this bug.