[Zope3-checkins]
SVN: Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py
Stacklevel 2 doesn't make much sense in warnings within ZCML
handlers. I'd rather
Philipp von Weitershausen
philikon at philikon.de
Sat Feb 18 07:10:20 EST 2006
Log message for revision 41658:
Stacklevel 2 doesn't make much sense in warnings within ZCML handlers. I'd rather
have the ZCML filename and line no. be stated, not the Python module. Perhaps later.
Changed:
U Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py
-=-
Modified: Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py
===================================================================
--- Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py 2006-02-18 11:06:02 UTC (rev 41657)
+++ Zope3/branches/philikon-simplify-skinning/src/zope/app/publisher/browser/metaconfigure.py 2006-02-18 12:10:20 UTC (rev 41658)
@@ -165,8 +165,7 @@
'Creating layers via ZCML has been deprecated. The browser:layer '
'directive will be removed in Zope 3.5. Layers are now interfaces '
'extending zope.publisher.interfaces.browser.IBrowserRequest. '
- 'They do not need further registration.',
- DeprecationWarning, stacklevel=2)
+ 'They do not need further registration.', DeprecationWarning)
interface = InterfaceClass(str(name), (base, ),
__doc__='Layer: %s' %str(name),
__module__='zope.app.layers')
@@ -179,7 +178,7 @@
warnings.warn(
'Layer interfaces do not require registration anymore. The '
'browser:layer directive will be removed in Zope 3.5.',
- DeprecationWarning, stacklevel=2)
+ DeprecationWarning)
path = interface.__module__ + '.' + interface.getName()
# If a name was specified, make this layer available under this name.
@@ -285,7 +284,7 @@
'directive will be removed in Zope 3.5. Skins are now interfaces '
'extending zope.publisher.interfaces.browser.IBrowserRequest. '
'They are registered using the \'interface\' directive.',
- DeprecationWarning, stacklevel=2)
+ DeprecationWarning)
interface = InterfaceClass(str(name), layers,
__doc__='Skin: %s' %str(name),
__module__='zope.app.skins')
@@ -314,8 +313,7 @@
' interface="%s"\n'
' type="zope.publisher.interfaces.browser.IBrowserSkinType"\n'
' name="%s"\n'
- ' />' % (path, name),
- DeprecationWarning, stacklevel=2)
+ ' />' % (path, name), DeprecationWarning)
# Register the skin interface as a skin using the passed name.
if name is not None:
More information about the Zope3-Checkins
mailing list