Issue #7449, part 2: regrtest.py -j option requires thread support

This commit is contained in:
Victor Stinner 2010-04-27 21:47:01 +00:00
parent d9d147b806
commit 1b4a69d79b
1 changed files with 5 additions and 1 deletions

View File

@ -478,7 +478,11 @@ def main(tests=None, testdir=None, verbose=0, quiet=False,
tests = iter(selected)
if use_mp:
from threading import Thread
try:
from threading import Thread
except ImportError:
print "Multiprocess option requires thread support"
sys.exit(2)
from Queue import Queue
from subprocess import Popen, PIPE
debug_output_pat = re.compile(r"\[\d+ refs\]$")