Closed Bug 365812 Opened 18 years ago Closed 17 years ago

Time zone error from a Google calendar

Categories

(Calendar :: Internal Components, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 314339

People

(Reporter: mail.lists, Unassigned)

References

Details

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1
Build Identifier: Lightning 0.4a1 20070103

I have Lightning pointed at my Google calendars using the private iCal URL provided by Google. Everytime I start Thunderbird (and thus Lightning) I get a popup with an error message:

"There has been an error reading data for calendar: School. It has been placed in read-only mode, since changes to this calendar will likely result in data-loss. You may change this setting by choosing 'Edit Calendar'."

Clicking on the Details button reveals:
INVALID_TIMEZONE
[Exception... "Component returned failure code: 0x804a0001 [calIRecurrenceItem.icalProperty]"  nsresult: "0x804a0001 (<unknown>)"  location: "JS frame :: file:///C:/Documents%20and%20Settings/Sean/Application%20Data/Thunderbird/Profiles/koye8x8v.default/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/js/calItemBase.js :: anonymous :: line 574"  data: no]

This has been occurring for some time now. I waited for the release of 0.3 to see if it might be fixed, but it is still there.

I am unwilling to post the URL for this calendar in this public forum, but if someone on the development team wants to contact me, I am happy to respond to an email request.

For the record, I prefer Google's time honored method of selecting a time zone by simply picking your time zone. Lightning's method of picking a time zone by selecting a city is, IMHO, rather a pain if your city is not on the list. Surely people know what time zone they are living in.

-Sean

Reproducible: Always

Steps to Reproduce:
1.
2.
3.



I have several calendars defined at Google. I have Lightning pointing to all of them. I only get this error for a single calendar. If I unsubscribe from that calendar the error goes away, even though other calendars remain. All calendars are set to the same time zone (Mountain GMT -7). The calendar that is causing the issue is the primary or default calendar. I know Google treats the default calendar differently from additional calendars. For example, currently alarms only work on the default calendar. 

The error details mention 'calIRecurrenceItem' which suggests an issue with recurring items. I do have recurring items in other calendars. However, the calendar in question is the only calendar with weekly recurring items (my school schedule). In all other calendars, what recurring items exist are yearly.

It is possible this is a Google bug, but I don't know what information is coming in v. what information you are looking for.

I prefer to have my calendar stored on Google in the event I am at work and do not have access to Lightning, I can still check my calendar when necessary.
Adding Philipp because he is the Google Calendar expert.
OS: Windows XP → All
Hardware: PC → All
I am having the same problem on OpenSuse 10.2, using Thunderbird 2.0 beta 2 and Lightening extension 3.1.  I have weekly occurring items on my calendar and only when I load the calendar containing those items does the error occur.
see also bug 314339 and bug 357704. 
Adding Qawanted in order to see if we can determine if this is a foreign timezone issue or a unrecognized TZID issue (like the old quoted TZID problem).
Keywords: qawanted
I am using Eastern time on all my calendars.  I tried testing with a new calendar with several weekly occuring items, and I couldn't reproduce the error.  I haven't tried all possible combinations, however. (In fact, one test I haven't tried is recurring all day events that occur on days with specific items). If you would like the address for my calendar which is causing the problems please email me. 
I am still not able to repeat the failure other than on my personal calendar.
Paul, could you send me the contents of the calendar that is causing problems per email?

Also, Sean, did you ever get my second mail regarding your calendar? I haven't heard from you for a while.
There's a difference in the TRZ-definitions, trying to figure them out...

Generated by mozilla:
BEGIN:VTIMEZONE
TZID:/mozilla.org/20070129_1/America/New_York
X-LIC-LOCATION:America/New_York
BEGIN:DAYLIGHT
TZOFFSETFROM:-0500
TZOFFSETTO:-0400
TZNAME:EDT
DTSTART:19700308T020000
RRULE:FREQ=YEARLY;INTERVAL=1;BYDAY=2SU;BYMONTH=3
END:DAYLIGHT
BEGIN:STANDARD
TZOFFSETFROM:-0400
TZOFFSETTO:-0500
TZNAME:EST
DTSTART:19701101T020000
RRULE:FREQ=YEARLY;INTERVAL=1;BYDAY=1SU;BYMONTH=11
END:STANDARD
END:VTIMEZONE

generated by google:
BEGIN:VTIMEZONE
TZID:America/New_York
X-LIC-LOCATION:America/New_York
BEGIN:STANDARD
TZOFFSETFROM:-0400
TZOFFSETTO:-0500
TZNAME:EST
DTSTART:19701025T020000
RRULE:FREQ=YEARLY;BYMONTH=10;BYDAY=-1SU
END:STANDARD
BEGIN:DAYLIGHT
TZOFFSETFROM:-0500
TZOFFSETTO:-0400
TZNAME:EDT
DTSTART:19700405T020000
RRULE:FREQ=YEARLY;BYMONTH=4;BYDAY=1SU
END:DAYLIGHT
END:VTIMEZONE
Mozilla: second sunday of march, first sunday of november
Google: first sunday of april, last sunday of october

The changes:
http://www.timeanddate.com/news/time/us-daylight-saving-extended.html

which means Mozilla got them right and google (or at least the file Paul sent) still got the old timezonedefinitions. Just tested this with my own account on google (hasn't been connected to Sunbird/Lightning even once) which gave the same results for the VTIMEZONE. Google claims it has the correct definitions:
http://www.google.com/support/calendar/bin/answer.py?answer=61026&ctx=sibling

but apparantly somewhere in the line (perhaps some of their servers) got it wrong... I'm suggesting setting to invalid...  
Attached file ics-file from google —
Newly exported ics-file from google, has incorrect definitions for America/New_York TZ
That might help explain the other bug I posted, Bug 373139.  
Actually that is bug 373139. I haven't been able to reproduce the INVALID_TIMEZONE from the original submitter. If I unset the google-calendar ics (without googleprovider) to readonly and try to add an event, it fires a 404 file-not-found. Can someone reproduce the original bug? 
Attached file Testcase with EXDATES —
In both Sean's and Paul's file, I also noticed that there were some EXDATEs with the /mozilla.org/20050126_1/America/New_York and /mozilla.org/20050126_1/America/Boise timezones. I believe the calendar was imported to Google via their import function.

Google should handle these timezones somehow when importing, either by including mozilla's timezone definition or using their own.

This is also the reason the INVALID_TIMEZONE error is showing up. I have attached a testcase that was extracted from Sean's calendar file. It contains the original timezone information provided by google and the event with the bogus exdates.

Sean's calendar also contains the same timezone definition Bas investigated. I am posting to the Google newsgroup that they should investigate this issue.

I think this bug can be marked as INVALID, since Google is producing invalid rfc2445. The only other option would be to make Sunbird/Lightning be more forgiving regarding timezone definitions, but that deserves an extra bug.
On my behalf, I can say that my calendar wasn't imported into Google.  
Agree with Phillip: RFC2445 states all VTIMEZONE's used in an ics must be defined. So marking Invalid or Wontfix would be a good thing. Of course we could choose to stripe all timezonedata which isn't defined as a workaround (for exdates, alarms etc) but actually this is something google should solve. We have bug 369263 for this, which is a dupe of 370079. I think it would be helpfull if times without corresponding timezones would be converted (after confirmation) to the application timezone. 

As for Paul's problem, even when the timezone would be preserved (bug 314339 and  bug 355449), it's a doublure with incorrect definitions on google's side. We could rewrite the VTIMEZONE with the SB definition if it already exists but this doesn't seem to be a good thing to do. Google should fix their timezones -> Wontfix for this bug and bug 373139 I think.
added a bug in google-code referring to this bug:
http://code.google.com/p/google-gdata/issues/detail?id=54
Keywords: qawanted
Whiteboard: [qa discussion needed]
Paul, if you didn't import your calendar into Google, how were you able to create exceptions that use a mozilla timezone? Did you maybe use a different programm to sync your calendar with google?

Could you (and also Sean) please answer on Ryan's post on [1]? It would be interesting to know how those timezones got into the ical feed.


[1] http://groups.google.com/group/google-calendar-help-dataapi/browse_thread/thread/d48ff1a9ef876fe2
If you go into manage calendars and select a calendar, Google gives several URLs at the bottom of the options that produce output in various formats. I simply point Lightning at the private ICAL URL(s). Works great, with this obvious exception.

If the issue is timezone definitions why is it only the "main" google calendar produces this error? I have nine different calendars defined on Google and "imported" into Lightening. Only the main calendar, the one I sent to Philipp, produces this error. The other calendars do not. 

-Sean
I did the same thing as Sean did.  
Sean, there's two errors. The error concerning the invalid timezone is caused by one of your event which has EXDATES, you have a recurring event with exceptions in that calendar. Somehow you created an recurring event, switched timezones and set exceptions to the event or you set the exceptions in another client which doesn't have the America/New_York timezone defined (neither google nor sunbird/lightning has an interface for exceptions, don't know which program you used to create this event). 

So, as a fix, you could export your calendar to an ics-file, open this is a texteditor and search which events have EXDATES. Then in Google calendar delete these events and recreate them (while not switching timezone's). Also you could edit the events in the texteditor, changing the undefined timezones to defined ones (best is the main timezone which is defined in the ics) and then import these to a new calendar. This will most likely get rid of the import-error you mention in comment 1. 

As for the incorrect definition of eastern time by google, this has to be solved by google. What you could try to do is export the ICS and replace all occurences of America/New_York in events (not the definition of the timezone itself, so look for "=America/New_York") with /mozilla.org/20070129_1/America/New_York (our definition). I don't know how google handles foreign timezones though, this is something you should try. If you changed the occurences in all events then you can delete the google-defintion of TZID:America/New_York and import the calendar in google. 

Please let uw know if this worked as a fix... 
Status: UNCONFIRMED → NEW
Ever confirmed: true
That makes sense and that would probably work as a fix, but I don't know how practical it is. The reason I started using Google was because I am occasionally in a situation when I don't have my laptop, but still need to look at my calendar, at work for example. I was hoping that I could edit events in my Google calendar from Lightening, but I haven't tried yet, because of the errors.  That would be very cool.

At any rate, Google does have a way to create an exception. When you edit a recurring event, it asks you (just like Outlook) if your edits apply to the whole series or just that date. Obviously their exception code has problems if it isn't maintaining the timezone properly, because timezone is something you set when you create the calendar itself, not when you create events in the calendar and my calendar is configured for U.S. Mountain, not U.S. Eastern. 

When setting a timezone in Google you pick your country then you pick your relevant timezone, which I find much more intuitive that Lightening's method of picking a city. That just seems awkward to me unless you have a database that has every major city in the world and its timezone. Major would also have to be defined by local standards. For example Boise, ID can hardly be considered a major city from a global perspective, but it is the largest city in Idaho. I live in Utah, so I end up picking Denver as my timezone. Why can't I just pick Mountain? Mountain is my timezone. Denver is not where I live. It's a nit picky thing, I know.

Thanks, folks, for looking into this. Appreciate your hard work.

-Sean
Sean, so how do you create events and set exceptions on your Google Calendar? Only by using the UI Google provides? And there was no point in time where you imported any amount of events via the Google UI?

The calendar you sent me contains exceptions that use a timezone from sunbird/lightning. The only way these timezones can get into Google would be to add events via the import function in their UI or to add them using the API. If you did not use the API directly, maybe you used a program that uses the API to add events and exceptions to your Google Calendar.

You must have used either of these methods, there is no other way I can think of that these timezones made it into Google. That might also explain why it only happens to the default calendar. 

If you remember how you added those events, please post on the google newsgroup. Otherwise I see no other possibility other than using the workaround Bas suggested or waiting for a fix from Google (which usually takes a while).

If you would like to edit events from within lightning, you must use the GData Calendar Provider [1]. It has some limitations that might keep you from using it with all your calendars and it is not availible from AMO yet. If you would still like to test the provider and cannot build it from source, I can provide you with a prebuilt package. Drop me an email in that case.
On the GDATA-page is a link to the download of the prebuilt package (Philipp, I thought you added that...): http://cmtalbert.googlepages.com/home
I honestly don't remember if I tried exporting from Lightning and then importing to Google or not. It's possible, maybe even likely. If I dumped all the events in that calendar and created them from scratch in Google, would that make a difference?

Thanks for the info on the GDATA provider. I'll keep an eye on it.

-Sean
I can confidently say that I never imported the calendar into Google.  I am look at some of the events that have odd EXDATE information and it seems really strange.  
Here is a snippet of one:

BEGIN:VEVENT
DTSTART;TZID=America/New_York:20060915T140000
DTEND;TZID=America/New_York:20060915T170000
RRULE:FREQ=WEEKLY;BYDAY=FR;UNTIL=20061111T190000Z
EXDATE;TZID=/mozilla.org/20050126_1/America/New_York:20061020T140000
EXDATE;TZID=/mozilla.org/20050126_1/America/New_York:20061110T140000
EXDATE;TZID=America/New_York:20061103T140000
EXDATE;TZID=America/New_York:20061110T140000
EXDATE;TZID=America/New_York:20061020T140000
DTSTAMP:20070316T145323Z
ORGANIZER;CN=Paul Burns:MAILTO:paul.h.burns@gmail.com
UID:{f51ab8e1-e80b-46f7-9723-957ed791bbc5}
CLASS:PRIVATE
CREATED:20060928T040040Z
DESCRIPTION:
LAST-MODIFIED:20061013T034533Z
LOCATION:CNS
SEQUENCE:9
STATUS:TENTATIVE
SUMMARY:Work
TRANSP:OPAQUE
END:VEVENT

There are two exceptions for Nov 10th, 2006. Also, all my editing has been using Google's interface, so I'm not sure where the TZID for mozilla.org could have entered into it back then.  

And to repeat Sean's sentiments, thanks everyone for helping with this.

-Paul
Sean, it would definitely help but would be too much work (unless your calendar has few items). I would start with exporting to ics, delete all EXDATES with foreign timezones and then import into google. 
After some discussion we have basically determined that this is essentially two issues. 
Issue 1: bug 373139 which is a google issue, and is being addressed by Google.

Issue 2: Our "foreign timezone" issue, which is bug 314339.

So, I am setting this as a duplicate of 314339. Please re-test this once both these issues are resolved and ensure that this problem was adequately addressed.
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → DUPLICATE
Whiteboard: [qa discussion needed]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: