Version 5.0a5 — 2019-05-07
- Drop support for Python 3.4
- Dynamic contexts can now be set two new ways, both thanks to Justas Sadzevičius.
- A plugin can implement a
dynamic_context
method to check frames for whether a new context should be started. See Dynamic Context Switchers for more details. - Another tool (such as a test runner) can use the new Coverage.switch_context() method to explicitly change the context.
- A plugin can implement a
- The
dynamic_context = test_function
setting now works with Python 2 old-style classes, though it only reports the method name, not the class it was defined on. Closes issue 797. fail_under
values more than 100 are reported as errors. Thanks to Mike Fiedler for closing issue 746.- The “missing” values in the text output are now sorted by line number, so that missing branches are reported near the other lines they affect. The values used to show all missing lines, and then all missing branches.
- Access to the SQLite database used for data storage is now thread-safe. Thanks, Stephan Richter. This closes issue 702.
- Combining data stored in SQLite is now about twice as fast, fixing issue 761. Thanks, Stephan Richter.
- The
filename
attribute on CoverageData objects has been made private. You can use thedata_filename
method to get the actual file name being used to store data, and thebase_filename
method to get the original filename before parallelizing suffixes were added. This is part of fixing issue 708. - Line numbers in the HTML report now align properly with source lines, even when Chrome’s minimum font size is set, fixing issue 748. Thanks Wen Ye.
➡️ PyPI page: coverage 5.0a5.
➡️ To install: python3 -m pip install coverage==5.0a5