Skip to content

Releases: nedbat/coveragepy

7.0.4

13 Oct 23:36
7.0.4
f4c27c7
Compare
Choose a tag to compare

Version 7.0.4 — 2023-01-07

  • Performance: an internal cache of file names was accidentally disabled, resulting in sometimes drastic reductions in performance. This is now fixed, closing issue 1527. Thanks to Ivan Ciuvalschii for the reproducible test case.

➡️  PyPI page: coverage 7.0.4.
➡️  To install: python3 -m pip install coverage==7.0.4

7.0.3

13 Oct 23:36
7.0.3
2ff9098
Compare
Choose a tag to compare

Version 7.0.3 — 2023-01-03

  • Fix: when using pytest-cov or pytest-xdist, or perhaps both, the combining step could fail with assert row is not None using 7.0.2. This was due to a race condition that has always been possible and is still possible. In 7.0.1 and before, the error was silently swallowed by the combining code. Now it will produce a message “Couldn’t combine data file” and ignore the data file as it used to do before 7.0.2. Closes issue 1522.

➡️  PyPI page: coverage 7.0.3.
➡️  To install: python3 -m pip install coverage==7.0.3

7.0.2

13 Oct 23:36
7.0.2
2f731e2
Compare
Choose a tag to compare

Version 7.0.2 — 2023-01-02

  • Fix: when using the [run] relative_files = True setting, a relative [paths] pattern was still being made absolute. This is now fixed, closing issue 1519.
  • Fix: if Python doesn’t provide tomllib, then TOML configuration files can only be read if coverage.py is installed with the [toml] extra. Coverage.py will raise an error if TOML support is not installed when it sees your settings are in a .toml file. But it didn’t understand that [tools.coverage] was a valid section header, so the error wasn’t reported if you used that header, and settings were silently ignored. This is now fixed, closing issue 1516.
  • Fix: adjusted how decorators are traced on PyPy 7.3.10, fixing issue 1515.
  • Fix: the coverage lcov report did not properly implement the --fail-under=MIN option. This has been fixed.
  • Refactor: added many type annotations, including a number of refactorings. This should not affect outward behavior, but they were a bit invasive in some places, so keep your eyes peeled for oddities.
  • Refactor: removed the vestigial and long untested support for Jython and IronPython.

➡️  PyPI page: coverage 7.0.2.
➡️  To install: python3 -m pip install coverage==7.0.2

7.0.1

13 Oct 23:36
7.0.1
c5cda3a
Compare
Choose a tag to compare

Version 7.0.1 — 2022-12-23

  • When checking if a file mapping resolved to a file that exists, we weren’t considering files in .whl files. This is now fixed, closing issue 1511.
  • File pattern rules were too strict, forbidding plus signs and curly braces in directory and file names. This is now fixed, closing issue 1513.
  • Unusual Unicode or control characters in source files could prevent reporting. This is now fixed, closing issue 1512.
  • The PyPy wheel now installs on PyPy 3.7, 3.8, and 3.9, closing issue 1510.

➡️  PyPI page: coverage 7.0.1.
➡️  To install: python3 -m pip install coverage==7.0.1

7.0.0

13 Oct 23:36
7.0.0
df3f2bf
Compare
Choose a tag to compare

Version 7.0.0 — 2022-12-18

Nothing new beyond 7.0.0b1.

➡️  PyPI page: coverage 7.0.0.
➡️  To install: python3 -m pip install coverage==7.0.0

7.0.0b1

13 Oct 23:36
7.0.0b1
f09e389
Compare
Choose a tag to compare
7.0.0b1 Pre-release
Pre-release

Version 7.0.0b1 — 2022-12-03

A number of changes have been made to file path handling, including pattern matching and path remapping with the [paths] setting (see [paths]). These changes might affect you, and require you to update your settings.

(This release includes the changes from 6.6.0b1, since 6.6.0 was never released.)

  • Changes to file pattern matching, which might require updating your configuration:
    • Previously, * would incorrectly match directory separators, making precise matching difficult. This is now fixed, closing issue 1407.
    • Now ** matches any number of nested directories, including none.
  • Improvements to combining data files when using the [run] relative_files setting, which might require updating your configuration:
    • During coverage combine, relative file paths are implicitly combined without needing a [paths] configuration setting. This also fixed issue 991.
    • A [paths] setting like */foo will now match foo/bar.py so that relative file paths can be combined more easily.
    • The [run] relative_files setting is properly interpreted in more places, fixing issue 1280.
  • When remapping file paths with [paths], a path will be remapped only if the resulting path exists. The documentation has long said the prefix had to exist, but it was never enforced. This fixes issue 608, improves issue 649, and closes issue 757.
  • Reporting operations now implicitly use the [paths] setting to remap file paths within a single data file. Combining multiple files still requires the coverage combine step, but this simplifies some single-file situations. Closes issue 1212 and issue 713.
  • The coverage report command now has a --format= option. The original style is now --format=text, and is the default.
    • Using --format=markdown will write the table in Markdown format, thanks to Steve Oswald, closing issue 1418.
    • Using --format=total will write a single total number to the output. This can be useful for making badges or writing status updates.
  • Combining data files with coverage combine now hashes the data files to skip files that add no new information. This can reduce the time needed. Many details affect the speed-up, but for coverage.py’s own test suite, combining is about 40% faster. Closes issue 1483.
  • When searching for completely un-executed files, coverage.py uses the presence of __init__.py files to determine which directories have source that could have been imported. However, implicit namespace packages don’t require __init__.py. A new setting [report] include_namespace_packages tells coverage.py to consider these directories during reporting. Thanks to Felix Horvat for the contribution. Closes issue 1383 and issue 1024.
  • Fixed environment variable expansion in pyproject.toml files. It was overly broad, causing errors outside of coverage.py settings, as described in issue 1481 and issue 1345. This is now fixed, but in rare cases will require changing your pyproject.toml to quote non-string values that use environment substitution.
  • An empty file has a coverage total of 100%, but used to fail with --fail-under. This has been fixed, closing issue 1470.
  • The text report table no longer writes out two separator lines if there are no files listed in the table. One is plenty.
  • Fixed a mis-measurement of a strange use of wildcard alternatives in match/case statements, closing issue 1421.
  • Fixed internal logic that prevented coverage.py from running on implementations other than CPython or PyPy (issue 1474).
  • The deprecated [run] note setting has been completely removed.

➡️  PyPI page: coverage 7.0.0b1.
➡️  To install: python3 -m pip install coverage==7.0.0b1

6.6.0b1

13 Oct 23:35
6.6.0b1
64559a0
Compare
Choose a tag to compare
6.6.0b1 Pre-release
Pre-release

Version 6.6.0b1 — 2022-10-31

(Note: 6.6.0 final was never released. These changes are part of 7.0.0b1.)

  • Changes to file pattern matching, which might require updating your configuration:
    • Previously, * would incorrectly match directory separators, making precise matching difficult. This is now fixed, closing issue 1407.
    • Now ** matches any number of nested directories, including none.
  • Improvements to combining data files when using the [run] relative_files setting:
    • During coverage combine, relative file paths are implicitly combined without needing a [paths] configuration setting. This also fixed issue 991.
    • A [paths] setting like */foo will now match foo/bar.py so that relative file paths can be combined more easily.
    • The setting is properly interpreted in more places, fixing issue 1280.
  • Fixed environment variable expansion in pyproject.toml files. It was overly broad, causing errors outside of coverage.py settings, as described in issue 1481 and issue 1345. This is now fixed, but in rare cases will require changing your pyproject.toml to quote non-string values that use environment substitution.
  • Fixed internal logic that prevented coverage.py from running on implementations other than CPython or PyPy (issue 1474).

➡️  PyPI page: coverage 6.6.0b1.
➡️  To install: python3 -m pip install coverage==6.6.0b1

6.5.0

13 Oct 23:35
Compare
Choose a tag to compare

Version 6.5.0 — 2022-09-29

  • The JSON report now includes details of which branches were taken, and which are missing for each file. Thanks, Christoph Blessing. Closes issue 1425.
  • Starting with coverage.py 6.2, class statements were marked as a branch. This wasn’t right, and has been reverted, fixing issue 1449. Note this will very slightly reduce your coverage total if you are measuring branch coverage.
  • Packaging is now compliant with PEP 517, closing issue 1395.
  • A new debug option --debug=pathmap shows details of the remapping of paths that happens during combine due to the [paths] setting.
  • Fix an internal problem with caching of invalid Python parsing. Found by OSS-Fuzz, fixing their bug 50381.

➡️  PyPI page: coverage 6.5.0.
➡️  To install: python3 -m pip install coverage==6.5.0

6.4.4

13 Oct 23:35
Compare
Choose a tag to compare

Version 6.4.4 — 2022-08-16

  • Wheels are now provided for Python 3.11.

➡️  PyPI page: coverage 6.4.4.
➡️  To install: python3 -m pip install coverage==6.4.4

6.4.3

13 Oct 23:35
Compare
Choose a tag to compare

Version 6.4.3 — 2022-08-06

  • Fix a failure when combining data files if the file names contained glob-like patterns. Thanks, Michael Krebs and Benjamin Schubert.
  • Fix a messaging failure when combining Windows data files on a different drive than the current directory, closing issue 1428. Thanks, Lorenzo Micò.
  • Fix path calculations when running in the root directory, as you might do in a Docker container. Thanks Arthur Rio.
  • Filtering in the HTML report wouldn’t work when reloading the index page. This is now fixed. Thanks, Marc Legendre.
  • Fix a problem with Cython code measurement, closing issue 972. Thanks, Matus Valo.

➡️  PyPI page: coverage 6.4.3.
➡️  To install: python3 -m pip install coverage==6.4.3