[Zope-Checkins] SVN: Zope/trunk/lib/python/App/Product.py Removed a
warning at Zope startup.
Florent Guillaume
fg at nuxeo.com
Thu Jun 1 07:59:23 EDT 2006
Log message for revision 68439:
Removed a warning at Zope startup.
Changed:
U Zope/trunk/lib/python/App/Product.py
-=-
Modified: Zope/trunk/lib/python/App/Product.py
===================================================================
--- Zope/trunk/lib/python/App/Product.py 2006-06-01 11:58:47 UTC (rev 68438)
+++ Zope/trunk/lib/python/App/Product.py 2006-06-01 11:59:22 UTC (rev 68439)
@@ -42,7 +42,7 @@
import Globals, OFS.Folder, OFS.SimpleItem, Acquisition, Products
from Globals import InitializeClass
-import ZClasses, AccessControl.Owned
+import AccessControl.Owned
from OFS.Folder import Folder
from HelpSys.HelpSys import ProductHelp
from AccessControl import Unauthorized
@@ -53,6 +53,17 @@
import RefreshFuncs
from App.config import getConfiguration
+# BBB: ZClasses are deprecated but we don't want the warning to appear here
+import warnings
+warnings.filterwarnings('ignore', message='^ZClasses', append=1)
+try:
+ import ZClasses
+finally:
+ del warnings.filters[-1]
+ try:
+ del __warningregistry__
+ except NameError:
+ pass
class ProductFolder(Folder):
"Manage a collection of Products"
More information about the Zope-Checkins
mailing list