◐ Shell
clean mode source ↗

bpo-42639: Move atexit state to PyInterpreterState by vstinner · Pull Request #23763 · python/cpython

@vstinner vstinner changed the title [WIP] bpo-40600: Move atexit state to PyInterpreterState [WIP] bpo-42639: Move atexit state to PyInterpreterState

Dec 14, 2020

corona10

@vstinner vstinner changed the title [WIP] bpo-42639: Move atexit state to PyInterpreterState bpo-42639: Move atexit state to PyInterpreterState

Dec 14, 2020

@vstinner vstinner marked this pull request as ready for review

December 14, 2020 22:08
* Add _PyAtExit_Call() function and remove pyexitfunc and
  pyexitmodule members of PyInterpreterState. The function
  logs atexit callback errors using _PyErr_WriteUnraisableMsg().
* Add _PyAtExit_Init() and _PyAtExit_Fini() functions.
* Remove traverse, clear and free functions of the atexit module.
* Remove _Py_PyAtExit() function.
* test_atexit uses textwrap.dedent().
* setup.py no longer tries to build atexit: it is always a built-in
  module.

Co-Authored-By: Dong-hee Na <donghee.na@python.org>

corona10

shihai1991

encukou

adorilson pushed a commit to adorilson/cpython that referenced this pull request

Mar 13, 2021
* Add _PyAtExit_Call() function and remove pyexitfunc and
  pyexitmodule members of PyInterpreterState. The function
  logs atexit callback errors using _PyErr_WriteUnraisableMsg().
* Add _PyAtExit_Init() and _PyAtExit_Fini() functions.
* Remove traverse, clear and free functions of the atexit module.

Co-authored-by: Dong-hee Na <donghee.na@python.org>