Skip to content

gh-145559: Re-export _Py_DumpTraceback and _Py_DumpTracebackThreads#145560

Open
alexmalyshev wants to merge 2 commits intopython:mainfrom
alexmalyshev:dump-traceback
Open

gh-145559: Re-export _Py_DumpTraceback and _Py_DumpTracebackThreads#145560
alexmalyshev wants to merge 2 commits intopython:mainfrom
alexmalyshev:dump-traceback

Conversation

@alexmalyshev
Copy link
Contributor

@alexmalyshev alexmalyshev commented Mar 5, 2026

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.

@bedevere-app
Copy link

bedevere-app bot commented Mar 5, 2026

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@vstinner
Copy link
Member

vstinner commented Mar 5, 2026

Rather than exporting internal C API functions, I would prefer to promote them as public or PyUnstable functions.

@bedevere-app
Copy link

bedevere-app bot commented Mar 5, 2026

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

@alexmalyshev
Copy link
Contributor Author

Made them PyUnsafe_ functions. I believe that the mentions to them in the configure and emscripten files can just be deleted now that they'll be public.

@sergey-miryanov
Copy link
Contributor

I believe they should have PyUnstable_ prefix, not PyUnsafe_.

@alexmalyshev
Copy link
Contributor Author

I believe they should have PyUnstable_ prefix, not PyUnsafe_.

Ack I always make this mistake...

…functions

These functions stopped being exported in python#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 as PyUnstable functions.
@sergey-miryanov
Copy link
Contributor

Please, try to avoid force-push.

@freakboy3742
Copy link
Contributor

!buildbot emscripten

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @freakboy3742 for commit 538a1cd 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F145560%2Fmerge

The command will test the builders whose names match following regular expression: emscripten

The builders matched are:

  • WASM Emscripten PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants