Skip to content

chore(deps): update dependency coverage to v7.18.0 - #211

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/coverage-7.18.x
Open

renovate[bot] wants to merge 1 commit into
mainfrom
renovate/coverage-7.18.x

Conversation

@renovate

@renovate renovate Bot commented Nov 29, 2026 •

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Change Age Confidence
coverage ==7.17.0 → ==7.18.0 age confidence

Release Notes

coveragepy/coveragepy (coverage)

v7.18.0

Compare Source

  • Feature: [run] source (and --source) entries can now be glob
    patterns, for example packages/*/src. A pattern is expanded to the
    directories it matches when measurement starts, so monorepo packages are
    measured, and their un-executed files reported, without listing each one.
    A pattern that matches nothing issues a warning. Closes issue 2400_.

  • Feature: two new methods for plug-ins to use in their test suites, as
    requested in issue 920_. The :meth:.Coverage.get_plugins method returns
    the currently registered plug-ins, including disabled ones. The
    :meth:.CoveragePlugin.is_enabled method reports their current enabled
    state.

  • Fix: lcov output now marks functions as starting on the first
    non-signature line, fixing errors about "inconsistent" tracefiles during
    combination. Closed issue 2394_.

  • Fix: XML and LCOV reports now honor the report context filter when
    calculating coverage.

  • Fix: when two source roots each contained a package with the same name, the
    XML report kept only one of the same-named files while still counting the
    lines of both, so lines-valid disagreed with the <line> elements in
    the document. Closes issue 1291_.

  • Fix: with [html] show_contexts enabled, re-running the HTML report kept
    pages whose lines were unchanged, even when the contexts were different, so
    they showed stale contexts. Closes issue 2372_.

  • Fix: with the C tracer and branch coverage, an error while starting to trace
    a function call (for example, RecursionError from should_trace when a
    new file is entered near the recursion limit) left the previous call's file
    in place. If the exception was caught, the function's return recorded arcs in
    that other file, which could report lines as executed that never ran. Now a
    call that fails to start records nothing, closing issue 2385_.

  • Fix: missing branch explanations for exits from a finally clause could
    incorrectly say a condition was always true, even when it was false while an
    exception or return was pending. These explanations now describe the missing
    jump without attributing it solely to the condition. Fixes issue 867_.

  • Fix: if a directory for the data file or a report couldn't be created, the
    error was a raw traceback. Now the error message names the file that was
    being written.

  • Performance: line coverage reports are faster when many measurement contexts
    cover the same file.

.. _issue 867: #​867
.. _issue 920: #​920
.. _issue 1291: nedbat#1291
.. _issue 2372: #​2372
.. _issue 2385: #​2385
.. _issue 2394: #​2394
.. _issue 2400: #​2400

.. _changelog-7.17.5:

v7.17.5

Compare Source

  • Fix: the reporting commands (report, html, xml, json,
    lcov, and annotate) used to put the current directory first on
    sys.path, to let plugins import local files. Now the current directory
    is added only if plugins are configured, and at the end of sys.path, so
    local files can't replace other modules.

  • Fix: local plugins interfered with erase and combine as reported in
    issue 1726_ and issue 1979. This is now fixed (pull 2253).

  • Fix: with the sysmon core on Python 3.14, starting and stopping a second
    Coverage object stopped the first one from measuring code it had already
    run. Closes issue 2302_.

  • Fix: combining data files failed with "Conflicting file tracer name" when
    one data file only listed a file without measuring it (as unexecuted source
    files are) and another measured the same file with a plugin. This happened
    in pytest-cov's distributed testing. Now a file with no measurements doesn't
    conflict with a plugin's measurements. Fixes issue 2358_.

  • Fix: saving data while another thread started measuring a new file handled
    by a plugin could fail with "dictionary changed size during iteration".
    Fixed in pull 2382_.

  • Fix: a keyboard interrupt at just the wrong moment could leave a lock locked
    and prevent saving data, as reported in issue 2383. This is now fixed
    (pull 2396
    ).

.. _issue 1726: #​1726
.. _issue 1979: #​1979
.. _pull 2253: #​2253
.. _issue 2302: #​2302
.. _issue 2358: #​2358
.. _pull 2382: #​2382
.. _issue 2383: #​2383
.. _pull 2396: #​2396

.. _changelog-7.17.4:

v7.17.4

Compare Source

  • Fix: since 7.13.1, a parallel data file could be named with the hash of
    different data than it held, for example when nbval records a notebook's
    coverage into pytest-cov's data file. Combining could then skip it as a
    duplicate and lose its data. Now the hash comes from the data in the file
    when it is saved. Fixes issue 2370_ with pull 2387_.

  • Fix: lines or arcs recorded by other threads while data was being flushed
    (for example during Coverage.get_data(), Coverage.save(), or dynamic
    context switches) could be lost. This is now fixed, closing issue 2384_.

  • Fix: on Python 3.14 with the pure-Python tracer (COVERAGE_CORE=pytrace)
    and branch measurement, a function that returned right after an except*
    handler recorded an arc with no line number. Reporting on the data then
    failed with a TypeError. Now that arc is not recorded. pull 2403_.

  • Fix: in the JSON report with show_contexts, each function and class had
    the contexts for every line in the file. Now they only have the contexts for
    their own lines. Closes issue 2374_.

  • Fix: The first entry in a [paths] list is the result path, and must be an
    actual file path. If it contained wildcards, the rule could never be used
    and was silently ignored. It is now reported as a configuration error.
    Closes issue 1531_.

  • Fix: a configuration file (.coveragerc, setup.cfg, tox.ini or
    pyproject.toml) saved with a UTF-8 byte order mark couldn't be read.
    Now a leading BOM is ignored. pull 2388_.

.. _issue 1531: #​1531
.. _issue 2370: #​2370
.. _issue 2374: #​2374
.. _issue 2384: #​2384
.. _pull 2387: #​2387
.. _pull 2388: #​2388
.. _pull 2403: #​2403

.. _changelog-7.17.3:

v7.17.3

Compare Source

  • Fix: using patch = fork, a child process wasn't measured unless patch = subprocess was also used, as described in issue 2340. This is now fixed
    in pull 2342
    .

  • Fix: the JSON report keys functions and classes by name, but names can
    repeat, for example a property getter and setter. Only the last one was
    kept, so the others were missing from the report. Now repeated names get a
    @<line number> suffix, as in the LCOV report. pull 2353_.

  • Fix: when combining parallel data files, a file that disappears after it
    has been listed (for example, when the process writing it is still finishing
    its write) is now reported with a warning, instead of stopping the combine
    with a DataError. This was a regression in 7.17.1. Closes issue 2364_.

  • Fix: with patch = subprocess on Python 3.13, a measured subprocess that
    was stopped with SIGINT would exit with status 1 instead of dying from the
    signal. This was a regression in 7.17.1, and is now fixed, closing issue 2362_.

  • Performance: on Python 3.13 and later, using the C tracer should result in
    test suites running about 8% to 12% faster (pull 2371_).

.. _issue 2340: #​2340
.. _pull 2342: #​2342
.. _pull 2353: #​2353
.. _issue 2364: #​2364
.. _issue 2362: #​2362
.. _pull 2371: #​2371

.. _changes_7-17-2:

v7.17.2

Compare Source

  • Fix: two different scenarios failed with "attempt to write a readonly
    database". These were regressions in 7.17.1. They are fixed, closing issue 2356_:

    • When using a version of SQLite older than 3.34.0, such as on RHEL 8 or
      Ubuntu 20.04, coverage combine (and pytest-cov, which combines
      automatically) always failed.

    • coverage combine and coverage debug data failed when a data file
      existed but had no coverage schema, for example an empty file left behind
      by a worker that died. A file we can't read is now reported like any other
      unusable data file, and is left in place.

.. _issue 2356: #​2356

.. _changes_7-17-1:

v7.17.1

Compare Source

  • Fix: a one-line class or function body immediately followed by another
    statement (such as class Foo: ... on its own line) was incorrectly
    reported as a missing branch when using the sys.monitoring core. This is now
    fixed, closing issue 2167_ and issue 2337_.

  • Fix: the HTML report only rewrites a file's page when the file or its data
    has changed, but each page also links to the previous and next files. When
    the set of reported files changed, unchanged pages kept their old links. For
    example, with skip_covered, a file that became 100% covered had its page
    deleted, but the pages next to it still linked to it. Now a page is also
    rewritten when its neighbors change.

  • Fix: --fail-under now uses at least the decimal precision of the
    threshold for both the comparison and failure message. With precision=0,
    a total of 0.4 now passes --fail-under=0.3 and fails --fail-under=0.5
    with the message "total of 0.4 is less than fail-under=0.5". Previously, the
    comparison rounded the total to zero and the message could claim "1 is less
    than 0". Closes issue 2295_.

  • Fix: the HTML report escaped file names twice, so a name with &, <,
    or quotes in it was shown with entities like &amp;. Now they are properly
    escaped only once.

  • Fix: --source=/ measured no files. A file system root can't be a source
    directory, so now it is an error. Closes issue 2291_.

  • In an abundance of caution, prevent forged SQLite journal files from deleting
    files they shouldn't.

.. _issue 2167: #​2167
.. _issue 2291: #​2291
.. _issue 2295: #​2295
.. _issue 2337: #​2337

.. _changes_7-17-0:


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant