Skip to content

1.6.0: pytest warnings #276

@kloczek

Description

@kloczek

I'm trying to package 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-cftime-1.6.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-cftime-1.6.0-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra -q
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.13, pytest-7.1.1, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/cftime-1.6.0rel, configfile: setup.cfg, testpaths: test
plugins: forked-1.4.0, xdist-2.5.0, cov-3.0.0
collected 2262 items

test/test_cftime.py ................................................................................................................................................ [  6%]
.................................................................................................................................................................... [ 13%]
.................................................................................................................................................................... [ 20%]
.................................................................................................................................................................... [ 28%]
.................................................................................................................................................................... [ 35%]
.................................................................................................................................................................... [ 42%]
.................................................................................................................................................................... [ 49%]
.................................................................................................................................................................... [ 57%]
.................................................................................................................................................................... [ 64%]
.................................................................................................................................................................... [ 71%]
.................................................................................................................................................................... [ 78%]
.................................................................................................................................................................... [ 86%]
.................................................................................................................................................................... [ 93%]
......................................................................................................................................................               [100%]

============================================================================= warnings summary =============================================================================
../../../../../usr/lib64/python3.8/site-packages/coverage/inorout.py:472
  /usr/lib64/python3.8/site-packages/coverage/inorout.py:472: CoverageWarning: --include is ignored because --source is set (include-ignored)
    self.warn("--include is ignored because --source is set", slug="include-ignored")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html

---------- coverage: platform linux, python 3.8.13-final-0 -----------
Name                                                                                                                       Stmts   Miss Branch BrPart  Cover   Missing
----------------------------------------------------------------------------------------------------------------------------------------------------------------------
/home/tkloczko/rpmbuild/BUILDROOT/python-cftime-1.6.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/cftime/__init__.py       5      0      0      0   100%
----------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOTAL                                                                                                                          5      0      0      0   100%

===================================================================== 2262 passed, 1 warning in 33.44s =====================================================================

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions