the.bay.news

Callback for subinterpreter shutdown

Discussions on Python.org
Callback for subinterpreter shutdown
Dear Python team, I’ve been experimenting with adding subinterpreter support to the nanobind binding library and ran into the following blocker where the official API seems too limited. Binding tools will generally have some per-subinterpreter internal state to keep track of types/instances of bindings. This state needs to be cleaned up at some point to avoid leaks. For classic CPython, the place to do so is via a callback at Py_AtExit which runs after Python has shut down. (Incidentally, this...

0 comments

Sign in to join the discussion — your thebay.events account works here.

No comments yet.