Repository navigation
Add --single-process option to regrtest to always run tests sequentially (ignore -jN option) #119727
Description
Activity
My motivation for this change is also a desire to change the regrtest default to -j0: run tests in parallel using the number of CPU.
- addedtestsTests in the Lib/test dirTests in the Lib/test dirtype-featureA feature request or enhancementA feature request or enhancement
on May 29, 2024 This is an opposite of
--multiprocess. Why not call it--singleprocess?You can run tests with
-j1, it will be sequentially, but in different processes.IMO "sequentially" is the right name.
--multiprocessmeans in fact "running tests in parallel". Using multipe processes is just an implementation details. It could be threads or something else. The opposite of parallel is sequential. IMO it's too late to rename the--multiprocessoption.Note: there is already a
--singleoption.--singleprocesssounds too close.I will not insist.
The
--multiprocessoption has two effects: it runs the tests in parallel and runs every test is a separate process. It could be possible to run the tests in parallel using the process pull, but this is not how it is implemented now, and I do not think there is a benefit to implement such option. Currently there are three options:- Run the tests sequentially in the same (main) process. By default.
- Run the tests sequentially in separate processes.
-j1. - Run the tests in parallel in separate processes.
-jN.
- changed the title
[-]Add `--sequentially` option to regrtest to always run tests sequentially (ignore `-jN` option)[/-][+]Add `--single-process` option to regrtest to always run tests sequentially (ignore `-jN` option)[/+]on Jun 3, 2024 Implemented by change 4e8aa32.
The Python release process runs tests sequentially. It catchs some issues which are ignored silently when running tests in parallel.
I propose adding
--sequentiallyoption to regrtest to always run tests sequentially. It can be used to ignore any-jNoption and also to re-run failed tests sequentially.Linked PRs