Closed Bug 678930 Opened 13 years ago Closed 13 years ago

ICS calendar fails when connection temporarily unavailable

Categories

(Calendar :: Provider: ICS/WebDAV, defect)

x86
All
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mmecca, Assigned: mmecca)

References

Details

Attachments

(1 file, 1 obsolete file)

Reloading a remote ics calendar with the connection unavailable will sometimes fail with 

Error: [Exception... "Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsIHttpChannel.responseStatus]"  nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)"  location: "JS frame :: file:///media/Data/mozilla/obj-i686-pc-linux-gnu-comm-miramar/mozilla/dist/xpi-stage/lightning/components/calICSCalendar.js :: <TOP_LEVEL> :: line 920"  data: no]
Source File: file:///media/Data/mozilla/obj-i686-pc-linux-gnu-comm-miramar/mozilla/dist/xpi-stage/lightning/components/calICSCalendar.js
Line: 920

This can leave the calendar in a locked state, and prevent further operations even if the connection becomes available again.
Assignee: nobody → matthew.mecca
Status: NEW → ASSIGNED
Attached patch Fix v1 (obsolete) — — Splinter Review
Allow provider to fail gracefully when encountering potentially temporary connection issues on load
Attachment #553095 - Flags: review?(philipp)
Blocks: 529771
Comment on attachment 553095 [details] [diff] [review]
Fix v1

Review of attachment 553095 [details] [diff] [review]:
-----------------------------------------------------------------

r=philipp with the following nits. Feel free to push to all three branches.

::: calendar/providers/ics/calICSCalendar.js
@@ +944,5 @@
>          // 404: Not Found
>          // This is a new calendar. Shouldn't try to parse it. But it also
>          // isn't a failure, so don't throw.
> +        if (responseStatus == 404) {
> +            cal.LOG("[calICSCalendar] 404: Not Found.");

I'd suggest being more verbose on the log message here since a file not found isn't really a bad thing for new calendars.
Attachment #553095 - Flags: review?(philipp) → review+
Attached patch Fix v2 — — Splinter Review
De-bitrotted, more verbose messages.
Attachment #553095 - Attachment is obsolete: true
Attachment #562347 - Flags: review+
I'll push to comm-beta after the merge.
Pushing to comm-aurora per Bug 543323 comment #12
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.0b8
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: