[Python-3000-checkins] r61154 - python/branches/py3k/Lib/bsddb/__init__.py
neal.norwitz
python-3000-checkins at python.org
Sat Mar 1 05:06:19 CET 2008
Author: neal.norwitz
Date: Sat Mar 1 05:06:19 2008
New Revision: 61154
Modified:
python/branches/py3k/Lib/bsddb/__init__.py
Log:
When the _iter_mixin stopped inheritting from UsserDictMixin, it lost the
__repr__ which caused bsddb.test.test_misc.py to fail in test03_repr_closed_db
Restore the repr so the test passes. I think this is correct, but it would
be good to have some more review.
Modified: python/branches/py3k/Lib/bsddb/__init__.py
==============================================================================
--- python/branches/py3k/Lib/bsddb/__init__.py (original)
+++ python/branches/py3k/Lib/bsddb/__init__.py Sat Mar 1 05:06:19 2008
@@ -170,6 +170,9 @@
def __del__(self):
self.close()
+ def __repr__(self):
+ return repr(dict(self.iteritems()))
+
def _checkCursor(self):
if self.dbc is None:
self.dbc = _DeadlockWrap(self.db.cursor)
More information about the Python-3000-checkins
mailing list