[Python-Dev] Can someone look at dummy_thread (#622537)?
Guido van Rossum
guido@python.org
Mon, 02 Dec 2002 10:36:53 -0500
> try:
> import threading
> except ImportError:
> threading = None # use non-threaded behaviour
But then you'd have to sprinkle the rest of the code with
"if threading is not None" tests. Brett's dummy_thread is an attempt
to reduce this clutter. I've been known to write a mini-version of
dummy_thread.py in code to minimize the clutter; it seems useful to
generalize this.
--Guido van Rossum (home page: http://www.python.org/~guido/)