[Zodb-checkins] CVS: ZODB4/src/zodb/storage - base.py:1.29.6.2

Jeremy Hylton jeremy at zope.com
Thu Jun 19 12:09:12 EDT 2003


Update of /cvs-repository/ZODB4/src/zodb/storage
In directory cvs.zope.org:/tmp/cvs-serv23095

Modified Files:
      Tag: ZODB3-2-merge
	base.py 
Log Message:
Put the stub DB class back, but fix comment to refer to MemoryStorage.


=== ZODB4/src/zodb/storage/base.py 1.29.6.1 => 1.29.6.2 ===
--- ZODB4/src/zodb/storage/base.py:1.29.6.1	Thu Jun 19 10:58:28 2003
+++ ZODB4/src/zodb/storage/base.py	Thu Jun 19 11:09:11 2003
@@ -36,6 +36,15 @@
     berkeley_is_available = True
 except ImportError:
     berkeley_is_available = False
+    # But, MemoryStorage piggybacks on the implementation of BDBFullStorage so
+    # create a fake db object that has some useful constants.
+    class db:
+        DB_QUEUE = 1
+        DB_DUP = 2
+        DB_FORCE = 3
+
+        class DBNotFoundError(Exception): pass
+        class DBKeyEmpty(Exception): pass
 
 from zodb.conflict import ConflictResolver
 from zodb.timestamp import newTimeStamp, TimeStamp




More information about the Zodb-checkins mailing list