-
Notifications
You must be signed in to change notification settings - Fork 31
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
2.4: pytest is failing #34
Comments
PR #35 switches the main 'tox' environment to use 'py.test'. |
Thank you 😄 |
@kloczek The 2.4.1 release includes the changes from PR #35: CI for the project is now done on Github Actions, where tox runs |
Here it is result with 2.4.1 + PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-repoze-who-2.4.1-3.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-repoze-who-2.4.1-3.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.13, pytest-7.1.2, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1
collected 0 items / 12 errors
================================================================================== ERRORS ==================================================================================
________________________________________________________ ERROR collecting repoze/who/plugins/tests/test_authtkt.py _________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/plugins/tests/test_authtkt.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
_______________________________________________________ ERROR collecting repoze/who/plugins/tests/test_basicauth.py ________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/plugins/tests/test_basicauth.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
________________________________________________________ ERROR collecting repoze/who/plugins/tests/test_htpasswd.py ________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/plugins/tests/test_htpasswd.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
_______________________________________________________ ERROR collecting repoze/who/plugins/tests/test_redirector.py _______________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/plugins/tests/test_redirector.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
__________________________________________________________ ERROR collecting repoze/who/plugins/tests/test_sql.py ___________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/plugins/tests/test_sql.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
___________________________________________________________ ERROR collecting repoze/who/tests/test__auth_tkt.py ____________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test__auth_tkt.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
____________________________________________________________ ERROR collecting repoze/who/tests/test__compat.py _____________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test__compat.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
______________________________________________________________ ERROR collecting repoze/who/tests/test_api.py _______________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test_api.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
__________________________________________________________ ERROR collecting repoze/who/tests/test_classifiers.py ___________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test_classifiers.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
_____________________________________________________________ ERROR collecting repoze/who/tests/test_config.py _____________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test_config.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
___________________________________________________________ ERROR collecting repoze/who/tests/test_middleware.py ___________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test_middleware.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
____________________________________________________________ ERROR collecting repoze/who/tests/test_restrict.py ____________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/repoze.who-2.4.1/repoze/who/tests/test_restrict.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
E ModuleNotFoundError: No module named 'repoze.who'
========================================================================= short test summary info ==========================================================================
ERROR repoze/who/plugins/tests/test_authtkt.py
ERROR repoze/who/plugins/tests/test_basicauth.py
ERROR repoze/who/plugins/tests/test_htpasswd.py
ERROR repoze/who/plugins/tests/test_redirector.py
ERROR repoze/who/plugins/tests/test_sql.py
ERROR repoze/who/tests/test__auth_tkt.py
ERROR repoze/who/tests/test__compat.py
ERROR repoze/who/tests/test_api.py
ERROR repoze/who/tests/test_classifiers.py
ERROR repoze/who/tests/test_config.py
ERROR repoze/who/tests/test_middleware.py
ERROR repoze/who/tests/test_restrict.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 12 errors during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
============================================================================ 12 errors in 0.12s ============================================================================ |
pytest is working with |
@kloczek The tests all pass cleanly when run using $ python3.8 -m venv /tmp/r.who-34
$ /tmp/r.who-34/bin/pip install --upgrade setuptools pip wheel
Requirement already satisfied: setuptools in /tmp/r.who-34/lib/python3.8/site-packages (56.0.0)
Collecting setuptools
Using cached setuptools-63.2.0-py3-none-any.whl (1.2 MB)
Requirement already satisfied: pip in /tmp/r.who-34/lib/python3.8/site-packages (21.1.1)
Collecting pip
Using cached pip-22.1.2-py3-none-any.whl (2.1 MB)
Collecting wheel
Using cached wheel-0.37.1-py2.py3-none-any.whl (35 kB)
Installing collected packages: wheel, setuptools, pip
Attempting uninstall: setuptools
Found existing installation: setuptools 56.0.0
Uninstalling setuptools-56.0.0:
Successfully uninstalled setuptools-56.0.0
Attempting uninstall: pip
Found existing installation: pip 21.1.1
Uninstalling pip-21.1.1:
Successfully uninstalled pip-21.1.1
Successfully installed pip-22.1.2 setuptools-63.2.0 wheel-0.37.1
$ /tmp/r.who-34/bin/pip install -e .
Obtaining file:///.../repoze.who
Preparing metadata (setup.py) ... done
Collecting WebOb
Using cached WebOb-1.8.7-py2.py3-none-any.whl (114 kB)
Collecting zope.interface
Using cached zope.interface-5.4.0-cp38-cp38-manylinux2010_x86_64.whl (259 kB)
Requirement already satisfied: setuptools in /tmp/r.who-34/lib/python3.8/site-packages (from repoze.who==2.4.2.dev0) (63.2.0)
Installing collected packages: zope.interface, WebOb, repoze.who
Running setup.py develop for repoze.who
Successfully installed WebOb-1.8.7 repoze.who-2.4.2.dev0 zope.interface-5.4.0
$ /tmp/r.who-34/bin/pip install pytest
Collecting pytest
Using cached pytest-7.1.2-py3-none-any.whl (297 kB)
Collecting py>=1.8.2
Using cached py-1.11.0-py2.py3-none-any.whl (98 kB)
Collecting attrs>=19.2.0
Using cached attrs-21.4.0-py2.py3-none-any.whl (60 kB)
Collecting tomli>=1.0.0
Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Collecting iniconfig
Using cached iniconfig-1.1.1-py2.py3-none-any.whl (5.0 kB)
Collecting packaging
Using cached packaging-21.3-py3-none-any.whl (40 kB)
Collecting pluggy<2.0,>=0.12
Using cached pluggy-1.0.0-py2.py3-none-any.whl (13 kB)
Collecting pyparsing!=3.0.5,>=2.0.2
Using cached pyparsing-3.0.9-py3-none-any.whl (98 kB)
Installing collected packages: iniconfig, tomli, pyparsing, py, pluggy, attrs, packaging, pytest
Successfully installed attrs-21.4.0 iniconfig-1.1.1 packaging-21.3 pluggy-1.0.0 py-1.11.0 pyparsing-3.0.9 pytest-7.1.2 tomli-2.0.1
$ /tmp/r.who-34/bin/py.test
============================= test session starts ==============================
platform linux -- Python 3.8.12, pytest-7.1.2, pluggy-1.0.0
rootdir: /.../repoze.who
collected 306 items
repoze/who/plugins/tests/test_authtkt.py ............................... [ 10%]
................... [ 16%]
repoze/who/plugins/tests/test_basicauth.py .............. [ 20%]
repoze/who/plugins/tests/test_htpasswd.py ............... [ 25%]
repoze/who/plugins/tests/test_redirector.py .................. [ 31%]
repoze/who/plugins/tests/test_sql.py ....................... [ 39%]
repoze/who/tests/test__auth_tkt.py ......................... [ 47%]
repoze/who/tests/test__helpers.py ...................... [ 54%]
repoze/who/tests/test_api.py ........................................... [ 68%]
................ [ 73%]
repoze/who/tests/test_classifiers.py ............... [ 78%]
repoze/who/tests/test_config.py ........................... [ 87%]
repoze/who/tests/test_middleware.py ............................ [ 96%]
repoze/who/tests/test_restrict.py .......... [100%]
============================= 306 passed in 0.42s ============================= If you can reproduce the issue in a clean virtual environment, please follow up. We wont be making changes to support hand-hacked |
That is my fault because I forgot exac procedure.
|
Looks like issue described on pytest-dev/pytest#3151 (where are as well links to solutions in many modules).
Here is pytest log
The text was updated successfully, but these errors were encountered: