Dear Pythons, as libtmux now requires python-gp-libs I started packaging it. The package builds without tests and is usable, aka libtmux builds. But the tests are failing. Or rather aborted due to _pytest.pathlib.ImportPathMismatchError errors
https://build.opensuse.org/package/live_build_log/home:ojkastl_buildservice:...
I have no clue why the tests are aborted. One thing I noted was that the package puts files into the %{python_sitelib}/ directory instead of into a subdirectory named after the package. Not sure if this is intended or related to the issues.
%{python_sitelib}/doctest_docutils.py %{python_sitelib}/docutils_compat.py %{python_sitelib}/gp_libs.py %{python_sitelib}/linkify_issues.py %{python_sitelib}/pytest_doctest_docutils.py
Thanks in advance for any hints! Kind Regards, Johannes Here is one of the three errors:
[ 32s] + pytest-3.9 --ignore=_build.python39 --ignore=_build.python310 --ignore=_build.python311 -v [ 32s] ============================= test session starts ============================== [ 32s] collecting ... collected 34 items / 3 errors [ 32s] [ 32s] ==================================== ERRORS ==================================== [ 32s] ___________________ ERROR collecting src/doctest_docutils.py ___________________ [ 32s] /usr/lib/python3.9/site-packages/_pytest/runner.py:341: in from_call [ 32s] result: Optional[TResult] = func() [ 32s] cls = <class '_pytest.runner.CallInfo'> [ 32s] duration = 0.00017835699986790132 [ 32s] excinfo = <ExceptionInfo ImportPathMismatchError('doctest_docutils', '/home/abuild/rpmbuild/BUILDROOT/python-gp-libs-0.0.4-0.x86...packages/doctest_docutils.py', PosixPa th('/home/abuild/rpmbuild/BUILD/gp_libs-0.0.4/src/doctest_docutils.py')) tblen=4> [ 32s] func = <function pytest_make_collect_report.<locals>.<lambda> at 0x7f4ac7c0a160> [ 32s] precise_start = 1551.728181141 [ 32s] precise_stop = 1551.728359498 [ 32s] reraise = None [ 32s] result = None [ 32s] start = 1700719116.762277 [ 32s] stop = 1700719116.7624557 [ 32s] when = 'collect' [ 32s] /usr/lib/python3.9/site-packages/_pytest/runner.py:372: in <lambda> [ 32s] call = CallInfo.from_call(lambda: list(collector.collect()), "collect") [ 32s] collector = <DoctestModule src/doctest_docutils.py> [ 32s] /usr/lib/python3.9/site-packages/_pytest/doctest.py:567: in collect [ 32s] module = import_path( [ 32s] MockAwareDocTestFinder = <class '_pytest.doctest.DoctestModule.collect.<locals>.MockAwareDocTestFinder'> [ 32s] doctest = <module 'doctest' from '/usr/lib64/python3.9/doctest.py'> [ 32s] self = <DoctestModule src/doctest_docutils.py> [ 32s] /usr/lib/python3.9/site-packages/_pytest/pathlib.py:590: in import_path [ 32s] raise ImportPathMismatchError(module_name, module_file, path) [ 32s] E _pytest.pathlib.ImportPathMismatchError: ('doctest_docutils', '/home/abuild/rpmbuild/BUILDROOT/python-gp-libs-0.0.4-0.x86_64/usr/lib/python3.9/site-packages/doctest_docutils.py ', PosixPath('/home/abuild/rpmbuild/BUILD/gp_libs-0.0.4/src/doctest_docutils.py')) [ 32s] ignore = '' [ 32s] is_same = False [ 32s] mod = <module 'doctest_docutils' from '/home/abuild/rpmbuild/BUILDROOT/python-gp-libs-0.0.4-0.x86_64/usr/lib/python3.9/site-packages/doctest_docutils.py'> [ 32s] mode = <ImportMode.prepend: 'prepend'> [ 32s] module_file = '/home/abuild/rpmbuild/BUILDROOT/python-gp-libs-0.0.4-0.x86_64/usr/lib/python3.9/site-packages/doctest_docutils.py' [ 32s] module_name = 'doctest_docutils' [ 32s] p = PosixPath('/home/abuild/rpmbuild/BUILD/gp_libs-0.0.4/src/doctest_docutils.py') [ 32s] path = PosixPath('/home/abuild/rpmbuild/BUILD/gp_libs-0.0.4/src/doctest_docutils.py') [ 32s] pkg_path = None [ 32s] pkg_root = PosixPath('/home/abuild/rpmbuild/BUILD/gp_libs-0.0.4/src') [ 32s] root = PosixPath('/home/abuild/rpmbuild/BUILD/gp_libs-0.0.4')
-- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537