[Zope-Checkins] SVN: Zope/branches/Zope-2_8-branch/lib/python/AccessControl/Owned.py Merge from 37633 on trunk:

Florent Guillaume fg at nuxeo.com
Mon Aug 1 16:15:02 EDT 2005


Log message for revision 37636:
  Merge from 37633 on trunk:
  Display offending line when warning about getOwner(1) deprecation.
  

Changed:
  U   Zope/branches/Zope-2_8-branch/lib/python/AccessControl/Owned.py

-=-
Modified: Zope/branches/Zope-2_8-branch/lib/python/AccessControl/Owned.py
===================================================================
--- Zope/branches/Zope-2_8-branch/lib/python/AccessControl/Owned.py	2005-08-01 20:13:08 UTC (rev 37635)
+++ Zope/branches/Zope-2_8-branch/lib/python/AccessControl/Owned.py	2005-08-01 20:15:00 UTC (rev 37636)
@@ -77,7 +77,7 @@
             import warnings
             warnings.warn('Owned.getOwner(1) is deprecated; '
                           'please use getOwnerTuple() instead.',
-                          DeprecationWarning)
+                          DeprecationWarning, stacklevel=2)
 
 
         owner=aq_get(self, '_owner', None, 1)



More information about the Zope-Checkins mailing list