[Zope-Checkins] SVN: Zope/branches/2.10/lib/python/App/Product.py
Removed a warning at Zope startup.
Florent Guillaume
fg at nuxeo.com
Thu Jun 1 07:58:48 EDT 2006
Log message for revision 68438:
Removed a warning at Zope startup.
Changed:
U Zope/branches/2.10/lib/python/App/Product.py
-=-
Modified: Zope/branches/2.10/lib/python/App/Product.py
===================================================================
--- Zope/branches/2.10/lib/python/App/Product.py 2006-06-01 11:57:17 UTC (rev 68437)
+++ Zope/branches/2.10/lib/python/App/Product.py 2006-06-01 11:58:47 UTC (rev 68438)
@@ -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