Closed Bug 406804 Opened 14 years ago Closed 14 years ago

Database upgrade from Sunbird 0.3 to 0.8pre fails

Categories

(Calendar :: Provider: Local Storage, defect)

defect
Not set
critical

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: ssitter, Assigned: dbo)

Details

(Keywords: regression)

Attachments

(1 file)

 
Steps to Reproduce:
1. Start Sunbird 0.3 with clean profile.
2. Create event
3. Start Sunbird 0.8pre with previously created profile

Actual results:
Created event is not displayed. Calendar list is empty.

Regression Range:
 WORKS in Sunbird 0.8pre (2007-12-03-04)
 FAILS in Sunbird 0.8pre (2007-12-04-05)
Most probably regressed by Bug 400950.

Error: Upgrade failed! DB Error: not an error
Source File: file:///D:/Programme/sunbird/js/calStorageCalendar.js
Line: 1136

Error: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [mozIStorageConnection.rollbackTransaction]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: file:///D:/Programme/sunbird/js/calStorageCalendar.js :: anonymous :: line 1137"  data: no]
Source File: file:///D:/Programme/sunbird/js/calStorageCalendar.js
Line: 1137

Error: Can't create calendar for 1 (storage, moz-profile-calendar://): [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [mozIStorageConnection.rollbackTransaction]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: file:///D:/Programme/sunbird/js/calStorageCalendar.js :: anonymous :: line 1137"  data: no]
Source File: file:///D:/Programme/sunbird/js/calCalendarManager.js
Line: 538
Keywords: regression
Attached patch fixes TZIDsSplinter Review
IMO we may as well consider removing the whole code updating the TZIDs, because the timezone service already resolves "/mozilla.org/*/<Olson-TZID>" fine. It makes sense to keep that behavior even in case we skip the "/mozilla.org/*/" prefix.
After all, IMO we should first fix this quickly (if it's correct, Stefan ;) ), and could remove the code later (I'd like to read Clint's opinion on this).
Assignee: nobody → daniel.boelzle
Status: NEW → ASSIGNED
Attachment #291625 - Flags: review?(ssitter)
Flags: blocking-calendar0.8+
OS: Windows 2000 → All
Hardware: PC → All
Version: Mozilla 1.8 Branch → unspecified
(In reply to comment #2)
> IMO we may as well consider removing the whole code updating the TZIDs, because
> the timezone service already resolves "/mozilla.org/*/<Olson-TZID>" fine.

But does this handles the update of renamed or removed timezones? E.g. the update from "/mozilla.org/20050126_1/America/Louisville" to "/mozilla.org/20070129_1/America/Kentucky/Louisville"?
Yes, the current code resolves the same TZIDs as latestTzid used to and the coming timezones database has to cover (resolve) all those, too. The timezone database can only grow ;) even in case a timezone has vanished from the Olson set, because we rely on that set of timezones to be always resolvable. 
Comment on attachment 291625 [details] [diff] [review]
fixes TZIDs

I'm not that familiar with the storage provider. Moving review to module owner.
Attachment #291625 - Flags: review?(ssitter) → review?(mvl)
Comment on attachment 291625 [details] [diff] [review]
fixes TZIDs

r=mvl
Attachment #291625 - Flags: review?(mvl) → review+
Checked in on HEAD and MOZILLA_1_8_BRANCH.
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → 0.8
STR passed now. Verified using Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8.1.12pre) Gecko/2007121105 Calendar/0.8pre.
Status: RESOLVED → VERIFIED
My problem is similar to this bug.  I have XP and have been using Sunbird 0.3 since last year.  Last week I attempted to rollback my PC settings through System Restore, only to find that SR was corrupted.  This, then, affected Sunbird 0.3.  I have tried reinstalling and opening in Safe Mode, but neither work.  

I have now downloaded v. 0.8, but this will not open, returning the message "Sunbird is already running, but is not responding.  To open a new window, you must first close the existing Sunbird process, or restart your system."  As Sunbird did not appear to be "open" (as mentioned above), I restarted the system.  I get the same response that Sunbird is already open.

I have noticed in Windows Explorer that there are now two program files: Mozilla Sunbird and Mozilla Sunbird (2).  There is still only one Application Data\Mozilla\Sunbird\Profiles under Documents and Settings, which appears to have all my data.  This file is also backed-up.

Any assistance would be appreciated. 
David, have a look if there's a dangling lock file (IIRC .parentlock or similar) in your profile's folder.
Thanks, Daniel, for prompt response, which I have only today been able to pick up.  I am afraid that I am not familiar with the term "dangling lock file," but I have checked the contents of the Documents and Settings profile folder, and the two program profile folders, ie Mozilla Sunbird and Mozilla Sunbird (2), and none appear to indicate that they are IIRC.parentlock or similar, but I may be looking at these incorrectly.  The only file in the two program profile folders are JScript Script Files marked "prefs."  Perhaps you could guide me in respect of what I should be looking for, please.

Regards, David
You need to log in before you can comment on or make changes to this bug.