GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add unstable C APIs for allocation-free raw-frame stack inspection · Issue #148925 · python/cpython

Add unstable C APIs for allocation-free raw-frame stack inspection #148925

New issue
Copy link
New issue
Copy link
Open
Open
Add unstable C APIs for allocation-free raw-frame stack inspection#148925
Copy link
Assignees
pablogsal
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-C-APItype-featureA feature request or enhancementA feature request or enhancement

Description

@danielsn
danielsn
opened on Apr 23, 2026
Issue body actions

Feature or enhancement

Proposal:

#145559 proposes a signal-safe mechanism to print backtraces. This is useful for human debugging, but not ideal for tools because it requires parsing human-readable text. For example, a crash-tracker may wish to export and analyze structured backtraces. Similarly, a profiler can benefit from the ability to generate structure stack-traces in pure C, without needing to reason about the safety of reentering the python interpreter.

Has this already been discussed elsewhere?

I have already discussed this feature proposal on Discourse

Links to previous discussion of this feature:

https://discuss.python.org/t/pure-c-structured-traceback/106872/8

Linked PRs

  • gh-148925: Add non-allocating PyUnstable_* APIs for call-stack iteration #148930

Activity

  1. danielsn
    added
    type-featureA feature request or enhancementA feature request or enhancement
    on Apr 23, 2026
  2. danielsn
    added 5 commits that reference this issue on Apr 23, 2026

    pythongh-148925: Add PyUnstable_CollectCallStack and PyUnstable_Print…

    574509c

    pythongh-148925: Add PyUnstable_CollectCallStack and PyUnstable_Print…

    d5e70e0

    pythongh-148925: Add PyUnstable_CollectCallStack and PyUnstable_Print…

    2246c91

    pythongh-148925: Add PyUnstable_CollectCallStack and PyUnstable_Print…

    697ce8a

    pythongh-148925: Add PyUnstable_CollectCallStack and PyUnstable_Print…

    a950a1e
  3. picnixz
    added
    interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)
    topic-C-API
    on Apr 23, 2026
  4. pablogsal
    self-assigned this
    on Apr 29, 2026
  5. danielsn
    added 3 commits that reference this issue on May 4, 2026

    pythongh-148925: Add PyUnstable_* API for signal-safe stack iteration

    3d92ae7

    pythongh-148925: Add PyUnstable_* API for signal-safe stack iteration

    02a222d

    pythongh-148925: Add signal-safe PyUnstable_* APIs for call-stack ite…

    4448ac8
  6. danielsn
    changed the title [-]Expose signal-safe way to get a structured stacktrace[/-] [+]Add unstable C APIs for allocation-free raw-frame stack inspection[/+] on Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @pablogsal
    pablogsal

Labels

interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-C-APItype-featureA feature request or enhancementA feature request or enhancement

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402503 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.