summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: bd8cdea)
raw | patch | inline | side by side (parent: bd8cdea)
author | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Tue, 23 Feb 2010 22:54:59 +0000 (22:54 +0000) | ||
committer | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Tue, 23 Feb 2010 22:54:59 +0000 (22:54 +0000) |
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/roundup/trunk@4466 57a73879-2fb5-44c3-a270-3262357dd7e2
roundup/anypy/dbm_.py | [new file with mode: 0644] | patch | blob |
diff --git a/roundup/anypy/dbm_.py b/roundup/anypy/dbm_.py
--- /dev/null
+++ b/roundup/anypy/dbm_.py
@@ -0,0 +1,12 @@
+# In Python 3 the "anydbm" module was renamed to be "dbm" which is now a
+# package containing the various implementations. The "wichdb" module's
+# whichdb() function was moved to the new "dbm" module.
+
+try:
+ # old school first because <3 had a "dbm" module too...
+ import anydbm
+ from whichdb import whichdb
+except ImportError:
+ # python 3+
+ import dbm as anydbm
+ whichdb = anydbm.whichdb