Is there a way to verify if pytest-xdist is being ...
# general
b
Is there a way to verify if pytest-xdist is being used or not? If I force run a file with 8 tests with pants, it's taking just under two minutes. When I run the same file with
pytest -n 4
, it's taking 68 seconds. So it looks like it is doing something concurrent, but is there a way to see what the exact command to pytest was during a pants run?
b
Yeah, there's two ways: • run with
--level=debug
and find the logged CLI invocation (https://www.pantsbuild.org/2.20/reference/global-options#level) • run with
--keep-sandboxes=always
and look at the
__run.sh
file in the sandbox (https://www.pantsbuild.org/2.21/docs/using-pants/troubleshooting-common-issues#debug-tip-inspect-the-sandbox-with---keep-sandboxes)
b
amazing...thanks