Closed Bug 421616 Opened 12 years ago Closed 12 years ago

Editing event to change calendar fails, event disappears from database


(Calendar :: Lightning Only, defect, blocker)

Not set


(Not tracked)



(Reporter: ssitter, Assigned: Fallen)




(Keywords: dataloss)


(1 file)

Lightning 0.8 (2008030619) + Thunderbird (20080307) on Windows XP

Editing event to change calendar fails, event disappears from database

Steps to Reproduce:
1. Start Thunderbird with clean profile, install Lightning and restart
2. Create a second storage calendar
3. Create new event in first calendar
4. Edit event and change the calendar to the second one
5. Press the "Save and Close" toolbar button

Actual Results:
Nothing happens. Edit event dialog is still shown. Errors in console:

Error: aItem has no properties
Source File: chrome://calendar/content/calendar-item-editing.js Line: 415

Error: uncaught exception: [Exception... "'[JavaScript Error: "aItem has no properties" {file: "chrome://calendar/content/calendar-item-editing.js" line: 415}]' when calling method: [calIOperationListener::onOperationComplete]"  nsresult: "0x80570021 (NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)"  location: "JS frame :: file:///[...]/js/calTransactionManager.js :: cT_onOperationComplete :: line 143"  data: yes]

Pressing "Save and Close" a second time closes the dialog. But the event is still displayed for the old calendar. After reloading the calendars the previously edited event is no longer available -> dataloss.

This seems to be storage provider specific (did not test other providers):
 from storage to storage -> failed
 from storage to ics -> failed
 from ics to storage -> worked
 from ics to ics -> worked

Sunbird doesn't show this issue because checkForAttendees() in calendar-item-editing.js is only executed for Lightning.

This issue has been reported in the German calendar forum
Flags: blocking-calendar0.8?
Regression range: Works in Lightning 0.8pre (2008-03-03-08)
                  Fails in Lightning 0.8pre (2008-03-04-01)

Checkins during regression range:

Seems to be caused by the checkin for Bug 418805.
Definitely a blocker.

Sebo, Philipp, Berend, since you either provided patches or reviews to bug 418805, can you please take a look at this.
Severity: critical → blocker
Flags: blocking-calendar0.8? → blocking-calendar0.8+
This seems to work for me?
Attached patch Fix v1Splinter Review
I take that back, I overread the fact that it only happens with lightning. The fix is quite simple, the storage calendar doesn't follow the idl specs that the item should be returned as a last argument in deleteItem.

It would be great if someone could take care that this gets checked in. I have limited internet access the next two weeks.
Assignee: nobody → philipp
Attachment #308319 - Flags: review?(ssitter)
Flags: in-testsuite?
Comment on attachment 308319 [details] [diff] [review]
Fix v1

seems to work, r=ssitter
Attachment #308319 - Flags: review?(ssitter) → review+
Keywords: checkin-needed
I committed the change to the trunk and the 1.8 branch. But I currently lack a Sunbird 0.8 tree and can't get one at the moment. I'll commit this change tomorrow on that branch, once I can download a full 0.8 tree.
Checked in on SUNBIRD_0_8_BRANCH as well.
Closed: 12 years ago
Flags: blocking-calendar0.8+
Keywords: checkin-needed
OS: Windows XP → All
Hardware: PC → All
Resolution: --- → FIXED
Target Milestone: --- → 0.8
Checked in latest builds (lightning 2008031019/sunbird 20080310) -> task is fixed and verified.
Flags: in-testsuite?
You need to log in before you can comment on or make changes to this bug.