bpo-39164: errors: add and expose _PyErr_GetExcInfo#17752
Merged
Conversation
Contributor
Author
|
@vstinner just in case you missed it 👋 :) |
vstinner
reviewed
Jan 13, 2020
This adds a new function named _PyErr_GetExcInfo that is a variation of the original PyErr_GetExcInfo taking a PyThreadState as its first argument. That function allows to retrieve the exceptions information of any Python thread — not only the current one.
jd
force-pushed
the
expose-PyErr_GetExcInfo
branch
from
January 13, 2020 15:50
76d6cbf to
1b19a83
Compare
Contributor
Author
|
Failure looks unrelated 🤔 |
Member
|
test_ttk_guionly failed twice on Azure Pipelines "Tests / Ubuntu": |
Member
|
Thanks @jd, I merged your PR. I made minor changes on your commit message. |
Contributor
Author
|
Thank you @vstinner 🙇 |
ammaraskar
reviewed
Jan 15, 2020
| PyErr_GetExcInfo(PyObject **p_type, PyObject **p_value, PyObject **p_traceback) | ||
| { | ||
| PyThreadState *tstate = _PyThreadState_GET(); | ||
| return _PyErr_GetExcInfo(tstate, p_type, p_value, p_traceback); |
Member
There was a problem hiding this comment.
Should this have a return? I think this introduced a warning on the windows build: https://github.com/python/cpython/runs/390021032#step:3:572
shihai1991
pushed a commit
to shihai1991/cpython
that referenced
this pull request
Jan 31, 2020
This adds a new function named _PyErr_GetExcInfo() that is a variation of the original PyErr_GetExcInfo() taking a PyThreadState as its first argument. That function allows to retrieve the exceptions information of any Python thread -- not only the current one.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds a new function named _PyErr_GetExcInfo that is a variation of the
original PyErr_GetExcInfo taking a PyThreadState as its first argument.
That function allows to retrieve the exceptions information of any Python
thread — not only the current one.
https://bugs.python.org/issue39164