diff --git a/sphinx/testing/fixtures.py b/sphinx/testing/fixtures.py index c6d4fbb7c31..a62f34694b7 100644 --- a/sphinx/testing/fixtures.py +++ b/sphinx/testing/fixtures.py @@ -145,7 +145,6 @@ def app( """ args, kwargs = app_params app_ = make_app(*args, **kwargs) - app_.env.config.enable_parallel_post_transform = True yield app_ print('# testroot:', kwargs.get('testroot', 'root')) @@ -190,7 +189,6 @@ def make(*args: Any, **kwargs: Any) -> SphinxTestApp: kwargs.setdefault('status', status) kwargs.setdefault('warning', warning) app_: Any = SphinxTestApp(*args, **kwargs) - # app_.env.config.enable_parallel_post_transform = True apps.append(app_) if test_params['shared_result']: app_ = SphinxTestAppWrapperForSkipBuilding(app_) diff --git a/sphinx/testing/util.py b/sphinx/testing/util.py index c81f8274532..e15a43b4b33 100644 --- a/sphinx/testing/util.py +++ b/sphinx/testing/util.py @@ -91,8 +91,8 @@ def __init__( status: IO | None = None, warning: IO | None = None, tags: list[str] | None = None, - docutilsconf: str | None = None, - parallel: int = 4, + docutils_conf: str | None = None, + parallel: int = 0, ) -> None: assert srcdir is not None diff --git a/sphinx/util/parallel.py b/sphinx/util/parallel.py index 6b8ce39997d..10f8c8945af 100644 --- a/sphinx/util/parallel.py +++ b/sphinx/util/parallel.py @@ -149,7 +149,7 @@ def make_chunks(arguments: Sequence[str], nproc: int, maxbatch: int = 10) -> lis chunksize = nargs // nproc if chunksize >= maxbatch: # try to improve batch size vs. number of batches - chunksize = int(sqrt(sqrt(nargs / nproc * maxbatch))) + chunksize = int(sqrt(nargs / nproc * maxbatch)) if chunksize == 0: chunksize = 1 nchunks, rest = divmod(nargs, chunksize) diff --git a/tox.ini b/tox.ini index 28632ae6508..fb7e344ff0b 100644 --- a/tox.ini +++ b/tox.ini @@ -24,7 +24,7 @@ setenv = PYTHONWARNINGS = error PYTEST_ADDOPTS = {env:PYTEST_ADDOPTS:} --color yes commands= - python -X dev -X warn_default_encoding -m pytest -n 4 --durations 25 {posargs} + python -X dev -X warn_default_encoding -m pytest --durations 25 {posargs} [testenv:docs] basepython = python3