-
Notifications
You must be signed in to change notification settings - Fork 22
Closed
Description
I have a meson-python project (https://github.com/akhmerov/python-mumps), and I object the following if I run spin test after spin install:
python-mumps$ spin test
Invoking `build` prior to running tests:
$ meson compile -C build
INFO: autodetecting backend as ninja
INFO: calculating backend command to run: /home/anton/micromamba/envs/py311/bin/ninja -C /home/anton/Bot/coding/python-mumps/build
ninja: Entering directory `/home/anton/Bot/coding/python-mumps/build'
ninja: no work to do.
$ meson install --only-changed -C build --destdir ../build-install
$ export PYTHONPATH="/home/anton/Bot/coding/python-mumps/build-install/usr/lib/python3.12/site-packages"
$ /home/anton/micromamba/envs/py311/bin/python3.12 -P -c 'import mumps'
$ export PYTHONPATH="/home/anton/Bot/coding/python-mumps/build-install/usr/lib/python3.12/site-packages"
$ cd /home/anton/Bot/coding/python-mumps/build-install/usr/lib/python3.12/site-packages
$ /home/anton/micromamba/envs/py311/bin/python3.12 -m pytest --rootdir=/home/anton/Bot/coding/python-mumps/build-install/usr/lib/python3.12/site-packages mumps
================================================================================= test session starts ==================================================================================
platform linux -- Python 3.12.1, pytest-8.0.0, pluggy-1.4.0
Using --randomly-seed=2233073045
rootdir: /home/anton/Bot/coding/python-mumps/build-install/usr/lib/python3.12/site-packages
configfile: ../../../../../pytest.ini
plugins: subtests-0.11.0, flake8-1.1.1, datadir-1.5.0, regressions-2.5.0, cov-4.1.0, flakes-4.0.5, anyio-4.2.0, randomly-3.15.0
collected 0 items / 1 error
======================================================================================== ERRORS ========================================================================================
______________________________________________________________________ ERROR collecting mumps/tests/test_mumps.py ______________________________________________________________________
import file mismatch:
imported module 'mumps.tests.test_mumps' has this __file__ attribute:
/home/anton/Bot/coding/python-mumps/mumps/tests/test_mumps.py
which is not the same as the test file we want to collect:
/home/anton/Bot/coding/python-mumps/build-install/usr/lib/python3.12/site-packages/mumps/tests/test_mumps.py
HINT: remove __pycache__ / .pyc files and/or use a unique basename for your test file modules
=============================================================================== short test summary info ================================================================================
ERROR mumps/tests/test_mumps.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
=================================================================================== 1 error in 0.25s ===================================================================================
spin test
functions properly if I do pip uninstall python-mumps
.
Metadata
Metadata
Assignees
Labels
No labels