summaryrefslogtreecommitdiffstats
path: root/Doc/library/_dummy_thread.rst
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2008-05-25 13:05:15 (GMT)
committerGeorg Brandl <georg@python.org>2008-05-25 13:05:15 (GMT)
commit2067bfdf253e134a4144d3747300dbfcc7cc6203 (patch)
tree76613f07319d07cc4f0159769131a051504f8c69 /Doc/library/_dummy_thread.rst
parent3b4b45bfe546b023383d4382af7767359390e264 (diff)
downloadcpython-2067bfdf253e134a4144d3747300dbfcc7cc6203.zip
cpython-2067bfdf253e134a4144d3747300dbfcc7cc6203.tar.gz
cpython-2067bfdf253e134a4144d3747300dbfcc7cc6203.tar.bz2
Rename thread to _thread and dummy_thread to _dummy_thread. Issue #2875.
Diffstat (limited to 'Doc/library/_dummy_thread.rst')
-rw-r--r--Doc/library/_dummy_thread.rst22
1 files changed, 22 insertions, 0 deletions
diff --git a/Doc/library/_dummy_thread.rst b/Doc/library/_dummy_thread.rst
new file mode 100644
index 0000000..62e5708
--- /dev/null
+++ b/Doc/library/_dummy_thread.rst
@@ -0,0 +1,22 @@
+:mod:`_dummy_thread` --- Drop-in replacement for the :mod:`_thread` module
+==========================================================================
+
+.. module:: _dummy_thread
+ :synopsis: Drop-in replacement for the _thread module.
+
+
+This module provides a duplicate interface to the :mod:`_thread` module. It is
+meant to be imported when the :mod:`_thread` module is not provided on a
+platform.
+
+Suggested usage is::
+
+ try:
+ import _thread
+ except ImportError:
+ import dummy_thread as _thread
+
+Be careful to not use this module where deadlock might occur from a thread being
+created that blocks waiting for another thread to be created. This often occurs
+with blocking I/O.
+