Skip to content

Commit 0346448

Browse files
Improve threading.daemon docstring (GH-14278)
Rephrase and clarify that "the entire Python program exits when only daemon threads are left". This matches the documentation at https://docs.python.org/3/library/threading.htmlGH-thread-objects. (cherry picked from commit bb110cc) Co-authored-by: mbarkhau <mbarkhau@gmail.com>
1 parent adcdb1e commit 0346448

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

Lib/threading.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1005,8 +1005,7 @@ def daemon(self):
10051005
main thread is not a daemon thread and therefore all threads created in
10061006
the main thread default to daemon = False.
10071007
1008-
The entire Python program exits when no alive non-daemon threads are
1009-
left.
1008+
The entire Python program exits when only daemon threads are left.
10101009
10111010
"""
10121011
assert self.__initialized, "Thread.__init__() not called"

0 commit comments

Comments
 (0)