github nedbat/coveragepy coverage-4.3
4.3

latest releases: 7.6.3, 7.6.2, 7.6.1...
21 hours ago

Version 4.3 — 2016-12-27

Special thanks to Loïc Dachary, who took an extraordinary interest in coverage.py and contributed a number of improvements in this release.

  • Subprocesses that are measured with automatic subprocess measurement used to read in any pre-existing data file. This meant data would be incorrectly carried forward from run to run. Now those files are not read, so each subprocess only writes its own data. Fixes issue 510.
  • The coverage combine command will now fail if there are no data files to combine. The combine changes in 4.2 meant that multiple combines could lose data, leaving you with an empty .coverage data file. Fixes issue 525, issue 412, issue 516, and probably issue 511.
  • Coverage.py wouldn’t execute sys.excepthook when an exception happened in your program. Now it does, thanks to Andrew Hoos. Closes issue 535.
  • Branch coverage fixes:
    • Branch coverage could misunderstand a finally clause on a try block that never continued on to the following statement, as described in issue 493. This is now fixed. Thanks to Joe Doherty for the report and Loïc Dachary for the fix.
    • A while loop with a constant condition (while True) and a continue statement would be mis-analyzed, as described in issue 496. This is now fixed, thanks to a bug report by Eli Skeggs and a fix by Loïc Dachary.
    • While loops with constant conditions that were never executed could result in a non-zero coverage report. Artem Dayneko reported this in issue 502, and Loïc Dachary provided the fix.
  • The HTML report now supports a --skip-covered option like the other reporting commands. Thanks, Loïc Dachary for the implementation, closing issue 433.
  • Options can now be read from a tox.ini file, if any. Like setup.cfg, sections are prefixed with “coverage:”, so [run] options will be read from the [coverage:run] section of tox.ini. Implements part of issue 519. Thanks, Stephen Finucane.
  • Specifying both --source and --include no longer silently ignores the include setting, instead it fails with a message. Thanks, Nathan Land and Loïc Dachary. Closes issue 265.
  • The Coverage.combine method has a new parameter, strict=False, to support failing if there are no data files to combine.
  • When forking subprocesses, the coverage data files would have the same random number appended to the file name. This didn’t cause problems, because the file names had the process id also, making collisions (nearly) impossible. But it was disconcerting. This is now fixed.
  • The text report now properly sizes headers when skipping some files, fixing issue 524. Thanks, Anthony Sottile and Loïc Dachary.
  • Coverage.py can now search .pex files for source, just as it can .zip and .egg. Thanks, Peter Ebden.
  • Data files are now about 15% smaller.
  • Improvements in the [run] debug setting:
    • The “dataio” debug setting now also logs when data files are deleted during combining or erasing.
    • A new debug option, “multiproc”, for logging the behavior of concurrency=multiprocessing.
    • If you used the debug options “config” and “callers” together, you’d get a call stack printed for every line in the multi-line config output. This is now fixed.
  • Fixed an unusual bug involving multiple coding declarations affecting code containing code in multi-line strings: issue 529.
  • Coverage.py will no longer be misled into thinking that a plain file is a package when interpreting --source options. Thanks, Cosimo Lupo.
  • If you try to run a non-Python file with coverage.py, you will now get a more useful error message. Issue 514.
  • The default pragma regex changed slightly, but this will only matter to you if you are deranged and use mixed-case pragmas.
  • Deal properly with non-ASCII file names in an ASCII-only world, issue 533.
  • Programs that set Unicode configuration values could cause UnicodeErrors when generating HTML reports. Pytest-cov is one example. This is now fixed.
  • Prevented deprecation warnings from configparser that happened in some circumstances, closing issue 530.
  • Corrected the name of the jquery.ba-throttle-debounce.js library. Thanks, Ben Finney. Closes issue 505.
  • Testing against PyPy 5.6 and PyPy3 5.5.
  • Switched to pytest from nose for running the coverage.py tests.
  • Renamed AUTHORS.txt to CONTRIBUTORS.txt, since there are other ways to contribute than by writing code. Also put the count of contributors into the author string in setup.py, though this might be too cute.

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

Don't miss a new coveragepy release

NewReleases is sending notifications on new releases.