You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
because I'm calling build with --no-isolation I'm using during all processes only locally installed modules
install .whl file in </install/prefix>
run pytest with PYTHONPATH pointing to sitearch and sitelib inside </install/prefix>
Here is pytest output:
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-intervaltree-3.1.0-8.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-intervaltree-3.1.0-8.fc35.x86_64/usr/lib/python3.8/site-packages+ /usr/bin/pytest -ra -m 'not network'==================================================================================== test session starts ====================================================================================platform linux -- Python 3.8.16, pytest-7.2.0, pluggy-1.0.0rootdir: /home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0, configfile: setup.cfgcollected 99 items / 3 errors========================================================================================== ERRORS ===========================================================================================_________________________________________________________________________ ERROR collecting intervaltree/interval.py _________________________________________________________________________/usr/lib/python3.8/site-packages/_pytest/runner.py:339: in from_call result: Optional[TResult] = func()/usr/lib/python3.8/site-packages/_pytest/runner.py:370: in <lambda> call = CallInfo.from_call(lambda: list(collector.collect()), "collect")/usr/lib/python3.8/site-packages/_pytest/doctest.py:548: in collect module = import_path(/usr/lib/python3.8/site-packages/_pytest/pathlib.py:556: in import_path raise ImportPathMismatchError(module_name, module_file, path)E _pytest.pathlib.ImportPathMismatchError: ('intervaltree.interval', '/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/build/lib/intervaltree/interval.py', PosixPath('/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/intervaltree/interval.py'))_______________________________________________________________________ ERROR collecting intervaltree/intervaltree.py _______________________________________________________________________/usr/lib/python3.8/site-packages/_pytest/runner.py:339: in from_call result: Optional[TResult] = func()/usr/lib/python3.8/site-packages/_pytest/runner.py:370: in <lambda> call = CallInfo.from_call(lambda: list(collector.collect()), "collect")/usr/lib/python3.8/site-packages/_pytest/doctest.py:548: in collect module = import_path(/usr/lib/python3.8/site-packages/_pytest/pathlib.py:556: in import_path raise ImportPathMismatchError(module_name, module_file, path)E _pytest.pathlib.ImportPathMismatchError: ('intervaltree.intervaltree', '/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/build/lib/intervaltree/intervaltree.py', PosixPath('/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/intervaltree/intervaltree.py'))___________________________________________________________________________ ERROR collecting intervaltree/node.py ___________________________________________________________________________/usr/lib/python3.8/site-packages/_pytest/runner.py:339: in from_call result: Optional[TResult] = func()/usr/lib/python3.8/site-packages/_pytest/runner.py:370: in <lambda> call = CallInfo.from_call(lambda: list(collector.collect()), "collect")/usr/lib/python3.8/site-packages/_pytest/doctest.py:548: in collect module = import_path(/usr/lib/python3.8/site-packages/_pytest/pathlib.py:556: in import_path raise ImportPathMismatchError(module_name, module_file, path)E _pytest.pathlib.ImportPathMismatchError: ('intervaltree.node', '/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/build/lib/intervaltree/node.py', PosixPath('/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/intervaltree/node.py'))================================================================================== short test summary info ==================================================================================ERROR intervaltree/interval.py - _pytest.pathlib.ImportPathMismatchError: ('intervaltree.interval', '/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/build/lib/intervaltree/interval.py', PosixPath('/home/tkloczko/rpmb...ERROR intervaltree/intervaltree.py - _pytest.pathlib.ImportPathMismatchError: ('intervaltree.intervaltree', '/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/build/lib/intervaltree/intervaltree.py', PosixPath('/home/tkloc...ERROR intervaltree/node.py - _pytest.pathlib.ImportPathMismatchError: ('intervaltree.node', '/home/tkloczko/rpmbuild/BUILD/intervaltree-3.1.0/build/lib/intervaltree/node.py', PosixPath('/home/tkloczko/rpmbuild/BUI...!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 3 errors during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!==================================================================================== 3 errors in 17.33s =====================================================================================
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
build
with--no-isolation
I'm using during all processes only locally installed modulesHere is pytest output:
Here is list of installed modules in build env
The text was updated successfully, but these errors were encountered: