[CalendarServer-changes] [2294] CalendarServer/branches/release/CalendarServer-1.3-dev/twistedcaldav /ical.py

source_changes at macosforge.org source_changes at macosforge.org
Thu Apr 10 02:23:15 PDT 2008


Revision: 2294
          http://trac.macosforge.org/projects/calendarserver/changeset/2294
Author:   wsanchez at apple.com
Date:     2008-04-10 02:23:14 -0700 (Thu, 10 Apr 2008)

Log Message:
-----------
Pull up r2284: iCalendar parse failure when recurrence instance is first

Modified Paths:
--------------
    CalendarServer/branches/release/CalendarServer-1.3-dev/twistedcaldav/ical.py

Modified: CalendarServer/branches/release/CalendarServer-1.3-dev/twistedcaldav/ical.py
===================================================================
--- CalendarServer/branches/release/CalendarServer-1.3-dev/twistedcaldav/ical.py	2008-04-09 21:02:59 UTC (rev 2293)
+++ CalendarServer/branches/release/CalendarServer-1.3-dev/twistedcaldav/ical.py	2008-04-10 09:23:14 UTC (rev 2294)
@@ -846,6 +846,7 @@
         component_id  = None
         timezone_refs = set()
         timezones     = set()
+        got_master    = False
         
         for subcomponent in self.subcomponents():
             # Disallowed in CalDAV-Access-08, section 4.1
@@ -876,8 +877,11 @@
                         raise ValueError("Calendar resources may not contain components with different UIDs " +
                                          "(%s and %s found)" % (component_id, subcomponent.propertyValue("UID")))
                     elif subcomponent.propertyValue("Recurrence-ID") is None:
-                        raise ValueError("Calendar resources may not contain components with the same UIDs and no Recurrence-IDs" +
-                                         "(%s and %s found)" % (component_id, subcomponent.propertyValue("UID")))
+                        if got_master:
+                            raise ValueError("Calendar resources may not contain components with the same UIDs and no Recurrence-IDs" +
+                                             "(%s and %s found)" % (component_id, subcomponent.propertyValue("UID")))
+                        else:
+                            got_master = True
         
                 timezone_refs.update(subcomponent.timezoneIDs())
         

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20080410/5a4b8664/attachment.html


More information about the calendarserver-changes mailing list