FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-145559: Add PyUnstable_DumpTraceback() and PyUnstable_DumpTracebackThreads() by alexmalyshev · Pull Request #148145 · python/cpython · GitHub

Repository navigation

gh-145559: Add PyUnstable_DumpTraceback() and PyUnstable_DumpTracebackThreads() - #148145

Merged
vstinner merged 12 commits into
python:mainfrom
alexmalyshev:traceback
May 6, 2026
Merged

vstinner merged 12 commits into
python:mainfrom
alexmalyshev:traceback

Conversation

alexmalyshev commented Apr 5, 2026 •
edited by github-actions Bot
Loading

Copy link
Copy Markdown
Contributor

These functions stopped being exported in #107215. However, they are the only way to print a Python stacktrace safely from a signal handler, making them very useful for extensions. Re-export them.

Regenerated from #145560 due to a bad merge.


📚 Documentation preview 📚: https://cpython-previews--148145.org.readthedocs.build/

Public versions of _Py_DumpTraceback() and _Py_DumpTracebackThreads().

Copy link
Copy Markdown
Member

@alexmalyshev: There are now merge conflicts, can you try to solve them? Moreover, a new max_threads parameter has been added. Can you update your PR to add it?

read-the-docs-community Bot commented May 1, 2026 •
edited
Loading

Copy link
Copy Markdown

Comment thread Doc/c-api/exceptions.rst Outdated
Comment thread Python/traceback.c Outdated

vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM if my suggestions are applied :-)

Comment thread Doc/c-api/exceptions.rst Outdated
Comment thread Modules/faulthandler.c
Comment thread Doc/whatsnew/3.15.rst Outdated
Co-authored-by: Victor Stinner <vstinner@python.org>
vstinner enabled auto-merge (squash) May 6, 2026 14:32
vstinner merged commit 646853d into python:main May 6, 2026
56 checks passed
alexmalyshev deleted the traceback branch May 6, 2026 15:28

Copy link
Copy Markdown
Contributor Author

Thanks for all the help @vstinner, I really appreciate it!

vstinner commented May 6, 2026

Copy link
Copy Markdown
Member

You're welcome. Thanks for your contribution.

vstinner commented May 6, 2026

Copy link
Copy Markdown
Member

There is no tests on the newly added C APIs. These functions are tested indirectly by test_faulthandler.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL