10000 gh-126091: Always link generator frames when propagating a thrown-in exception through a yield-from chain by jbower-fb · Pull Request #126092 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-126091: Always link generator frames when propagating a thrown-in exception through a yield-from chain #126092

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Nov 21, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Put back XXX comment.
  • Loading branch information
jbower-fb committed Nov 19, 2024
commit 940f28f5344f9fe19d0828077f775f9c92a53f71
2 changes: 2 additions & 0 deletions Objects/genobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -476,6 +476,8 @@ _gen_throw(PyGenObject *gen, int close_on_genexit,
/* `yf` is a generator or a coroutine. */

/* Link frame into the stack to enable complete backtraces. */
/* XXX We should probably be updating the current frame somewhere in
ceval.c. */
_PyInterpreterFrame *prev = tstate->current_frame;
frame->previous = prev;
tstate->current_frame = frame;
Expand Down
0