Mailing List Archive

Thunderbird / Lightning and Free/Busy together with DAViCal]
Hi,

Last week, Andrew McMillan replied to a question of mine (to this list)
and I will quote his text:

"That's certainly odd, too, and I suspect it might be an error due to
excessive debugging output causing the error.

I think people have to be very careful enabling debugging. In
particular setting:
$c->dbg['all'] = 1; // Don't do this unless you know what you're doing
can break the server in some cases where a debug log message accesses an
uninitialised variable, and PHP is set to E_ALL.

In such cases the response logging will not be correct, because it has
no knowledge of the earlier error message which caused the headers to be
sent early, etc. Similar issues exist for the case where output starts
early due to characters after a closing tag in the config file.

Perhaps one day I'll catch all of those warnings that happen in debug
messages, but I rarely enable 'all' debug myself, so the odds of me
catching them aren't generally very high.

But in any case, dbg['all'] provides waaaaaaayyy too much information to
be useful for solving setup problems. I generally find
dbg['querystring'] is the most useful starting point, although there are
some specific ones also for debugging authentication issues which can be
useful."

I send you this because you mentioned you started logging the server
when you use the debug option for that you might face some unexpected
behaviour which has nothing to do with your actual problems.

Regards,
Ruud




-------- Original Message --------
Subject: Re: [DAViCal-general] Thunderbird / Lightning and Free/Busy
together with DAViCal
Date: Wed, 14 Oct 2009 15:09:46 +0200
From: Matthias Mohr <MMohr@sysdesign-edv.de>
To: <rscds-general at lists.sourceforge.net>
References: <4AD5AE6B.4090603 at SysDesign-EDV.de> <4AD5B7BC.5090304 at chello.nl>

Hi,

> For logging/debugging Sunbird/Lightning you may want to look at:
>
> https://wiki.mozilla.org/Calendar:QA_CalDAV_Support#Diagnosis_hints
Thanks - I already found it and enabled it.

Now I can see the following in the error console:
"CalDAV: Server does not support scheduling; freebusy query not possible"

Huh?
I thought DAViCal promotes the scheduling extensions as supported?

I also had a look at the packets (with wireshark) and I saw the
following header
(HTTP/1.1 200 OK) as response to an OPTION request (only the relevant
lines):

Shouldn't that be OK?
Or does Lightning need other / additional information?

A response to a PROPFIND also contains the above lines in the header
and additionally this as XML-data (also only relevant lines):

best regards,
Matthias

HELPING HEADS for Hard- and Software
-------------------------------------------------------------------------
Fuer Ihre Projekte entwickeln wir massgeschneiderte Loesungen - schnell,
flexibel und direkt vor Ort. Unser eingespieltes Team an erfahrenen Hard-
und Software-Spezialisten unterstuetzt Sie dort, wo Sie uns brauchen.



--------------------------------------------------------------------------
SysDesign GmbH
Saentisstrasse 25
D-88079 Kressbronn am Bodensee

Geschaeftsfuehrer: Franz Kleiner
Handelsregister: Ulm 632138
--------------------------------------------------------------------------
Thunderbird / Lightning and Free/Busy together with DAViCal] [ In reply to ]
Hi Ruud,

> Last week, Andrew McMillan replied to a question of mine (to this list)
> and I will quote his text:
Thanks for pointing me to that.
But I don't think that excessive logging in DAViCal is the problem
- I switched on the logging because of the problem, not vice versa ;-)
And I also have a productional davical where the logging is completely
switched off and this one also show the same problem as my testing
installation with complete logging...

Although I (currently) no longer think that DAViCal is the problem
- I think some Thunderbird updates (or one of it's plugins) causes
odd behaviour...
I'll retry it with the TB3 - Beta and a corresponding Lightning (Beta) version...

kind regards,
Matthias

HELPING HEADS for Hard- and Software
-------------------------------------------------------------------------
Fuer Ihre Projekte entwickeln wir massgeschneiderte Loesungen - schnell,
flexibel und direkt vor Ort. Unser eingespieltes Team an erfahrenen Hard-
und Software-Spezialisten unterstuetzt Sie dort, wo Sie uns brauchen.



--------------------------------------------------------------------------
SysDesign GmbH
Saentisstrasse 25
D-88079 Kressbronn am Bodensee

Geschaeftsfuehrer: Franz Kleiner
Handelsregister: Ulm 632138
--------------------------------------------------------------------------
Thunderbird / Lightning and Free/Busy together with DAViCal] [ In reply to ]
Hi everybody,

now I tried the same tests with Thunderbird 3 Beta 3 and a corresponding
Lightning 1.0pre (portable version, if that matters).
The resulting behaviour is the same as in TB2/Lightning
(Free-Busy does not work)
but it shows much more logging information than the released version.

so what I see is when (re)loading the calendar, it says
"Calendar generally support calendar-schedule"
and later:
"principal namespace list empty, calendar doesn't support scheduling"
And when I open the invite dialog, it says the well known
"Calendar doen't support scheduling; freebusy query not possible"

Any ideas?


Here is what Thunderbird tells me in its error console (a bit shortened,
but nearly complete):
--------------------------------------------------------------------------
CalDAV: send: <D:propfind xmlns:D="DAV:"
xmlns:CS="http://calendarserver.org/ns/">
<D:prop>
<D:resourcetype/>
<D:owner/>
<CS:getctag/>
</D:prop>
</D:propfind>
--------------------------------------------------------------------------
CalDAV: Status 207 on initial PROPFIND for calendar Mohr, Matthias
--------------------------------------------------------------------------
CalDAV: Authentication scheme for Mohr, Matthias is Basic
--------------------------------------------------------------------------
CalDAV: recv: <?xml version="1.0" encoding="utf-8" ?>
<multistatus xmlns="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav"
xmlns:A="http://calendarserver.org/ns/">
<response>
<href>/caldav/caldav.php/MMohr/home/</href>
<propstat>
<prop>
<resourcetype>
<collection/>
<C:calendar/>
<C:schedule-calendar/>
</resourcetype>
<A:getctag>"32d2a3c90e609ae8c653e335a5420481"</A:getctag>
<owner>
<href>/caldav/caldav.php/MMohr/</href>
</owner>
</prop>
<status>HTTP/1.1 200 OK</status>
</propstat>
</response>
</multistatus>
--------------------------------------------------------------------------
CalDAV: initial ctag "32d2a3c90e609ae8c653e335a5420481" for calendar
Mohr, Matthias
--------------------------------------------------------------------------
CalDAV: send: OPTIONS https://myserver/caldav/caldav.php/MMohr/
--------------------------------------------------------------------------
CalDAV: DAV header: 1, 2, 3, access-control, calendar-access,
calendar-schedule
--------------------------------------------------------------------------
CalDAV: Calendar Mohr, Matthias generally supports calendar-schedule
--------------------------------------------------------------------------
CalDAV: send: PROPFIND https://myserver/caldav/caldav.php/MMohr/
<D:propfind xmlns:D="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav">
<D:prop>
<C:calendar-home-set/>
<C:calendar-user-address-set/>
<C:schedule-inbox-URL/>
<C:schedule-outbox-URL/>
</D:prop>
</D:propfind>
--------------------------------------------------------------------------
CalDAV: recv: <?xml version="1.0" encoding="utf-8" ?>
<multistatus xmlns="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav">
<response>
<href>/caldav/caldav.php/MMohr/</href>
<propstat>
<prop>
<C:calendar-home-set>
<href>/caldav/caldav.php/MMohr/</href>
</C:calendar-home-set>
<C:calendar-user-address-set>
<href>mailto%3AMMohr%40SysDesign-EDV.de</href>
<href>/caldav/caldav.php/MMohr/</href>
</C:calendar-user-address-set>
<C:schedule-inbox-URL>
<href>/caldav/caldav.php/MMohr/.in/</href>
</C:schedule-inbox-URL>
<C:schedule-outbox-URL>
<href>/caldav/caldav.php/MMohr/.out/</href>
</C:schedule-outbox-URL>
</prop>
<status>HTTP/1.1 200 OK</status>
</propstat>
</response>
</multistatus>
--------------------------------------------------------------------------
CalDAV: principal namespace list empty, calendar Mohr, Matthias doesn't
support scheduling
--------------------------------------------------------------------------
...
--------------------------------------------------------------------------
CalDAV: Calendar Mohr, Matthias doen't support scheduling; freebusy
query not possible
--------------------------------------------------------------------------

kind regards,
Matthias
HELPING HEADS for Hard- and Software
-------------------------------------------------------------------------
Fuer Ihre Projekte entwickeln wir massgeschneiderte Loesungen - schnell,
flexibel und direkt vor Ort. Unser eingespieltes Team an erfahrenen Hard-
und Software-Spezialisten unterstuetzt Sie dort, wo Sie uns brauchen.



--------------------------------------------------------------------------
SysDesign GmbH
Saentisstrasse 25
D-88079 Kressbronn am Bodensee

Geschaeftsfuehrer: Franz Kleiner
Handelsregister: Ulm 632138
--------------------------------------------------------------------------
Thunderbird / Lightning and Free/Busy together with DAViCal] [ In reply to ]
CalDAV freebusy seems to be broken in current Lightning code; see
https://bugzilla.mozilla.org/show_bug.cgi?id=504051

I suspect that over and above that the urlencoding of the colon in the
mailto: is confusing Lightning as well.

bb

On 10/14/2009 11:05 AM, Matthias Mohr wrote:
> Hi everybody,
>
> now I tried the same tests with Thunderbird 3 Beta 3 and a corresponding
> Lightning 1.0pre (portable version, if that matters).
> The resulting behaviour is the same as in TB2/Lightning
> (Free-Busy does not work)
> but it shows much more logging information than the released version.
>
> so what I see is when (re)loading the calendar, it says
> "Calendar generally support calendar-schedule"
> and later:
> "principal namespace list empty, calendar doesn't support scheduling"
> And when I open the invite dialog, it says the well known
> "Calendar doen't support scheduling; freebusy query not possible"
>
> Any ideas?
>
>
> Here is what Thunderbird tells me in its error console (a bit shortened,
> but nearly complete):
> --------------------------------------------------------------------------
> CalDAV: send:<D:propfind xmlns:D="DAV:"
> xmlns:CS="http://calendarserver.org/ns/">
> <D:prop>
> <D:resourcetype/>
> <D:owner/>
> <CS:getctag/>
> </D:prop>
> </D:propfind>
> --------------------------------------------------------------------------
> CalDAV: Status 207 on initial PROPFIND for calendar Mohr, Matthias
> --------------------------------------------------------------------------
> CalDAV: Authentication scheme for Mohr, Matthias is Basic
> --------------------------------------------------------------------------
> CalDAV: recv:<?xml version="1.0" encoding="utf-8" ?>
> <multistatus xmlns="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav"
> xmlns:A="http://calendarserver.org/ns/">
> <response>
> <href>/caldav/caldav.php/MMohr/home/</href>
> <propstat>
> <prop>
> <resourcetype>
> <collection/>
> <C:calendar/>
> <C:schedule-calendar/>
> </resourcetype>
> <A:getctag>"32d2a3c90e609ae8c653e335a5420481"</A:getctag>
> <owner>
> <href>/caldav/caldav.php/MMohr/</href>
> </owner>
> </prop>
> <status>HTTP/1.1 200 OK</status>
> </propstat>
> </response>
> </multistatus>
> --------------------------------------------------------------------------
> CalDAV: initial ctag "32d2a3c90e609ae8c653e335a5420481" for calendar
> Mohr, Matthias
> --------------------------------------------------------------------------
> CalDAV: send: OPTIONS https://myserver/caldav/caldav.php/MMohr/
> --------------------------------------------------------------------------
> CalDAV: DAV header: 1, 2, 3, access-control, calendar-access,
> calendar-schedule
> --------------------------------------------------------------------------
> CalDAV: Calendar Mohr, Matthias generally supports calendar-schedule
> --------------------------------------------------------------------------
> CalDAV: send: PROPFIND https://myserver/caldav/caldav.php/MMohr/
> <D:propfind xmlns:D="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav">
> <D:prop>
> <C:calendar-home-set/>
> <C:calendar-user-address-set/>
> <C:schedule-inbox-URL/>
> <C:schedule-outbox-URL/>
> </D:prop>
> </D:propfind>
> --------------------------------------------------------------------------
> CalDAV: recv:<?xml version="1.0" encoding="utf-8" ?>
> <multistatus xmlns="DAV:" xmlns:C="urn:ietf:params:xml:ns:caldav">
> <response>
> <href>/caldav/caldav.php/MMohr/</href>
> <propstat>
> <prop>
> <C:calendar-home-set>
> <href>/caldav/caldav.php/MMohr/</href>
> </C:calendar-home-set>
> <C:calendar-user-address-set>
> <href>mailto%3AMMohr%40SysDesign-EDV.de</href>
> <href>/caldav/caldav.php/MMohr/</href>
> </C:calendar-user-address-set>
> <C:schedule-inbox-URL>
> <href>/caldav/caldav.php/MMohr/.in/</href>
> </C:schedule-inbox-URL>
> <C:schedule-outbox-URL>
> <href>/caldav/caldav.php/MMohr/.out/</href>
> </C:schedule-outbox-URL>
> </prop>
> <status>HTTP/1.1 200 OK</status>
> </propstat>
> </response>
> </multistatus>
> --------------------------------------------------------------------------
> CalDAV: principal namespace list empty, calendar Mohr, Matthias doesn't
> support scheduling
> --------------------------------------------------------------------------
> ...
> --------------------------------------------------------------------------
> CalDAV: Calendar Mohr, Matthias doen't support scheduling; freebusy
> query not possible
> --------------------------------------------------------------------------
>
> kind regards,
> Matthias
> HELPING HEADS for Hard- and Software
> -------------------------------------------------------------------------
> Fuer Ihre Projekte entwickeln wir massgeschneiderte Loesungen - schnell,
> flexibel und direkt vor Ort. Unser eingespieltes Team an erfahrenen Hard-
> und Software-Spezialisten unterstuetzt Sie dort, wo Sie uns brauchen.
>
>
>
> --------------------------------------------------------------------------
> SysDesign GmbH
> Saentisstrasse 25
> D-88079 Kressbronn am Bodensee
>
> Geschaeftsfuehrer: Franz Kleiner
> Handelsregister: Ulm 632138
> --------------------------------------------------------------------------
>
>
Thunderbird / Lightning and Free/Busy together with DAViCal] [ In reply to ]
Hi Andrew,

> The problem was in release 0.9.7.2, and was (as Bruno Browning correctly
> points out) due to my over-enthusiastic URL encoding causing Lightning
> to discard the e-mail address for the principal as unusable.
Well, I don't know if the calDAV RFC says anything about the encoding,
but for me it's not unusual that the strings will be encoded and have to be
decoded by the other side (Lighning).
So I (now) unterstand that the problem started with the changes in 0.9.7.2
- nevertheless I still think that Lightning could use some code which
works with or without URL encoded strings...

> This was fixed in 0.9.7.3, and a further fix for a problem maintaining
> permissions was included in 0.9.7.4, both of which have now been
> publicised further than IRC & twitter (which will inevitably be the
> first to know).
Thanks - I already found the 0.9.7.4 but did not have time to update my installation
(I patched my installation a bit and I don't want to loose these changes - so I have
to reintegrate them in the new version)

BTW, are you interested in the patches?
I don't know if they are relevant for somebody else, but they help here.

One change is for treating all username case insensitive (including configuration
parameter to switch this behaviour on or off)
- this code works well (for our installation - getting the users by LDAP) and should also help others -
but: I had to change one part in libawl which is hardcoded there, because libawl
is unable to detect DAViCal settings...
... I'm not sure how to handle this, so I didn't provide it currently to the public.

Another change is (imho) totally needless for others.
In my installation all group names start with ".Grp" to distinguish between users and groups.
To make them always the first (or last), I changed the postgres sort order (I added a "USING ~<~")

The third change is/was for treating eMail addresses case insensitive.
Most of that change is already present in DAViCal 0.9.7.2 - only one line was missing ;.-)

And another change makes the GUI repsonses when "syncing with LDAP" a bit more logical (for me)
- e.g. it doesn't tell you to deactivate already deactivated users...

My last change is that I totally rewrote the get_permissions PG/SQL method
- I didn't understand the behaviour of the original one, so I defined the behaviour how I wanted it
and the reprogrammed it.
I also added some more convenience PG/SQL methods to query different things
(and also to delete a user with all his resources)
--> nothing special and mostly needless for others ;-)

If you want, I could take some time and create patches for the above and send them to you....

regards,
Matthias

HELPING HEADS for Hard- and Software
-------------------------------------------------------------------------
Fuer Ihre Projekte entwickeln wir massgeschneiderte Loesungen - schnell,
flexibel und direkt vor Ort. Unser eingespieltes Team an erfahrenen Hard-
und Software-Spezialisten unterstuetzt Sie dort, wo Sie uns brauchen.



--------------------------------------------------------------------------
SysDesign GmbH
Saentisstrasse 25
D-88079 Kressbronn am Bodensee

Geschaeftsfuehrer: Franz Kleiner
Handelsregister: Ulm 632138
--------------------------------------------------------------------------