New submission from Hagen Fürstenau <hfuerste...@gmx.net>: This leads to unhelpful warnings:
>>> with contextlib.nested(open("x", "w")) as f: pass ... /usr/local/lib/python3.1/contextlib.py:17: DeprecationWarning: With-statements now directly support multiple context managers return next(self.gen) Patch is attached. ---------- components: Library (Lib) files: warning_stacklevel.patch keywords: patch messages: 89209 nosy: hagen severity: normal status: open title: Wrong stacklevel in warning for contextlib.nested type: behavior versions: Python 2.7, Python 3.1 Added file: http://bugs.python.org/file14259/warning_stacklevel.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue6256> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com