summaryrefslogtreecommitdiffstats
path: root/Doc/library/atexit.rst
diff options
context:
space:
mode:
authorÉric Araujo <merwok@netwok.org>2011-07-29 16:04:24 (GMT)
committerÉric Araujo <merwok@netwok.org>2011-07-29 16:04:24 (GMT)
commitfe1e298d8bbfbdfd1c2af74dbb74f47e2d04a6d0 (patch)
treeb9b6f456a06f529110f40468d21b7d5d63969aee /Doc/library/atexit.rst
parent63b18a4445a22d157b5ddf0677cc904356d83d81 (diff)
downloadcpython-fe1e298d8bbfbdfd1c2af74dbb74f47e2d04a6d0.zip
cpython-fe1e298d8bbfbdfd1c2af74dbb74f47e2d04a6d0.tar.gz
cpython-fe1e298d8bbfbdfd1c2af74dbb74f47e2d04a6d0.tar.bz2
Document that atexit execution order is undefined (#9788)
Diffstat (limited to 'Doc/library/atexit.rst')
-rw-r--r--Doc/library/atexit.rst4
1 files changed, 3 insertions, 1 deletions
diff --git a/Doc/library/atexit.rst b/Doc/library/atexit.rst
index cc1051b..5b87b94 100644
--- a/Doc/library/atexit.rst
+++ b/Doc/library/atexit.rst
@@ -9,7 +9,9 @@
The :mod:`atexit` module defines functions to register and unregister cleanup
functions. Functions thus registered are automatically executed upon normal
-interpreter termination.
+interpreter termination. The order in which the functions are called is not
+defined; if you have cleanup operations that depend on each other, you should
+wrap them in a function and register that one. This keeps :mod:`atexit` simple.
Note: the functions registered via this module are not called when the program
is killed by a signal not handled by Python, when a Python fatal internal error