[CalendarServer-changes] [8350] CalendarServer/trunk/txdav/common/datastore/upgrade/sql/upgrade.py

source_changes at macosforge.org source_changes at macosforge.org
Tue Nov 29 14:23:57 PST 2011


Revision: 8350
          http://trac.macosforge.org/projects/calendarserver/changeset/8350
Author:   sagen at apple.com
Date:     2011-11-29 14:23:57 -0800 (Tue, 29 Nov 2011)
Log Message:
-----------
Catch either RuntimeError or ValueError

Modified Paths:
--------------
    CalendarServer/trunk/txdav/common/datastore/upgrade/sql/upgrade.py

Modified: CalendarServer/trunk/txdav/common/datastore/upgrade/sql/upgrade.py
===================================================================
--- CalendarServer/trunk/txdav/common/datastore/upgrade/sql/upgrade.py	2011-11-29 03:27:44 UTC (rev 8349)
+++ CalendarServer/trunk/txdav/common/datastore/upgrade/sql/upgrade.py	2011-11-29 22:23:57 UTC (rev 8350)
@@ -147,7 +147,7 @@
             actual_version = yield sqlTxn.calendarserverValue(self.versionKey)
             actual_version = int(actual_version)
             yield sqlTxn.commit()
-        except RuntimeError, ValueError:
+        except (RuntimeError, ValueError):
             self.log_error("Database key %s cannot be determined." % (self.versionKey,))
             yield sqlTxn.abort()
             if self.defaultKeyValue is None:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20111129/4ea621a0/attachment.html>


More information about the calendarserver-changes mailing list