summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2010-04-27 21:47:01 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2010-04-27 21:47:01 (GMT)
commit1b4a69d79bcdd50829ce871be703606211965e72 (patch)
treed3af329b1b263c001aa0c1eabfe8753e8a38e82c /Lib
parentd9d147b8060970bca0e8ebb4ee4ba210558d5c28 (diff)
downloadcpython-1b4a69d79bcdd50829ce871be703606211965e72.zip
cpython-1b4a69d79bcdd50829ce871be703606211965e72.tar.gz
cpython-1b4a69d79bcdd50829ce871be703606211965e72.tar.bz2
Issue #7449, part 2: regrtest.py -j option requires thread support
Diffstat (limited to 'Lib')
-rwxr-xr-xLib/test/regrtest.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py
index 349e15e..545e0ea 100755
--- a/Lib/test/regrtest.py
+++ b/Lib/test/regrtest.py
@@ -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\]$")