Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6d81a21

Browse files
committed
regrtest doesn't ignore -j1 anymore
* regrtest now uses subprocesses when the -j1 command line option is used: each test file runs in a fresh child process. Before, the -j1 option was ignored. * Tools/buildbot/test.bat script now uses -j1 by default to run each test file in fresh child process.
1 parent 2292edf commit 6d81a21

3 files changed

Lines changed: 11 additions & 3 deletions

File tree

Lib/test/libregrtest/cmdline.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -318,8 +318,6 @@ def _parse_args(args, **kwargs):
318318
if ns.use_mp <= 0:
319319
# Use all cores + extras for tests that like to sleep
320320
ns.use_mp = 2 + (os.cpu_count() or 1)
321-
if ns.use_mp == 1:
322-
ns.use_mp = None
323321
if ns.use:
324322
for a in ns.use:
325323
for r in a:

Misc/NEWS

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,16 @@ Library
2222
- Issue #27056: Optimize pickle.load() and pickle.loads(), up to 10% faster
2323
to deserialize a lot of small objects.
2424

25+
Tests
26+
-----
27+
28+
- Issue #25285: regrtest now uses subprocesses when the -j1 command line option
29+
is used: each test file runs in a fresh child process. Before, the -j1 option
30+
was ignored.
31+
32+
- Issue #25285: Tools/buildbot/test.bat script now uses -j1 by default to run
33+
each test file in fresh child process.
34+
2535

2636
What's New in Python 3.6.0 alpha 1?
2737
===================================

Tools/buildbot/test.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ setlocal
44

55
set here=%~dp0
66
set rt_opts=-q -d
7-
set regrtest_args=
7+
set regrtest_args=-j1
88

99
:CheckOpts
1010
if "%1"=="-x64" (set rt_opts=%rt_opts% %1) & shift & goto CheckOpts

0 commit comments

Comments
 (0)