[CalendarServer-changes] [3567] CalendarServer/trunk/twistedcaldav/directory/appleopendirectory.py

source_changes at macosforge.org source_changes at macosforge.org
Tue Dec 23 10:50:18 PST 2008


Revision: 3567
          http://trac.macosforge.org/projects/calendarserver/changeset/3567
Author:   cdaboo at apple.com
Date:     2008-12-23 10:50:17 -0800 (Tue, 23 Dec 2008)
Log Message:
-----------
Some record types don't support certain attributes. Don't allow that error to cause cache fault failure.

Modified Paths:
--------------
    CalendarServer/trunk/twistedcaldav/directory/appleopendirectory.py

Modified: CalendarServer/trunk/twistedcaldav/directory/appleopendirectory.py
===================================================================
--- CalendarServer/trunk/twistedcaldav/directory/appleopendirectory.py	2008-12-22 20:22:10 UTC (rev 3566)
+++ CalendarServer/trunk/twistedcaldav/directory/appleopendirectory.py	2008-12-23 18:50:17 UTC (rev 3567)
@@ -307,8 +307,15 @@
                 if value in self._storage(recordType)[disabledKey]:
                     continue
 
-                self.reloadCache(recordType, lookup=(lookupKey, value,))
-                record = lookup()
+                try:
+                    self.reloadCache(recordType, lookup=(lookupKey, value,))
+                    record = lookup()
+                except opendirectory.ODError, e:
+                    if e.message[1] == -14140:
+                        # Unsupported attribute on record - don't fail
+                        record = None
+                    else:
+                        raise
 
                 if record is None:
                     self._storage(recordType)[disabledKey].add(value)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20081223/39a18b47/attachment.html>


More information about the calendarserver-changes mailing list