Skip to content

Commit a3fd1c9

Browse files
committed
windows: ensure we run at least 1 test worker
On low core count machines, the calculation could reach 0.
1 parent 6ee944f commit a3fd1c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cpython-windows/build.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1562,7 +1562,7 @@ def build_cpython(arch: str, pgo=False, build_mode="static"):
15621562
"test",
15631563
"--pgo",
15641564
"-j",
1565-
"%d" % (multiprocessing.cpu_count() / 2 - 1),
1565+
"%d" % max(1, multiprocessing.cpu_count() / 2 - 1),
15661566
# test_regrtest hangs for some reason. It is the test for the
15671567
# test harness itself and isn't exercising useful code. Skip it.
15681568
"--exclude",

0 commit comments

Comments
 (0)