Problem
Running rtest --runner pytest -n 4 on more-itertools fails because pytest-xdist can't serialize Decimal objects across worker processes.
execnet.gateway_base.DumpError: can't serialize <class 'decimal.Decimal'>
Tests pass fine without parallelization (rtest --runner pytest works).
Reproduction
git clone https://github.com/more-itertools/more-itertools
cd more-itertools
uv venv && uv sync --all-groups
uv pip install pytest-xdist rtest
# Works
.venv/bin/rtest --runner pytest tests
# Fails
.venv/bin/rtest --runner pytest -n 4 tests
Notes
This is may a pytest-xdist limitation. But worth tracking since it affects which repos can use parallel pytest execution.
Problem
Running
rtest --runner pytest -n 4on more-itertools fails because pytest-xdist can't serializeDecimalobjects across worker processes.Tests pass fine without parallelization (
rtest --runner pytestworks).Reproduction
Notes
This is may a pytest-xdist limitation. But worth tracking since it affects which repos can use parallel pytest execution.