blob: 0658df2d27fc7427a5ad5263a3069472828ef40c [file] [log] [blame]
Georg Brandl116aa622007-08-15 14:28:22 +00001:mod:`dummy_threading` --- Drop-in replacement for the :mod:`threading` module
2==============================================================================
3
4.. module:: dummy_threading
5 :synopsis: Drop-in replacement for the threading module.
6
7
8This module provides a duplicate interface to the :mod:`threading` module. It
Georg Brandl2067bfd2008-05-25 13:05:15 +00009is meant to be imported when the :mod:`_thread` module is not provided on a
Georg Brandl116aa622007-08-15 14:28:22 +000010platform.
11
12Suggested usage is::
13
14 try:
Georg Brandl2067bfd2008-05-25 13:05:15 +000015 import threading
Georg Brandl116aa622007-08-15 14:28:22 +000016 except ImportError:
Georg Brandl2067bfd2008-05-25 13:05:15 +000017 import dummy_threading
Georg Brandl116aa622007-08-15 14:28:22 +000018
Georg Brandl2067bfd2008-05-25 13:05:15 +000019Be careful to not use this module where deadlock might occur from a thread being
20created that blocks waiting for another thread to be created. This often occurs
21with blocking I/O.
Georg Brandl116aa622007-08-15 14:28:22 +000022