Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
gh-89770: Implement PEP-678 - Exception notes#31317
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
…le of the assigned notes
bedevere-bot commentedFeb 13, 2022
🤖 New build scheduled with the buildbot fleet by@iritkatriel for commit1555087 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
This reverts commit7bab63e.
… a sequence of strings
Uh oh!
There was an error while loading.Please reload this page.
gvanrossum left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Where's the descriptor for"__notes__"?
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
gvanrossum left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
"Errors should never pass silently."
Uh oh!
There was an error while loading.Please reload this page.
gvanrossum commentedMar 16, 2022
Yeah, I like this! |
iritkatriel commentedMar 17, 2022
How about error handling when printing the traceback? Should we print something like "cannot printnotes: not a sequence", and similarly if a note is not a str? |
gvanrossum commentedMar 17, 2022
How about printing If either of those fails, either raise an exception from |
iritkatriel commentedMar 17, 2022
I'll do something likewhat we do for str(exc). |
Zac-HD commentedMar 22, 2022
Heya - I think we should have an explicit test that if you |
iritkatriel commentedMar 22, 2022
That's a good point. I added the test and fixed the code to copy the notes in split(), so long as they are a sequence (producing a list). If people assign arbitrary objects to notes I don't know how to copy them. |
bedevere-bot commentedApr 14, 2022
🤖 New build scheduled with the buildbot fleet by@iritkatriel for commit95be670 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
Uh oh!
There was an error while loading.Please reload this page.
iritkatriel commentedApr 14, 2022
Sorry about the noise (I messed it up multitasking). Getting there now. |
bedevere-bot commentedApr 14, 2022
🤖 New build scheduled with the buildbot fleet by@iritkatriel for commit602b4c4 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
iritkatriel commentedApr 15, 2022
The buildbots are happy with this. Let me know if you would like to re-review, otherwise I'll merge it tomorrow or so. |
serhiy-storchaka left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Opened#106033.
| returnNULL; | ||
| } | ||
| if (!PyObject_HasAttr(self,&_Py_ID(__notes__))) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Do not use PyObject_HasAttr. It is broken by design.
Uh oh!
There was an error while loading.Please reload this page.
No description provided.