{{ message }}
bpo-45711: [asyncio] Normalize exceptions immediately after Fetch, before they are stored as StackItem, which should be normalized#29890
Merged
iritkatriel merged 5 commits intoDec 3, 2021
Conversation
Member
Author
|
This broke a couple of the asyncio tests, I'm checking why. |
Sorry, something went wrong.
Member
Author
Right, because I removed the traceback update, which is not part of the normalising. The tests pass if I put it back. But I think the right place to do this is when the exception is captured, here cpython/Modules/_asynciomodule.c Line 2705 in cb8f491 |
Sorry, something went wrong.
…a StackItem (exc_info)
asvetlov
approved these changes
Dec 2, 2021
gvanrossum
reviewed
Dec 2, 2021
This reverts commit 847fcdb.
gvanrossum
approved these changes
Dec 3, 2021
gvanrossum
left a comment
Member
There was a problem hiding this comment.
LG from me, not sure how long to wait for @1st1.
Sorry, something went wrong.
1st1
approved these changes
Dec 3, 2021
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
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.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.
The handled exception exc_info (unlike the in-flight exception currexc) is always normalized. Except in asyncio, where unnormalised exceptions are saved in a StackItem and need to be normalized when they are used.
This PR brings asyncio in line with the rest of the code, by normalising exceptions and setting the traceback when they are Fetched.
https://bugs.python.org/issue45711