[Python-checkins] r79704 - python/trunk/Lib/bsddb/__init__.py

benjamin.peterson python-checkins at python.org
Sat Apr 3 17:58:15 CEST 2010


Author: benjamin.peterson
Date: Sat Apr  3 17:58:15 2010
New Revision: 79704

Log:
remove deprecation warnings silence attempting

Modified:
   python/trunk/Lib/bsddb/__init__.py

Modified: python/trunk/Lib/bsddb/__init__.py
==============================================================================
--- python/trunk/Lib/bsddb/__init__.py	(original)
+++ python/trunk/Lib/bsddb/__init__.py	Sat Apr  3 17:58:15 2010
@@ -43,12 +43,11 @@
 absolute_import = (sys.version_info[0] >= 3)
 
 if (sys.version_info >= (2, 6)) and (sys.version_info < (3, 0)) :
+    import warnings
     if sys.py3kwarning and (__name__ != 'bsddb3') :
-        import warnings
         warnings.warnpy3k("in 3.x, the bsddb module has been removed; "
                           "please use the pybsddb project instead",
                           DeprecationWarning, 2)
-    warnings.filterwarnings("*PyCObject*", DeprecationWarning, "_bsddb")
 
 try:
     if __name__ == 'bsddb3':


More information about the Python-checkins mailing list