Skip to content

pytest-xdist 2 support #100

Closed
Closed
@dmtucker

Description

@dmtucker

There are some breaking changes: https://github.com/pytest-dev/pytest-xdist/blob/1d08799c82f94d7c2c32a8131945babc4a580ae0/CHANGELOG.rst#pytest-xdist-200-2020-08-12

$ venv/bin/pytest --mypy --verbose -n auto demo
================================================ test session starts =================================================
platform linux -- Python 3.8.2, pytest-6.0.1, py-1.9.0, pluggy-0.13.1 -- /home/dtux/Projects/pytest-mypy/venv/bin/python
cachedir: .pytest_cache
Using --randomly-seed=1597766100
rootdir: /home/dtux/Projects/pytest-mypy
plugins: xdist-2.0.0, forked-1.3.0, randomly-2.1.1, pylint-0.17.0, cov-2.5.1, mypy-0.6.3.dev21+gbf78e22.d20200818
[gw0] linux Python 3.8.2 cwd: /home/dtux/Projects/pytest-mypy
gw0 C / gw1 I / gw2 I / gw3 IINTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/_pytest/main.py", line 238, in wrap_session
INTERNALERROR>     config.hook.pytest_sessionstart(session=session)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/hooks.py", line 286, in __call__
INTERNALERROR>     return self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/manager.py", line 84, in <lambda>
INTERNALERROR>     self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/xdist/dsession.py", line 78, in pytest_sessionstart
INTERNALERROR>     nodes = self.nodemanager.setup_nodes(putevent=self.queue.put)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 65, in setup_nodes
INTERNALERROR>     return [self.setup_node(spec, putevent) for spec in self.specs]
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 65, in <listcomp>
INTERNALERROR>     return [self.setup_node(spec, putevent) for spec in self.specs]
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 73, in setup_node
INTERNALERROR>     node.setup()
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 260, in setup
INTERNALERROR>     self.config.hook.pytest_configure_node(node=self)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/hooks.py", line 286, in __call__
INTERNALERROR>     return self._hookexec(self, self.get_hookimpls(), kwargs)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/manager.py", line 93, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook, methods, kwargs)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/manager.py", line 84, in <lambda>
INTERNALERROR>     self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall(
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/callers.py", line 208, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/callers.py", line 80, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/venv/lib/python3.8/site-packages/pluggy/callers.py", line 187, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/home/dtux/Projects/pytest-mypy/src/pytest_mypy.py", line 66, in pytest_configure_node
INTERNALERROR>     node.slaveinput['_mypy_results_path'] = \
INTERNALERROR> AttributeError: 'WorkerController' object has no attribute 'slaveinput'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions