[CalendarServer-users] iMIP replies… (hack solution)

Markus Stürmer Markus.Stuermer at informatik.uni-erlangen.de
Thu Apr 23 04:23:15 PDT 2009


After spending some more time I was able to identify the problem.

The error emerges from file
	CalendarServer/twistedcaldav/scheduling/implicit.py
class ImplicitScheduler's member function
	def extractCalendarData(self)
in line
306                     for item in  
self.originatorPrincipal.calendarUserAddresses():

To be honest, I do not fully understand the interdependencies in DCS.  
But from what I understand the problem arises in that line:
303                 self.originatorPrincipal = (yield  
self.request.locateResource(originatorPrincipalURL))

If I schedule an event, locateResource usually returns an object of  
type "DirectoryCalendarPrincipalResource" describing the  
originator==organizer of the event. I did not verify that, but from  
what I've read every DirectoryCalendarPrincipalResource should have at  
least some urn / guid - type cuaddr-esses and possibly email addresses.

But during imip mail injection, an object of type  
"DirectoryPrincipalResource" is returned which lacks the  
"calenderUserAddresses()" member function (although it is refers to  
the iMIP injection user).

So my workaround was to change
304                 if self.originatorPrincipal:
into
304                 if self.originatorPrincipal and  
hasattr(self.originatorPrincipal,'calendarUserAddresses'):

That way mail injection works, *BUT* I am not sure which problems  
could arise later if self.originator (self is an ImplicitScheduler)  
remains "" as initialized in line 298.

Regards,
Markus


Am 21.04.2009 um 11:00 schrieb Markus Stürmer:

> After some more web searches and experiments…
>
> CALDAV support in Lightning 0.9 is quite incomplete. Lightning  
> 1.0pre is slightly better, but still not complete and quite  
> unstable. So internal inbox/outbox scheduling should not be expected  
> to work for now.
>
> For iCal I noticed that it
> 1) uses SOME email account for sending replies, but not the one the  
> invitation was sent from
> 2) uses the email address given in the Addressbook, not of the  
> invited attendee
>
> After getting that as desired, also iCal reply end up with
>> exceptions.AttributeError: 'DirectoryPrincipalResource' object has  
>> no attribute 'calendarUserAddresses'
>
> I'd really like to know if others have the same error message or if  
> iMIP is working for them without problems.
>
> Regards,
> Markus
>
>
> Am 19.04.2009 um 13:02 schrieb Markus Stürmer:
>
>> Hello!
>>
>> I'm trying to configure DCS on openSUSE 10.3 for a mixed Linux/ 
>> MacOS environment using XML file authentication.
>>
>> There is few information available about DCS / Lightning  
>> interoperability. It seems Lightning does not processing scheduling  
>> requests in the scheduling inbox on the server, and does not send  
>> invitations through DCS either. Was someone sucessful in getting  
>> that working, or is that not yet supported in Lighning?
>>
>> I got the iMIP scheduling in DCS only partially working: Known  
>> users are asked internally (for iCal, see above), and external  
>> users get an invitation email. Problems arise when DCS tries  
>> interpreting and injecting email replies. I use the builtin mail  
>> templates and have enabled plus-addressing on the mail server. I've  
>> added an entry to the XML file for the  com.apple.calendarserver  
>> and the respective GUID to the »principals with "DAV:all" access«.
>>
>>
>> Depending on the client (both most recent version) I use to create  
>> the reply email I get the following errors:
>>
>> Reply created by iCal and sent through Mail:
>> 2009-04-19 10:45:32+0200 [-] [caldav-8081] 	  File "/srv/ 
>> CalendarServer/vdisk/CalendarServer/twistedcaldav/scheduling/ 
>> processing.py", line 144, in doImplicitOrganizer
>> 2009-04-19 10:45:32+0200 [-] [caldav-8081] 	    result = (yield  
>> self.doImplicitOrganizerUpdate())
>> 2009-04-19 10:45:32+0200 [-] [caldav-8081] 	 
>> exceptions.AssertionError: There must be one and only one ATTENDEE  
>> property in a REPLY
>>
>> Reply created by Lightning and sent through Thunderbird:
>> 2009-04-19 10:48:33+0200 [-] [caldav-8081] 	  File "/srv/ 
>> CalendarServer/vdisk/CalendarServer/twistedcaldav/method/ 
>> put_common.py", line 1085, in run
>> 2009-04-19 10:48:33+0200 [-] [caldav-8081] 	    raise err
>> 2009-04-19 10:48:33+0200 [-] [caldav-8081] 	 
>> exceptions.AttributeError: 'DirectoryPrincipalResource' object has  
>> no attribute 'calendarUserAddresses'
>>
>>
>> After adding an cuaddr to the calender user entry, I also got  
>> errors when trying to schedule an event.
>> 2009-04-19 10:58:58+0200 [-] [caldav-8081] 	  File "/srv/ 
>> CalendarServer/vdisk/CalendarServer/twistedcaldav/directory/ 
>> directory.py", line 298, in __init__
>> 2009-04-19 10:58:58+0200 [-] [caldav-8081] 	    assert  
>> len(calendarUserAddresses) == 0
>> 2009-04-19 10:58:58+0200 [-] [caldav-8081] 	 
>> exceptions.AssertionError:
>>
>> And for interpreting Lightning/Thunderbird replies the error  
>> changes to:
>> 2009-04-19 11:06:13+0200 [-] [caldav-8081] 	  File "/srv/ 
>> CalendarServer/vdisk/CalendarServer/twistedcaldav/mail.py", line  
>> 259, in http_POST
>> 2009-04-19 11:06:13+0200 [-] [caldav-8081] 	    yield  
>> self.authorize(request, (caldavxml.ScheduleDeliver(),))
>> 2009-04-19 11:06:13+0200 [-] [caldav-8081] 	 
>> exceptions.AssertionError:
>>
>> Best regards,
>> Markus
>> _______________________________________________
>> calendarserver-users mailing list
>> calendarserver-users at lists.macosforge.org
>> http://lists.macosforge.org/mailman/listinfo.cgi/calendarserver-users
>>
>>
>
> _______________________________________________
> calendarserver-users mailing list
> calendarserver-users at lists.macosforge.org
> http://lists.macosforge.org/mailman/listinfo.cgi/calendarserver-users
>
>



More information about the calendarserver-users mailing list