Skip to content
This repository has been archived by the owner. It is now read-only.

CalDAVRevertEntityQueueableOperation failure #231

Closed
macosforgebot opened this issue Jul 16, 2008 · 4 comments
Closed

CalDAVRevertEntityQueueableOperation failure #231

macosforgebot opened this issue Jul 16, 2008 · 4 comments

Comments

@macosforgebot
Copy link

@macosforgebot macosforgebot commented Jul 16, 2008

cabanela@… originally submitted this as ticket:293


I am using the current (revision 2706) trunk of the Calendar Server.

Attempts to add a new item to one of my calendars results in:

"HTTP/1.1 500 Internal Server Error" to operation CalDAVRevertEntityQueueableOperation

No error message get placed in the error.log, however, the last few entries in the access.log are:

199.17.102.218 - JuanCabanela [16/Jul/2008:16:50:24 -0500] "PROPFIND /principals/users/JuanCabanela/ HTTP/1.1" 500 201 "-" "DAVKit/2.0 (10.5.4; wrbt) iCal 3.0.4" [19.3 ms]
199.17.102.218 - JuanCabanela [16/Jul/2008:16:50:24 -0500] "PROPFIND /principals/users/JuanCabanela/ HTTP/1.1" 207 1107 "-" "DAVKit/2.0 (10.5.4; wrbt) iCal 3.0.4" [14.5 ms]
199.17.102.218 - JuanCabanela [16/Jul/2008:16:50:24 -0500] "PROPFIND /principals/users/JuanCabanela/ HTTP/1.1" 207 294 "-" "DAVKit/2.0 (10.5.4; wrbt) iCal 3.0.4" [12.8 ms]
199.17.102.218 - - [16/Jul/2008:16:50:24 -0500] "PUT /calendars/__uids__/juan/54978F4D-C96D-4A1D-BE81-C37C78A06F9D/182C8FDC-CBF6-485D-AC56-3D0AAFD62CA6.ics HTTP/1.1" 500 201 "-" "DAVKit/2.0 (10.5.4; wrbt) iCal 3.0.4" [11.7 ms]

Since I ran 'run' interactively, the screen output is:

2008-07-16 16:50:24-0500 [-] [caldav-8009]  [-] [twisted.web2.dav.method.propfind#error] Error reading property ('urn:ietf:params:xml:ns:caldav', 'calendar-home-set') for resource /principals/users/JuanCabanela/: 
2008-07-16 16:50:24-0500 [-] [caldav-8009]  [-] Exception rendering:
2008-07-16 16:50:24-0500 [-] [caldav-8009]  [-] Unhandled Error
2008-07-16 16:50:24-0500 [-] [caldav-8009]  Traceback (most recent call last):
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 239, in callback
2008-07-16 16:50:24-0500 [-] [caldav-8009]      self._startRunCallbacks(result)
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 304, in _startRunCallbacks
2008-07-16 16:50:24-0500 [-] [caldav-8009]      self._runCallbacks()
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 317, in _runCallbacks
2008-07-16 16:50:24-0500 [-] [caldav-8009]      self.result = callback(self.result, *args, **kw)
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 601, in gotResult
2008-07-16 16:50:24-0500 [-] [caldav-8009]      _deferGenerator(g, deferred)
2008-07-16 16:50:24-0500 [-] [caldav-8009]  --- <exception caught here> ---
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 576, in _deferGenerator
2008-07-16 16:50:24-0500 [-] [caldav-8009]      result = g.next()
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/web2/dav/method/propfind.py", line 164, in http_PROPFIND
2008-07-16 16:50:24-0500 [-] [caldav-8009]      status = statusForFailure(f, "getting property: %s" % (property,))
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/web2/dav/http.py", line 319, in statusForFailure
2008-07-16 16:50:24-0500 [-] [caldav-8009]      failure.raiseException()
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/web2/dav/method/propfind.py", line 158, in http_PROPFIND
2008-07-16 16:50:24-0500 [-] [caldav-8009]      resource_property = resource_property.getResult()
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 555, in getResult
2008-07-16 16:50:24-0500 [-] [caldav-8009]      self.result.raiseException()
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/python/failure.py", line 303, in raiseException
2008-07-16 16:50:24-0500 [-] [caldav-8009]      raise self.type, self.value, self.tb
2008-07-16 16:50:24-0500 [-] [caldav-8009]  exceptions.AssertionError: 
2008-07-16 16:50:24-0500 [-] [caldav-8009]  
2008-07-16 16:50:24-0500 [-] [caldav-8009]  [AMP,client] Exception rendering:
2008-07-16 16:50:24-0500 [-] [caldav-8009]  [AMP,client] Unhandled Error
2008-07-16 16:50:24-0500 [-] [caldav-8009]  Traceback (most recent call last):
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/web2/server.py", line 314, in _getChild
2008-07-16 16:50:24-0500 [-] [caldav-8009]      result = res.locateChild(self, path)
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/CalendarServer/twistedcaldav/directory/resource.py", line 62, in locateChild
2008-07-16 16:50:24-0500 [-] [caldav-8009]      d.addCallback(lambda _: self.provisionChild(name))
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 191, in addCallback
2008-07-16 16:50:24-0500 [-] [caldav-8009]      callbackKeywords=kw)
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 182, in addCallbacks
2008-07-16 16:50:24-0500 [-] [caldav-8009]      self._runCallbacks()
2008-07-16 16:50:24-0500 [-] [caldav-8009]  --- <exception caught here> ---
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/Twisted/twisted/internet/defer.py", line 317, in _runCallbacks
2008-07-16 16:50:24-0500 [-] [caldav-8009]      self.result = callback(self.result, *args, **kw)
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/CalendarServer/twistedcaldav/directory/resource.py", line 62, in <lambda>
2008-07-16 16:50:24-0500 [-] [caldav-8009]      d.addCallback(lambda _: self.provisionChild(name))
2008-07-16 16:50:24-0500 [-] [caldav-8009]    File "/usr/local/DarwinCalendarServer/CalendarServer/twistedcaldav/static.py", line 500, in provisionChild
2008-07-16 16:50:24-0500 [-] [caldav-8009]      assert len(name) > 4
2008-07-16 16:50:24-0500 [-] [caldav-8009]  exceptions.AssertionError: 
2008-07-16 16:50:24-0500 [-] [caldav-8009]  

Any ideas?

@macosforgebot
Copy link
Author

@macosforgebot macosforgebot commented Jul 17, 2008

@wsanchez originally submitted this as comment:1:⁠ticket:293

  • Description modified
@macosforgebot
Copy link
Author

@macosforgebot macosforgebot commented Jul 17, 2008

@wsanchez originally submitted this as comment:2:⁠ticket:293

  • Status changed from new to assigned

(error.log doesn't get any output with using the ./run script; output goes to the tty instead.)

This appears to be the important bit:

2008-07-16 16:50:24-0500 [-] [caldav-8009]       File "/usr/local/DarwinCalendarServer/CalendarServer/twistedcaldav/static.py", line 500, in provisionChild
2008-07-16 16:50:24-0500 [-] [caldav-8009]      assert len(name) > 4
2008-07-16 16:50:24-0500 [-] [caldav-8009]  exceptions.AssertionError: 
@macosforgebot
Copy link
Author

@macosforgebot macosforgebot commented Jul 17, 2008

@wsanchez originally submitted this as comment:3:⁠ticket:293

  • Status changed from assigned to closed
  • Resolution set to worksforme

This happens if the GUID for an account doesn't have at least 4 characters in it. GUIDs have a specific format (for example, 3b3b4553-0d5a-40e3-849a-1e5239af2f75) which must be used.

That said, we do cheat in the conf/accounts-test.xml file and used GUIDs in there which are, in fact, invalid GUIDs. That's because of some expectations in CalDAVTester which need to be fixed.

So I'm going to assume that you saw this bad example and did something similar with your XML file. I recommend that you not enter <guid> elements into the accounts XML file, in which case the server will generate GUIDs based on the realm name (<accounts realm="Test Realm">) and the <uid> element value. This is safe as long as you don't change the realm name or UIDs. Otherwise, use valid GUIDs.

Re-open this if I'm not right about what's going on here.

@macosforgebot
Copy link
Author

@macosforgebot macosforgebot commented Jul 18, 2008

cabanela@… originally submitted this as comment:4:⁠ticket:293


Replying to wsanchez@apple.com:

This happens if the GUID for an account doesn't have at least 4 characters in it. GUIDs have a specific format (for example, 3b3b4553-0d5a-40e3-849a-1e5239af2f75) which must be used.

Actually, from the phrasing, looks like it needs >4 characters, not >=4. I say this because my GUID had four letters in it.

I removed the GUIDS from my accounts.xml file as you suggested, but the server simply doesn't serve information in this case. Its a different error, so I will open another ticket.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.