Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions 6 Doc/library/threading.rst
Original file line number Diff line number Diff line change
Expand Up @@ -310,8 +310,10 @@ If the :meth:`~Thread.run` method raises an exception,
:func:`threading.excepthook` is called to handle it. By default,
:func:`threading.excepthook` ignores silently :exc:`SystemExit`.

A thread can be flagged as a "daemon thread". The significance of this flag is
that the entire Python program exits when only daemon threads are left. The
A thread can be flagged as a "daemon thread". A thread with this flag is shut
down when the main thread and all other non-daemon threads end.
This means a Python program runs as long as non-daemon threads (such as the main
thread) are running, and exits when only daemon threads are left. The
initial value is inherited from the creating thread. The flag can be set
through the :attr:`~Thread.daemon` property or the *daemon* constructor
argument.
Expand Down
Loading
Morty Proxy This is a proxified and sanitized view of the page, visit original site.