[CalendarServer-changes] [1702] CalendarServer/branches/release/CalendarServer-1.0-dev/twistedcaldav /method/report_common.py

source_changes at macosforge.org source_changes at macosforge.org
Fri Jul 20 17:02:58 PDT 2007


Revision: 1702
          http://trac.macosforge.org/projects/calendarserver/changeset/1702
Author:   wsanchez at apple.com
Date:     2007-07-20 17:02:58 -0700 (Fri, 20 Jul 2007)

Log Message:
-----------
Pulled up r1697 from trunk.

Modified Paths:
--------------
    CalendarServer/branches/release/CalendarServer-1.0-dev/twistedcaldav/method/report_common.py

Modified: CalendarServer/branches/release/CalendarServer-1.0-dev/twistedcaldav/method/report_common.py
===================================================================
--- CalendarServer/branches/release/CalendarServer-1.0-dev/twistedcaldav/method/report_common.py	2007-07-20 22:48:59 UTC (rev 1701)
+++ CalendarServer/branches/release/CalendarServer-1.0-dev/twistedcaldav/method/report_common.py	2007-07-21 00:02:58 UTC (rev 1702)
@@ -341,8 +341,14 @@
             continue
 
         calendar = calresource.iCalendar(name)
-        assert calendar is not None, "Calendar %s is missing from calendar collection %r" % (name, calresource)
         
+        # The calendar may come back as None if the resource is being changed, or was deleted
+        # between our initial index query and getting here. For now we will ignore this errror, but in
+        # the longer term we need to simplement some form of locking, perhaps.
+        if calendar is None:
+            log.err("Calendar %s is missing from calendar collection %r" % (name, calresource))
+            continue
+        
         # Ignore ones of this UID
         if excludeuid:
             # See if we have a UID match

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20070720/720b5456/attachment.html


More information about the calendarserver-changes mailing list