Skip to content
New issue

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

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

Already on GitHub? # to your account

add PyErr::display #3334

Merged
merged 1 commit into from
Jul 25, 2023
Merged

add PyErr::display #3334

merged 1 commit into from
Jul 25, 2023

Conversation

davidhewitt
Copy link
Member

@davidhewitt davidhewitt commented Jul 21, 2023

When looking at 3.12 FFI changes I saw the new PyErr_DisplayException and this inspired me to add PyErr::Display for all versions.

While looking at this I noticed that PyErr_PrintEx will call sys.excepthook, so I added this to the documentation.

I think we generally want to be using .display() instead of .print() in tests because there's no meaning to calling sys.excepthook there, so I updated the callsites.

@adamreichold
Copy link
Member

so I added the ...

There seems to be something missing from the above?

@davidhewitt
Copy link
Member Author

so I added the ...

There seems to be something missing from the above?

Yes, I meant to say "added to the documentation", got distracted halfway writing 🤦

@adamreichold adamreichold added this pull request to the merge queue Jul 25, 2023
Merged via the queue into PyO3:main with commit 8ce6c26 Jul 25, 2023
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants