[Zodb-checkins] SVN: ZODB/branches/matt-python-versions/src/ZODB/POSException.py Checkpoint.
matt@zope.com
cvs-admin at zope.org
Thu Nov 20 16:16:59 EST 2008
Log message for revision 93194:
Checkpoint.
Changed:
U ZODB/branches/matt-python-versions/src/ZODB/POSException.py
-=-
Modified: ZODB/branches/matt-python-versions/src/ZODB/POSException.py
===================================================================
--- ZODB/branches/matt-python-versions/src/ZODB/POSException.py 2008-11-20 20:59:33 UTC (rev 93193)
+++ ZODB/branches/matt-python-versions/src/ZODB/POSException.py 2008-11-20 21:16:59 UTC (rev 93194)
@@ -36,20 +36,21 @@
class POSError(StandardError):
"""Persistent object system error."""
- # The 'message' attribute was deprecated for BaseException with
- # Python 2.6; here we create descriptor properties to continue using it
- def __set_message(self, v):
- self.__dict__['message'] = v
+ if sys.version_info[:2] == (2, 6):
+ # The 'message' attribute was deprecated for BaseException with
+ # Python 2.6; here we create descriptor properties to continue using it
+ def __set_message(self, v):
+ self.__dict__['message'] = v
- def __get_message(self):
- return self.__dict__['message']
+ def __get_message(self):
+ return self.__dict__['message']
- def __del_message(self):
- del self.__dict__['message']
+ def __del_message(self):
+ del self.__dict__['message']
- message = property(__get_message, __set_message, __del_message)
+ message = property(__get_message, __set_message, __del_message)
- if sys.version_info[:2] <= (2, 5):
+ if sys.version_info[:2] == (2, 5):
def __reduce__(self):
# Copy extra data from internal structures
state = self.__dict__.copy()
More information about the Zodb-checkins
mailing list