Closed Bug 871199 Opened 6 years ago Closed 6 years ago

All day events are corrupted by ical.js backend

Categories

(Calendar :: ICAL.js Integration, defect, critical)

defect
Not set
critical

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mmecca, Assigned: Fallen)

References

Details

(Keywords: dataloss, dogfood)

Attachments

(1 file)

All day events and other properties of type VALUE=DATE are incorrectly formatted by the ical.js backend, causing data corruption on ics calendars containing these events.

STR:
1) Switch to the ical.js backend
2) Create and open a new ics calendar
3) Create an all day event

Results:
On restarting Thunderbird, calendar parsing fails with

Error: 'Error: invalid date-time value: "2013--0-5-T1::"' when calling method: [calIIcalComponent::getNextProperty] = NS_ERROR_XPC_JS_THREW_JS_OBJECT
Source file: resource://calendar/modules/calIteratorUtils.jsm
Line: 186


Date properties are written in the format:
DTSTART:2013-05-11

but should be in the format:
DTSTART;VALUE=DATE:20130511
Summary: All day events are corrupted by ical.js backend → [jsical] All day events are corrupted by ical.js backend
Component: Internal Components → ICAL.js Integration
Summary: [jsical] All day events are corrupted by ical.js backend → All day events are corrupted by ical.js backend
Severity: normal → critical
Keywords: dataloss, dogfood
Attached patch Fix - v1 β€” β€” Splinter Review
Turns out this is https://github.com/mozilla-comm/ical.js/pull/84 and I just forgot to include the patch in Lightning.

I'd appreciate if you could review the PR on github for the tests it adds. The patch uploaded here just contains the changes in Lightning.
Assignee: nobody → philipp
Status: NEW → ASSIGNED
Attachment #749897 - Flags: review?(matthew.mecca)
Comment on attachment 749897 [details] [diff] [review]
Fix - v1

r=lightsofapollo at github. Some slight changes I'll add before commit.
Attachment #749897 - Flags: review?(matthew.mecca) → review+
Pushed to comm-central changeset 65fd9a64e428
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → 2.6
Backported to releases/comm-aurora changeset 37c0e4310473
Target Milestone: 2.6 → 2.5
Attachment #749897 - Flags: approval-calendar-aurora+
You need to log in before you can comment on or make changes to this bug.