[issue38733] PyErr_Occurred(): tstate must be non-NULL

2019-11-07 Thread STINNER Victor
STINNER Victor added the comment: I merged my change, I close the issue. The change is a little bit backward incompatible, so I prefer to not backport it. PyErr_Occurred() checks tstate==NULL for 9 years, there is no urgency to change it :-) It can wait for Python 3.9. -- resolution

[issue38733] PyErr_Occurred(): tstate must be non-NULL

2019-11-07 Thread STINNER Victor
STINNER Victor added the comment: In 2018 with bpo-26558, I fixed Py_FatalError() to no longer access the current exception of the current Python thread state, if the current thread doesn't not hold the GIL: commit 3a228ab17c2a9cffd1a2f15f30d6209768de20a6 Author: Victor Stinner Date: Thu

[issue38733] PyErr_Occurred(): tstate must be non-NULL

2019-11-07 Thread STINNER Victor
STINNER Victor added the comment: New changeset d12d0e7c0fe2b49c40ac4d66365147c619d6c475 by Victor Stinner in branch 'master': bpo-38733: PyErr_Occurred() caller must hold the GIL (GH-17080) https://github.com/python/cpython/commit/d12d0e7c0fe2b49c40ac4d66365147c619d6c475 -- __

[issue38733] PyErr_Occurred(): tstate must be non-NULL

2019-11-07 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +16589 stage: -> patch review pull_request: https://github.com/python/cpython/pull/17080 ___ Python tracker ___ _

[issue38733] PyErr_Occurred(): tstate must be non-NULL

2019-11-07 Thread STINNER Victor
New submission from STINNER Victor : bpo-3605 modified PyErr_Occurred() to return NULL if the current Python thread state ("tstate") is NULL: commit 8e0bdfd1d473ddffaf3501768678f8a970019da8 Author: Jeffrey Yasskin Date: Thu May 13 18:31:05 2010 + Make PyErr_Occurred return NULL if