[issue21857] assert that functions clearing the current exception are not called with an exception set
STINNER Victor added the comment: I don't think anymore that it's a good idea. Almost all C functions can replace the current Python exception. There is no reason to add assertions only in a few functions. -- resolution: - not a bug status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21857 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21857] assert that functions clearing the current exception are not called with an exception set
New submission from STINNER Victor: Attached patch detects (when Python is compiled in debug mode) if functions that may clear the current exception are called with an exception set. The check avoids loosing an exception. The problem is that the test_sqlite fails with the patch applied. I will open a new patch for that. I already added similar checks in functions of Python/ceval.c. -- files: assert_exc.patch keywords: patch messages: 221444 nosy: haypo priority: normal severity: normal status: open title: assert that functions clearing the current exception are not called with an exception set versions: Python 3.5 Added file: http://bugs.python.org/file35767/assert_exc.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21857 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21857] assert that functions clearing the current exception are not called with an exception set
STINNER Victor added the comment: The problem is that the test_sqlite fails with the patch applied. I will open a new patch for that. I opened the issue #21858 for that. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21857 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com