Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,23 @@ show_missing = true
[run]
branch = true
cover_pylib = false
# NOTE: `disable_warnings` is needed when `pytest-cov` runs in tandem
# NOTE: with `pytest-xdist`. These warnings are false negative in this
# NOTE: context.
#
# NOTE: It's `coveragepy` that emits the warnings and previously they
# NOTE: wouldn't get on the radar of `pytest`'s `filterwarnings`
# NOTE: mechanism. This changed, however, with `pytest >= 8.4`. And
# NOTE: since we set `filterwarnings = error`, those warnings are being
# NOTE: raised as exceptions, cascading into `pytest`'s internals and
# NOTE: causing tracebacks and crashes of the test sessions.
#
# Ref:
# * https://github.com/pytest-dev/pytest-cov/issues/693
# * https://github.com/pytest-dev/pytest-cov/pull/695
# * https://github.com/pytest-dev/pytest-cov/pull/696
disable_warnings =
module-not-measured
plugins =
# covdefaults
Cython.Coverage
Expand Down
7 changes: 7 additions & 0 deletions docs/changelog-fragments/732.contrib.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
False negative warnings reported by ``coveragepy`` when are now
disabled. They are evident when ``pytest-cov`` runs with the
``pytest-xdist`` integration. ``pytest`` 8.4 gives them more
visibility and out ``filterwarnings = error`` setting was turning
them into errors before this change.

-- by :user:`webknjaz`
Loading