[issue23810] Suboptimal stacklevel of deprecation warnings for formatter and imp modules

Brett Cannon report at bugs.python.org
Fri Apr 24 17:14:31 CEST 2015


Brett Cannon added the comment:

Here is a private function in warnings for calculating the stack depth to the first frame not referencing some key string. Can someone look at it to make sure it looks reasonable?

I'm starting with it being private since it uses sys._getframe() and I don't know how widely needed it is.

----------
keywords: +patch
stage: test needed -> patch review
versions:  -Python 3.4
Added file: http://bugs.python.org/file39196/better_stacklevel.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue23810>
_______________________________________


More information about the Python-bugs-list mailing list