PageRenderTime 384ms CodeModel.GetById 221ms app.highlight 2ms RepoModel.GetById 159ms app.codeStats 1ms

/Doc/library/dummy_threading.rst

http://unladen-swallow.googlecode.com/
ReStructuredText | 23 lines | 15 code | 8 blank | 0 comment | 0 complexity | d3d5ed98d273c8b01685dbdd6c522992 MD5 | raw file
 1
 2:mod:`dummy_threading` --- Drop-in replacement for the :mod:`threading` module
 3==============================================================================
 4
 5.. module:: dummy_threading
 6   :synopsis: Drop-in replacement for the threading module.
 7
 8
 9This module provides a duplicate interface to the :mod:`threading` module.  It
10is meant to be imported when the :mod:`thread` module is not provided on a
11platform.
12
13Suggested usage is::
14
15   try:
16       import threading as _threading
17   except ImportError:
18       import dummy_threading as _threading
19
20Be careful to not use this module where deadlock might occur from a thread
21being created that blocks waiting for another thread to be created.  This  often
22occurs with blocking I/O.
23