Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

INTERNALERROR when running tests with tox #2592

Closed
kubouch opened this issue Jun 23, 2023 · 1 comment · Fixed by #2593
Closed

INTERNALERROR when running tests with tox #2592

kubouch opened this issue Jun 23, 2023 · 1 comment · Fixed by #2593

Comments

@kubouch
Copy link
Contributor

kubouch commented Jun 23, 2023

Issue

Following the documentation, running tox -e py to run the tests results in a strange error:

> git clone https://github.com/pypa/virtualenv.git
> tox -e dev
> tox -e py
.pkg: _optional_hooks> python /home/kubouch/miniconda3/lib/python3.10/site-packages/pyproject_api/_backend.py True hatchling.build
.pkg: get_requires_for_build_wheel> python /home/kubouch/miniconda3/lib/python3.10/site-packages/pyproject_api/_backend.py True hatchling.build
.pkg: get_requires_for_build_editable> python /home/kubouch/miniconda3/lib/python3.10/site-packages/pyproject_api/_backend.py True hatchling.build
.pkg: build_wheel> python /home/kubouch/miniconda3/lib/python3.10/site-packages/pyproject_api/_backend.py True hatchling.build
py: install_package_deps> python -I -m pip install 'covdefaults>=2.3' 'coverage-enable-subprocess>=1' 'coverage>=7.2.7' 'distlib<1,>=0.3.6' 'filelock<4,>=3.12' 'flaky>=3.7' 'importlib-metadata>=6.6; python_version < "3.8"' 'packaging>=23.1' 'platformdirs<4,>=3.5.1' 'pytest-env>=0.8.1' 'pytest-freezer>=0.4.6; platform_python_implementation == "PyPy"' 'pytest-mock>=3.10' 'pytest-randomly>=3.12' 'pytest-timeout>=2.1' 'pytest>=7.3.1' 'setuptools>=67.8' 'time-machine>=2.9; platform_python_implementation == "CPython"'
py: install_package> python -I -m pip install --force-reinstall --no-deps /home/kubouch/git/extern/virtualenv/.tox/.tmp/package/2/virtualenv-20.23.2.dev2+g09d67b1-py3-none-any.whl
py: commands[0]> coverage erase
py: commands[1]> coverage run -m pytest --junitxml /home/kubouch/git/extern/virtualenv/.tox/junit.py.xml tests --int
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/.tox/py/lib/python3.10/site-packages/_pytest/main.py", line 265, in wrap_session
INTERNALERROR>     config._do_configure()
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/.tox/py/lib/python3.10/site-packages/_pytest/config/__init__.py", line 1056, in _do_configure
INTERNALERROR>     self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/.tox/py/lib/python3.10/site-packages/pluggy/_hooks.py", line 452, in call_historic
INTERNALERROR>     res = self._hookexec(self.name, self._hookimpls, kwargs, False)
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/.tox/py/lib/python3.10/site-packages/pluggy/_manager.py", line 112, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/.tox/py/lib/python3.10/site-packages/pluggy/_callers.py", line 116, in _multicall
INTERNALERROR>     raise exception.with_traceback(exception.__traceback__)
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/.tox/py/lib/python3.10/site-packages/pluggy/_callers.py", line 80, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/home/kubouch/git/extern/virtualenv/tests/conftest.py", line 27, in pytest_configure
INTERNALERROR>     order = manager.hook.pytest_collection_modifyitems._nonwrappers  # noqa: SLF001
INTERNALERROR> AttributeError: '_HookCaller' object has no attribute '_nonwrappers'
py: exit 3 (0.36 seconds) /home/kubouch/git/extern/virtualenv> coverage run -m pytest --junitxml /home/kubouch/git/extern/virtualenv/.tox/junit.py.xml tests --int pid=5209
.pkg: _exit> python /home/kubouch/miniconda3/lib/python3.10/site-packages/pyproject_api/_backend.py True hatchling.build
  py: FAIL code 3 (3.85=setup[3.42]+cmd[0.06,0.36] seconds)
  evaluation failed :( (3.91 seconds)

Seems like it happens during the coverage run.

I used the latest main branch of virtualenv, commit 09d67b1

Environment

Provide at least:

OS:

name arch family kernel_version
linux x86_64 unix 6.3.8-arch1-1

pip list of the host python where virtualenv is installed:

Package                 Version
----------------------- --------
appdirs                 1.4.4
asttokens               2.0.5
backcall                0.2.0
boltons                 23.0.0
brotlipy                0.7.0
cachetools              5.3.1
certifi                 2023.5.7
cffi                    1.15.1
chardet                 5.1.0
charset-normalizer      2.0.4
colorama                0.4.6
conda                   23.5.0
conda-package-handling  2.1.0
conda_package_streaming 0.8.0
cryptography            39.0.1
debugpy                 1.5.1
decorator               5.1.1
distlib                 0.3.6
executing               0.8.3
filelock                3.12.2
greenlet                1.1.2
idna                    3.4
ipykernel               6.15.2
ipython                 8.3.0
jedi                    0.18.1
jsonpatch               1.32
jsonpointer             2.1
jupyter_client          8.1.0
jupyter_core            5.3.0
logging-tree            1.9
matplotlib-inline       0.1.6
msgpack                 1.0.3
nest-asyncio            1.5.6
packaging               23.1
parso                   0.8.3
pexpect                 4.8.0
pickleshare             0.7.5
pip                     21.2.4
platformdirs            3.8.0
pluggy                  1.0.0
prompt-toolkit          3.0.36
psutil                  5.9.0
ptyprocess              0.7.0
pure-eval               0.2.2
pycosat                 0.6.4
pycparser               2.21
Pygments                2.15.1
pynvim                  0.4.3
pyOpenSSL               23.0.0
pyproject-api           1.5.2
PySocks                 1.7.1
python-dateutil         2.8.2
PyYAML                  6.0
pyzmq                   25.0.2
ranger-fm               1.9.3
requests                2.29.0
ruamel.yaml             0.17.21
ruamel.yaml.clib        0.2.6
setuptools              67.8.0
six                     1.16.0
stack-data              0.2.0
tomli                   2.0.1
toolz                   0.12.0
tornado                 6.2
tox                     4.6.3
tqdm                    4.65.0
traitlets               5.7.1
urllib3                 1.26.15
virtualenv              20.23.1
wcwidth                 0.2.5
wheel                   0.38.4
zstandard               0.19.0

Output of the virtual environment creation

Make sure to run the creation with -vvv --with-traceback:

Didn't create virtual environment, just tried to run the tests
@kubouch kubouch added the bug label Jun 23, 2023
@jugmac00
Copy link
Contributor

Same for me with very different system setup.

As the last pull request succeeded, I suspect an unpinned test dependency to be the problem.

I have currently no time to investigate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants