Closed Bug 604227 Opened 10 years ago Closed 6 years ago

GData Provider can't sync shared calendar with access set to "See only free/busy"

Categories

(Calendar :: Provider: GData, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: jon, Assigned: Fallen)

References

Details

Attachments

(1 file, 1 obsolete file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.2.10) Gecko/20100914 Firefox/3.6.10 (.NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.2.9) Gecko/20100915 Lightning/1.0b2 Thunderbird/3.1.4

TB: 3.1.4 on Win32 and Linux (Ubuntu 10.10)
Lightning: 1.0b2
GData Provider: 0.7.1

If you try to add a shared calendar to Lightning in which you have only "See free/busy" information, the user will continually be prompted for the password and the calendar won't work.  If you add the same calendar via CalDav, the calendar will sync correctly.  The calendar is correctly viewable via the Google Calendar interface.

Reproducible: Always

Steps to Reproduce:
1. add a calendar you have full read/write access to but is not your own calendar
2. add a shared calendar you have full read access to
3. add a shared calendar you have only "full/busy" access to

Really, you only need to do step #3
Actual Results:  
1. after inputting user/password, calendar will sync
2. after inputting user/password, calendar will sync
3. after inputting user/password, TB/Lightning will continue to prompt for the password and will then start to ask for other calendar passwords.  This keeps happening until you delete the calendar and restart Thunderbird.  You will be prompted for the password again, which once entered will allow the other calendars to sync.

Expected Results:  
The calendar should sync, even if it can only show free/busy information.

using Silvermel theme.  I did not try it on the default theme.

Not sure of the severity of the bug -- once you hit it, the software is screwed up until you can hit "cancel" on the password request and then remove the calendar before it tries to log in again.  The rest of your calendars stop working until you restart Thunderbird.
Hmmm...I didn't find this the first time in my search, but it could probably be a dupe of bug 465906.  It may not be though, based on the some of the comments in the bug (about the credentials being wrong).
I think this is a duplicate of bug 465906. But I have this problem as well.
https://bugzilla.mozilla.org/show_bug.cgi?id=598083 started from what appears to be this same problem. I think this is the more appropriate thread and will ask the other be closed.

Confirm. I have this problem too.
When I try adding the calendar as CalDAV it says the calendar is temporarily unavailable. Enabling and re-enabling the calendar causes all calendars to be blank until it is disabled and Lightning restarted (close / reopen tab).

Creating it as a Google Calendar causes Lightning to continuously prompt for password -- even thought it is the same login / password already in use on the other calendars. It continues this until you select Cancel on the password dialog, at which point the calendar data vanishes for all the calendars. It remains blank unless you disable the Google free/busy calendar and restart Lightning (close / open tab).

I first reported this in Bug 598083 2010-09-20 10:28 PDT https://bugzilla.mozilla.org/show_bug.cgi?id=598083
When I add the calendar as iCal it doesn't give and error, but it doesn't show the data either.
1. Added Calendar as google with free/busy only
2. Verified it does not display
3. Changed calendar in google account to See Details
4. Verified calendar displays properly. I get an information box asking if I want to Upgrade one of my calendars in Lightning. I say Yes. After an initial delay, it displays properly.

QED

Something about having a Google Calendar set to free/busy mode interferes with proper authentication or data collection.
John, could you please post your version information in this bug? I will attempt to set up a shared calendar and grant free/busy access to test later today.
From the TBird Add-Ons Manager, Lightning 1.2.1, Provider for Google Calendar 0.9
TBird About Box: v10.0.1
Ubuntu 11.04 natty, 64-bit

I am willing to build/test with other versions if the make file is provided (./configure). I am already way over my head in other projects so I need to be an end user for this one.

I can arrange a calendar to be shared from the same account I had trouble with should the problem not be duplicatable with a pure google account. The account I had trouble with is via google, however it links as https://www.google.com/calendar/ical/(student_login)%40students.ipfw.edu/public/basic.ics

Hope this helps!
Attached file changed calGoogleCalendar.js (obsolete) —
I had the same Problem with TB11.0.1 and Google Calendar 0.9

I solved the Problem with two changes in 
AppData\Roaming\Thunderbird\Profiles\qpuchalh.default\extensions\{a62ef8ec-5fdc-40c2-873c-223b8a6925cc}\js\calGoogleCalendar.js

I changed the RegEx (~line 253)

from

        var re = new RegExp("/calendar/(feeds|ical)/" +
                            "([^/]+)/(public|private)-?([^/]+)?/" +
                            "(full|basic)(.ics)?$");

to

        var re = new RegExp("/calendar/(feeds|ical)/" +
                            "([^/]+)/(public|private)-?([^/]+)?/" +
                            "(full|basic|free-busy)(.ics)?$");


and the mFullUri.path assignment (~line 268)

from

this.mFullUri.path = "/calendar/feeds/" + matches[2] + "/private/full";

to

if (matches[5] == "free-busy") {
   this.mFullUri.path = "/calendar/feeds/" + matches[2] + "/private/free-busy"
}
else {
   this.mFullUri.path = "/calendar/feeds/" + matches[2] + "/private/full";
}


Sorry for that ugly "patch". I added the complete js file as attachment.
I didn't find the source repository, yet. And I have no diff tool on my windows installed.
I Forgot to mention:
I'm not familiar with the code, so somebody should review me changes to avoide possible side effects.
Lorenz, that looks like a very viable fix and the first real progress, other than lots of people confirming they have the same problem, in the last two years. 

I intend to try it again as soon as I have time to set the google calendar appropriately.

Thank-you.
Attachment #616770 - Attachment is obsolete: true
Duplicate of this bug: 598083
Comment on attachment 617207 [details] [diff] [review]
calGoogleCalendar.patch

There was noting requested on this patch, so I'll put it in Philipp's review queue.
Attachment #617207 - Flags: review?(philipp)
Could you check if this works with the provider version linked in bug 493389 comment 60? The Provider will be substantially changing, and I don't really want to further patch the old version.
Comment on attachment 617207 [details] [diff] [review]
calGoogleCalendar.patch

Actually, this won't be fixed in the new version yet. I can apply the first part of the patch without problems, but we will need to check how free-busy only calendars work with the v3 API.

Nevertheless, I will take this from my queue since it doesn't fit in. I've added a TODO note to my code so I don't forget to test this before releasing the new gdata code.
Attachment #617207 - Flags: review?(philipp)
This issue was fixed with the Provider for Google Calendar 1.0.2, I am therefore closing this bug.
Assignee: nobody → philipp
Status: UNCONFIRMED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.