1.. Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 2.. For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt 3 4============================== 5Change history for coverage.py 6============================== 7 8These changes are listed in decreasing version number order. Note this can be 9different from a strict chronological order when there are two branches in 10development at the same time, such as 4.5.x and 5.0. 11 12This list is detailed and covers changes in each pre-release version. If you 13want to know what's different in 5.0 since 4.5.x, see :ref:`whatsnew5x`. 14 15 16 .. When updating the "Unreleased" header to a specific version, use this 17 .. format. Don't forget the jump target: 18 .. 19 .. .. _changes_981: 20 .. 21 .. Version 9.8.1 --- 2027-07-27 22 .. ---------------------------- 23 24 25.. _changes_51: 26 27Version 5.1 --- 2020-04-12 28-------------------------- 29 30- The JSON report now includes counts of covered and missing branches. Thanks, 31 Salvatore Zagaria. 32 33- On Python 3.8, try-finally-return reported wrong branch coverage with 34 decorated async functions (`issue 946`_). This is now fixed. Thanks, Kjell 35 Braden. 36 37- The :meth:`~coverage.Coverage.get_option` and 38 :meth:`~coverage.Coverage.set_option` methods can now manipulate the 39 ``[paths]`` configuration setting. Thanks to Bernát Gábor for the fix for 40 `issue 967`_. 41 42.. _issue 946: https://github.com/nedbat/coveragepy/issues/946 43.. _issue 967: https://github.com/nedbat/coveragepy/issues/967 44 45 46.. _changes_504: 47 48Version 5.0.4 --- 2020-03-16 49---------------------------- 50 51- If using the ``[run] relative_files`` setting, the XML report will use 52 relative files in the ``<source>`` elements indicating the location of source 53 code. Closes `issue 948`_. 54 55- The textual summary report could report missing lines with negative line 56 numbers on PyPy3 7.1 (`issue 943`_). This is now fixed. 57 58- Windows wheels for Python 3.8 were incorrectly built, but are now fixed. 59 (`issue 949`_) 60 61- Updated Python 3.9 support to 3.9a4. 62 63- HTML reports couldn't be sorted if localStorage wasn't available. This is now 64 fixed: sorting works even though the sorting setting isn't retained. (`issue 65 944`_ and `pull request 945`_). Thanks, Abdeali Kothari. 66 67.. _issue 943: https://github.com/nedbat/coveragepy/issues/943 68.. _issue 944: https://github.com/nedbat/coveragepy/issues/944 69.. _pull request 945: https://github.com/nedbat/coveragepy/pull/945 70.. _issue 948: https://github.com/nedbat/coveragepy/issues/948 71.. _issue 949: https://github.com/nedbat/coveragepy/issues/949 72 73 74.. _changes_503: 75 76Version 5.0.3 --- 2020-01-12 77---------------------------- 78 79- A performance improvement in 5.0.2 didn't work for test suites that changed 80 directory before combining data, causing "Couldn't use data file: no such 81 table: meta" errors (`issue 916`_). This is now fixed. 82 83- Coverage could fail to run your program with some form of "ModuleNotFound" or 84 "ImportError" trying to import from the current directory. This would happen 85 if coverage had been packaged into a zip file (for example, on Windows), or 86 was found indirectly (for example, by pyenv-virtualenv). A number of 87 different scenarios were described in `issue 862`_ which is now fixed. Huge 88 thanks to Agbonze O. Jeremiah for reporting it, and Alexander Waters and 89 George-Cristian Bîrzan for protracted debugging sessions. 90 91- Added the "premain" debug option. 92 93- Added SQLite compile-time options to the "debug sys" output. 94 95.. _issue 862: https://github.com/nedbat/coveragepy/issues/862 96.. _issue 916: https://github.com/nedbat/coveragepy/issues/916 97 98 99.. _changes_502: 100 101Version 5.0.2 --- 2020-01-05 102---------------------------- 103 104- Programs that used multiprocessing and changed directories would fail under 105 coverage. This is now fixed (`issue 890`_). A side effect is that debug 106 information about the config files read now shows absolute paths to the 107 files. 108 109- When running programs as modules (``coverage run -m``) with ``--source``, 110 some measured modules were imported before coverage starts. This resulted in 111 unwanted warnings ("Already imported a file that will be measured") and a 112 reduction in coverage totals (`issue 909`_). This is now fixed. 113 114- If no data was collected, an exception about "No data to report" could happen 115 instead of a 0% report being created (`issue 884`_). This is now fixed. 116 117- The handling of source files with non-encodable file names has changed. 118 Previously, if a file name could not be encoded as UTF-8, an error occurred, 119 as described in `issue 891`_. Now, those files will not be measured, since 120 their data would not be recordable. 121 122- A new warning ("dynamic-conflict") is issued if two mechanisms are trying to 123 change the dynamic context. Closes `issue 901`_. 124 125- ``coverage run --debug=sys`` would fail with an AttributeError. This is now 126 fixed (`issue 907`_). 127 128.. _issue 884: https://github.com/nedbat/coveragepy/issues/884 129.. _issue 890: https://github.com/nedbat/coveragepy/issues/890 130.. _issue 891: https://github.com/nedbat/coveragepy/issues/891 131.. _issue 901: https://github.com/nedbat/coveragepy/issues/901 132.. _issue 907: https://github.com/nedbat/coveragepy/issues/907 133.. _issue 909: https://github.com/nedbat/coveragepy/issues/909 134 135 136.. _changes_501: 137 138Version 5.0.1 --- 2019-12-22 139---------------------------- 140 141- If a 4.x data file is the cause of a "file is not a database" error, then use 142 a more specific error message, "Looks like a coverage 4.x data file, are you 143 mixing versions of coverage?" Helps diagnose the problems described in 144 `issue 886`_. 145 146- Measurement contexts and relative file names didn't work together, as 147 reported in `issue 899`_ and `issue 900`_. This is now fixed, thanks to 148 David Szotten. 149 150- When using ``coverage run --concurrency=multiprocessing``, all data files 151 should be named with parallel-ready suffixes. 5.0 mistakenly named the main 152 process' file with no suffix when using ``--append``. This is now fixed, 153 closing `issue 880`_. 154 155- Fixed a problem on Windows when the current directory is changed to a 156 different drive (`issue 895`_). Thanks, Olivier Grisel. 157 158- Updated Python 3.9 support to 3.9a2. 159 160.. _issue 880: https://github.com/nedbat/coveragepy/issues/880 161.. _issue 886: https://github.com/nedbat/coveragepy/issues/886 162.. _issue 895: https://github.com/nedbat/coveragepy/issues/895 163.. _issue 899: https://github.com/nedbat/coveragepy/issues/899 164.. _issue 900: https://github.com/nedbat/coveragepy/issues/900 165 166 167.. _changes_50: 168 169Version 5.0 --- 2019-12-14 170-------------------------- 171 172Nothing new beyond 5.0b2. 173 174 175.. _changes_50b2: 176 177Version 5.0b2 --- 2019-12-08 178---------------------------- 179 180- An experimental ``[run] relative_files`` setting tells coverage to store 181 relative file names in the data file. This makes it easier to run tests in 182 one (or many) environments, and then report in another. It has not had much 183 real-world testing, so it may change in incompatible ways in the future. 184 185- When constructing a :class:`coverage.Coverage` object, `data_file` can be 186 specified as None to prevent writing any data file at all. In previous 187 versions, an explicit `data_file=None` argument would use the default of 188 ".coverage". Fixes `issue 871`_. 189 190- Python files run with ``-m`` now have ``__spec__`` defined properly. This 191 fixes `issue 745`_ (about not being able to run unittest tests that spawn 192 subprocesses), and `issue 838`_, which described the problem directly. 193 194- The ``[paths]`` configuration section is now ordered. If you specify more 195 than one list of patterns, the first one that matches will be used. Fixes 196 `issue 649`_. 197 198- The :func:`.coverage.numbits.register_sqlite_functions` function now also 199 registers `numbits_to_nums` for use in SQLite queries. Thanks, Simon 200 Willison. 201 202- Python 3.9a1 is supported. 203 204- Coverage.py has a mascot: :ref:`Sleepy Snake <sleepy>`. 205 206.. _issue 649: https://github.com/nedbat/coveragepy/issues/649 207.. _issue 745: https://github.com/nedbat/coveragepy/issues/745 208.. _issue 838: https://github.com/nedbat/coveragepy/issues/838 209.. _issue 871: https://github.com/nedbat/coveragepy/issues/871 210 211 212.. _changes_50b1: 213 214Version 5.0b1 --- 2019-11-11 215---------------------------- 216 217- The HTML and textual reports now have a ``--skip-empty`` option that skips 218 files with no statements, notably ``__init__.py`` files. Thanks, Reya B. 219 220- Configuration can now be read from `TOML`_ files. This requires installing 221 coverage.py with the ``[toml]`` extra. The standard "pyproject.toml" file 222 will be read automatically if no other configuration file is found, with 223 settings in the ``[tool.coverage.]`` namespace. Thanks to Frazer McLean for 224 implementation and persistence. Finishes `issue 664`_. 225 226- The ``[run] note`` setting has been deprecated. Using it will result in a 227 warning, and the note will not be written to the data file. The 228 corresponding :class:`.CoverageData` methods have been removed. 229 230- The HTML report has been reimplemented (no more table around the source 231 code). This allowed for a better presentation of the context information, 232 hopefully resolving `issue 855`_. 233 234- Added sqlite3 module version information to ``coverage debug sys`` output. 235 236- Asking the HTML report to show contexts (``[html] show_contexts=True`` or 237 ``coverage html --show-contexts``) will issue a warning if there were no 238 contexts measured (`issue 851`_). 239 240.. _TOML: https://github.com/toml-lang/toml#readme 241.. _issue 664: https://github.com/nedbat/coveragepy/issues/664 242.. _issue 851: https://github.com/nedbat/coveragepy/issues/851 243.. _issue 855: https://github.com/nedbat/coveragepy/issues/855 244 245 246.. _changes_50a8: 247 248Version 5.0a8 --- 2019-10-02 249---------------------------- 250 251- The :class:`.CoverageData` API has changed how queries are limited to 252 specific contexts. Now you use :meth:`.CoverageData.set_query_context` to 253 set a single exact-match string, or :meth:`.CoverageData.set_query_contexts` 254 to set a list of regular expressions to match contexts. This changes the 255 command-line ``--contexts`` option to use regular expressions instead of 256 filename-style wildcards. 257 258 259.. _changes_50a7: 260 261Version 5.0a7 --- 2019-09-21 262---------------------------- 263 264- Data can now be "reported" in JSON format, for programmatic use, as requested 265 in `issue 720`_. The new ``coverage json`` command writes raw and summarized 266 data to a JSON file. Thanks, Matt Bachmann. 267 268- Dynamic contexts are now supported in the Python tracer, which is important 269 for PyPy users. Closes `issue 846`_. 270 271- The compact line number representation introduced in 5.0a6 is called a 272 "numbits." The :mod:`coverage.numbits` module provides functions for working 273 with them. 274 275- The reporting methods used to permanently apply their arguments to the 276 configuration of the Coverage object. Now they no longer do. The arguments 277 affect the operation of the method, but do not persist. 278 279- A class named "test_something" no longer confuses the ``test_function`` 280 dynamic context setting. Fixes `issue 829`_. 281 282- Fixed an unusual tokenizing issue with backslashes in comments. Fixes 283 `issue 822`_. 284 285- ``debug=plugin`` didn't properly support configuration or dynamic context 286 plugins, but now it does, closing `issue 834`_. 287 288.. _issue 720: https://github.com/nedbat/coveragepy/issues/720 289.. _issue 822: https://github.com/nedbat/coveragepy/issues/822 290.. _issue 834: https://github.com/nedbat/coveragepy/issues/834 291.. _issue 829: https://github.com/nedbat/coveragepy/issues/829 292.. _issue 846: https://github.com/nedbat/coveragepy/issues/846 293 294 295.. _changes_50a6: 296 297Version 5.0a6 --- 2019-07-16 298---------------------------- 299 300- Reporting on contexts. Big thanks to Stephan Richter and Albertas Agejevas 301 for the contribution. 302 303 - The ``--contexts`` option is available on the ``report`` and ``html`` 304 commands. It's a comma-separated list of shell-style wildcards, selecting 305 the contexts to report on. Only contexts matching one of the wildcards 306 will be included in the report. 307 308 - The ``--show-contexts`` option for the ``html`` command adds context 309 information to each covered line. Hovering over the "ctx" marker at the 310 end of the line reveals a list of the contexts that covered the line. 311 312- Database changes: 313 314 - Line numbers are now stored in a much more compact way. For each file and 315 context, a single binary string is stored with a bit per line number. This 316 greatly improves memory use, but makes ad-hoc use difficult. 317 318 - Dynamic contexts with no data are no longer written to the database. 319 320 - SQLite data storage is now faster. There's no longer a reason to keep the 321 JSON data file code, so it has been removed. 322 323- Changes to the :class:`.CoverageData` interface: 324 325 - The new :meth:`.CoverageData.dumps` method serializes the data to a string, 326 and a corresponding :meth:`.CoverageData.loads` method reconstitutes this 327 data. The format of the data string is subject to change at any time, and 328 so should only be used between two installations of the same version of 329 coverage.py. 330 331 - The :meth:`CoverageData constructor<.CoverageData.__init__>` has a new 332 argument, `no_disk` (default: False). Setting it to True prevents writing 333 any data to the disk. This is useful for transient data objects. 334 335- Added the classmethod :meth:`.Coverage.current` to get the latest started 336 Coverage instance. 337 338- Multiprocessing support in Python 3.8 was broken, but is now fixed. Closes 339 `issue 828`_. 340 341- Error handling during reporting has changed slightly. All reporting methods 342 now behave the same. The ``--ignore-errors`` option keeps errors from 343 stopping the reporting, but files that couldn't parse as Python will always 344 be reported as warnings. As with other warnings, you can suppress them with 345 the ``[run] disable_warnings`` configuration setting. 346 347- Coverage.py no longer fails if the user program deletes its current 348 directory. Fixes `issue 806`_. Thanks, Dan Hemberger. 349 350- The scrollbar markers in the HTML report now accurately show the highlighted 351 lines, regardless of what categories of line are highlighted. 352 353- The hack to accommodate ShiningPanda_ looking for an obsolete internal data 354 file has been removed, since ShiningPanda 0.22 fixed it four years ago. 355 356- The deprecated `Reporter.file_reporters` property has been removed. 357 358.. _ShiningPanda: https://wiki.jenkins.io/display/JENKINS/ShiningPanda+Plugin 359.. _issue 806: https://github.com/nedbat/coveragepy/pull/806 360.. _issue 828: https://github.com/nedbat/coveragepy/issues/828 361 362 363.. _changes_50a5: 364 365Version 5.0a5 --- 2019-05-07 366---------------------------- 367 368- Drop support for Python 3.4 369 370- Dynamic contexts can now be set two new ways, both thanks to Justas 371 Sadzevičius. 372 373 - A plugin can implement a ``dynamic_context`` method to check frames for 374 whether a new context should be started. See 375 :ref:`dynamic_context_plugins` for more details. 376 377 - Another tool (such as a test runner) can use the new 378 :meth:`.Coverage.switch_context` method to explicitly change the context. 379 380- The ``dynamic_context = test_function`` setting now works with Python 2 381 old-style classes, though it only reports the method name, not the class it 382 was defined on. Closes `issue 797`_. 383 384- ``fail_under`` values more than 100 are reported as errors. Thanks to Mike 385 Fiedler for closing `issue 746`_. 386 387- The "missing" values in the text output are now sorted by line number, so 388 that missing branches are reported near the other lines they affect. The 389 values used to show all missing lines, and then all missing branches. 390 391- Access to the SQLite database used for data storage is now thread-safe. 392 Thanks, Stephan Richter. This closes `issue 702`_. 393 394- Combining data stored in SQLite is now about twice as fast, fixing `issue 395 761`_. Thanks, Stephan Richter. 396 397- The ``filename`` attribute on :class:`.CoverageData` objects has been made 398 private. You can use the ``data_filename`` method to get the actual file 399 name being used to store data, and the ``base_filename`` method to get the 400 original filename before parallelizing suffixes were added. This is part of 401 fixing `issue 708`_. 402 403- Line numbers in the HTML report now align properly with source lines, even 404 when Chrome's minimum font size is set, fixing `issue 748`_. Thanks Wen Ye. 405 406.. _issue 702: https://github.com/nedbat/coveragepy/issues/702 407.. _issue 708: https://github.com/nedbat/coveragepy/issues/708 408.. _issue 746: https://github.com/nedbat/coveragepy/issues/746 409.. _issue 748: https://github.com/nedbat/coveragepy/issues/748 410.. _issue 761: https://github.com/nedbat/coveragepy/issues/761 411.. _issue 797: https://github.com/nedbat/coveragepy/issues/797 412 413 414.. _changes_50a4: 415 416Version 5.0a4 --- 2018-11-25 417---------------------------- 418 419- You can specify the command line to run your program with the ``[run] 420 command_line`` configuration setting, as requested in `issue 695`_. 421 422- Coverage will create directories as needed for the data file if they don't 423 exist, closing `issue 721`_. 424 425- The ``coverage run`` command has always adjusted the first entry in sys.path, 426 to properly emulate how Python runs your program. Now this adjustment is 427 skipped if sys.path[0] is already different than Python's default. This 428 fixes `issue 715`_. 429 430- Improvements to context support: 431 432 - The "no such table: meta" error is fixed.: `issue 716`_. 433 434 - Combining data files is now much faster. 435 436- Python 3.8 (as of today!) passes all tests. 437 438.. _issue 695: https://github.com/nedbat/coveragepy/issues/695 439.. _issue 715: https://github.com/nedbat/coveragepy/issues/715 440.. _issue 716: https://github.com/nedbat/coveragepy/issues/716 441.. _issue 721: https://github.com/nedbat/coveragepy/issues/721 442 443 444.. _changes_50a3: 445 446Version 5.0a3 --- 2018-10-06 447---------------------------- 448 449- Context support: static contexts let you specify a label for a coverage run, 450 which is recorded in the data, and retained when you combine files. See 451 :ref:`contexts` for more information. 452 453- Dynamic contexts: specifying ``[run] dynamic_context = test_function`` in the 454 config file will record the test function name as a dynamic context during 455 execution. This is the core of "Who Tests What" (`issue 170`_). Things to 456 note: 457 458 - There is no reporting support yet. Use SQLite to query the .coverage file 459 for information. Ideas are welcome about how reporting could be extended 460 to use this data. 461 462 - There's a noticeable slow-down before any test is run. 463 464 - Data files will now be roughly N times larger, where N is the number of 465 tests you have. Combining data files is therefore also N times slower. 466 467 - No other values for ``dynamic_context`` are recognized yet. Let me know 468 what else would be useful. I'd like to use a pytest plugin to get better 469 information directly from pytest, for example. 470 471.. _issue 170: https://github.com/nedbat/coveragepy/issues/170 472 473- Environment variable substitution in configuration files now supports two 474 syntaxes for controlling the behavior of undefined variables: if ``VARNAME`` 475 is not defined, ``${VARNAME?}`` will raise an error, and ``${VARNAME-default 476 value}`` will use "default value". 477 478- Partial support for Python 3.8, which has not yet released an alpha. Fixes 479 `issue 707`_ and `issue 714`_. 480 481.. _issue 707: https://github.com/nedbat/coveragepy/issues/707 482.. _issue 714: https://github.com/nedbat/coveragepy/issues/714 483 484 485.. _changes_50a2: 486 487Version 5.0a2 --- 2018-09-03 488---------------------------- 489 490- Coverage's data storage has changed. In version 4.x, .coverage files were 491 basically JSON. Now, they are SQLite databases. This means the data file 492 can be created earlier than it used to. A large amount of code was 493 refactored to support this change. 494 495 - Because the data file is created differently than previous releases, you 496 may need ``parallel=true`` where you didn't before. 497 498 - The old data format is still available (for now) by setting the environment 499 variable COVERAGE_STORAGE=json. Please tell me if you think you need to 500 keep the JSON format. 501 502 - The database schema is guaranteed to change in the future, to support new 503 features. I'm looking for opinions about making the schema part of the 504 public API to coverage.py or not. 505 506- Development moved from `Bitbucket`_ to `GitHub`_. 507 508- HTML files no longer have trailing and extra whitespace. 509 510- The sort order in the HTML report is stored in local storage rather than 511 cookies, closing `issue 611`_. Thanks, Federico Bond. 512 513- pickle2json, for converting v3 data files to v4 data files, has been removed. 514 515.. _Bitbucket: https://bitbucket.org/ned/coveragepy 516.. _GitHub: https://github.com/nedbat/coveragepy 517 518.. _issue 611: https://github.com/nedbat/coveragepy/issues/611 519 520 521.. _changes_50a1: 522 523Version 5.0a1 --- 2018-06-05 524---------------------------- 525 526- Coverage.py no longer supports Python 2.6 or 3.3. 527 528- The location of the configuration file can now be specified with a 529 ``COVERAGE_RCFILE`` environment variable, as requested in `issue 650`_. 530 531- Namespace packages are supported on Python 3.7, where they used to cause 532 TypeErrors about path being None. Fixes `issue 700`_. 533 534- A new warning (``already-imported``) is issued if measurable files have 535 already been imported before coverage.py started measurement. See 536 :ref:`cmd_warnings` for more information. 537 538- Running coverage many times for small runs in a single process should be 539 faster, closing `issue 625`_. Thanks, David MacIver. 540 541- Large HTML report pages load faster. Thanks, Pankaj Pandey. 542 543.. _issue 625: https://bitbucket.org/ned/coveragepy/issues/625/lstat-dominates-in-the-case-of-small 544.. _issue 650: https://bitbucket.org/ned/coveragepy/issues/650/allow-setting-configuration-file-location 545.. _issue 700: https://github.com/nedbat/coveragepy/issues/700 546 547 548.. _changes_454: 549 550Version 4.5.4 --- 2019-07-29 551---------------------------- 552 553- Multiprocessing support in Python 3.8 was broken, but is now fixed. Closes 554 `issue 828`_. 555 556.. _issue 828: https://github.com/nedbat/coveragepy/issues/828 557 558 559.. _changes_453: 560 561Version 4.5.3 --- 2019-03-09 562---------------------------- 563 564- Only packaging metadata changes. 565 566 567.. _changes_452: 568 569Version 4.5.2 --- 2018-11-12 570---------------------------- 571 572- Namespace packages are supported on Python 3.7, where they used to cause 573 TypeErrors about path being None. Fixes `issue 700`_. 574 575- Python 3.8 (as of today!) passes all tests. Fixes `issue 707`_ and 576 `issue 714`_. 577 578- Development moved from `Bitbucket`_ to `GitHub`_. 579 580.. _issue 700: https://github.com/nedbat/coveragepy/issues/700 581.. _issue 707: https://github.com/nedbat/coveragepy/issues/707 582.. _issue 714: https://github.com/nedbat/coveragepy/issues/714 583 584.. _Bitbucket: https://bitbucket.org/ned/coveragepy 585.. _GitHub: https://github.com/nedbat/coveragepy 586 587 588.. _changes_451: 589 590Version 4.5.1 --- 2018-02-10 591---------------------------- 592 593- Now that 4.5 properly separated the ``[run] omit`` and ``[report] omit`` 594 settings, an old bug has become apparent. If you specified a package name 595 for ``[run] source``, then omit patterns weren't matched inside that package. 596 This bug (`issue 638`_) is now fixed. 597 598- On Python 3.7, reporting about a decorated function with no body other than a 599 docstring would crash coverage.py with an IndexError (`issue 640`_). This is 600 now fixed. 601 602- Configurer plugins are now reported in the output of ``--debug=sys``. 603 604.. _issue 638: https://bitbucket.org/ned/coveragepy/issues/638/run-omit-is-ignored-since-45 605.. _issue 640: https://bitbucket.org/ned/coveragepy/issues/640/indexerror-reporting-on-an-empty-decorated 606 607 608.. _changes_45: 609 610Version 4.5 --- 2018-02-03 611-------------------------- 612 613- A new kind of plugin is supported: configurers are invoked at start-up to 614 allow more complex configuration than the .coveragerc file can easily do. 615 See :ref:`api_plugin` for details. This solves the complex configuration 616 problem described in `issue 563`_. 617 618- The ``fail_under`` option can now be a float. Note that you must specify the 619 ``[report] precision`` configuration option for the fractional part to be 620 used. Thanks to Lars Hupfeldt Nielsen for help with the implementation. 621 Fixes `issue 631`_. 622 623- The ``include`` and ``omit`` options can be specified for both the ``[run]`` 624 and ``[report]`` phases of execution. 4.4.2 introduced some incorrect 625 interactions between those phases, where the options for one were confused 626 for the other. This is now corrected, fixing `issue 621`_ and `issue 622`_. 627 Thanks to Daniel Hahler for seeing more clearly than I could. 628 629- The ``coverage combine`` command used to always overwrite the data file, even 630 when no data had been read from apparently combinable files. Now, an error 631 is raised if we thought there were files to combine, but in fact none of them 632 could be used. Fixes `issue 629`_. 633 634- The ``coverage combine`` command could get confused about path separators 635 when combining data collected on Windows with data collected on Linux, as 636 described in `issue 618`_. This is now fixed: the result path always uses 637 the path separator specified in the ``[paths]`` result. 638 639- On Windows, the HTML report could fail when source trees are deeply nested, 640 due to attempting to create HTML filenames longer than the 250-character 641 maximum. Now filenames will never get much larger than 200 characters, 642 fixing `issue 627`_. Thanks to Alex Sandro for helping with the fix. 643 644.. _issue 563: https://bitbucket.org/ned/coveragepy/issues/563/platform-specific-configuration 645.. _issue 618: https://bitbucket.org/ned/coveragepy/issues/618/problem-when-combining-windows-generated 646.. _issue 621: https://bitbucket.org/ned/coveragepy/issues/621/include-ignored-warning-when-using 647.. _issue 622: https://bitbucket.org/ned/coveragepy/issues/622/report-omit-overwrites-run-omit 648.. _issue 627: https://bitbucket.org/ned/coveragepy/issues/627/failure-generating-html-reports-when-the 649.. _issue 629: https://bitbucket.org/ned/coveragepy/issues/629/multiple-use-of-combine-leads-to-empty 650.. _issue 631: https://bitbucket.org/ned/coveragepy/issues/631/precise-coverage-percentage-value 651 652 653.. _changes_442: 654 655Version 4.4.2 --- 2017-11-05 656---------------------------- 657 658- Support for Python 3.7. In some cases, class and module docstrings are no 659 longer counted in statement totals, which could slightly change your total 660 results. 661 662- Specifying both ``--source`` and ``--include`` no longer silently ignores the 663 include setting, instead it displays a warning. Thanks, Loïc Dachary. Closes 664 `issue 265`_ and `issue 101`_. 665 666- Fixed a race condition when saving data and multiple threads are tracing 667 (`issue 581`_). It could produce a "dictionary changed size during iteration" 668 RuntimeError. I believe this mostly but not entirely fixes the race 669 condition. A true fix would likely be too expensive. Thanks, Peter Baughman 670 for the debugging, and Olivier Grisel for the fix with tests. 671 672- Configuration values which are file paths will now apply tilde-expansion, 673 closing `issue 589`_. 674 675- Now secondary config files like tox.ini and setup.cfg can be specified 676 explicitly, and prefixed sections like `[coverage:run]` will be read. Fixes 677 `issue 588`_. 678 679- Be more flexible about the command name displayed by help, fixing 680 `issue 600`_. Thanks, Ben Finney. 681 682.. _issue 101: https://bitbucket.org/ned/coveragepy/issues/101/settings-under-report-affect-running 683.. _issue 581: https://bitbucket.org/ned/coveragepy/issues/581/race-condition-when-saving-data-under 684.. _issue 588: https://bitbucket.org/ned/coveragepy/issues/588/using-rcfile-path-to-toxini-uses-run 685.. _issue 589: https://bitbucket.org/ned/coveragepy/issues/589/allow-expansion-in-coveragerc 686.. _issue 600: https://bitbucket.org/ned/coveragepy/issues/600/get-program-name-from-command-line-when 687 688 689.. _changes_441: 690 691Version 4.4.1 --- 2017-05-14 692---------------------------- 693 694- No code changes: just corrected packaging for Python 2.7 Linux wheels. 695 696 697.. _changes_44: 698 699Version 4.4 --- 2017-05-07 700-------------------------- 701 702- Reports could produce the wrong file names for packages, reporting ``pkg.py`` 703 instead of the correct ``pkg/__init__.py``. This is now fixed. Thanks, Dirk 704 Thomas. 705 706- XML reports could produce ``<source>`` and ``<class>`` lines that together 707 didn't specify a valid source file path. This is now fixed. (`issue 526`_) 708 709- Namespace packages are no longer warned as having no code. (`issue 572`_) 710 711- Code that uses ``sys.settrace(sys.gettrace())`` in a file that wasn't being 712 coverage-measured would prevent correct coverage measurement in following 713 code. An example of this was running doctests programmatically. This is now 714 fixed. (`issue 575`_) 715 716- Errors printed by the ``coverage`` command now go to stderr instead of 717 stdout. 718 719- Running ``coverage xml`` in a directory named with non-ASCII characters would 720 fail under Python 2. This is now fixed. (`issue 573`_) 721 722.. _issue 526: https://bitbucket.org/ned/coveragepy/issues/526/generated-xml-invalid-paths-for-cobertura 723.. _issue 572: https://bitbucket.org/ned/coveragepy/issues/572/no-python-source-warning-for-namespace 724.. _issue 573: https://bitbucket.org/ned/coveragepy/issues/573/cant-generate-xml-report-if-some-source 725.. _issue 575: https://bitbucket.org/ned/coveragepy/issues/575/running-doctest-prevents-complete-coverage 726 727 728Version 4.4b1 --- 2017-04-04 729---------------------------- 730 731- Some warnings can now be individually disabled. Warnings that can be 732 disabled have a short name appended. The ``[run] disable_warnings`` setting 733 takes a list of these warning names to disable. Closes both `issue 96`_ and 734 `issue 355`_. 735 736- The XML report now includes attributes from version 4 of the Cobertura XML 737 format, fixing `issue 570`_. 738 739- In previous versions, calling a method that used collected data would prevent 740 further collection. For example, `save()`, `report()`, `html_report()`, and 741 others would all stop collection. An explicit `start()` was needed to get it 742 going again. This is no longer true. Now you can use the collected data and 743 also continue measurement. Both `issue 79`_ and `issue 448`_ described this 744 problem, and have been fixed. 745 746- Plugins can now find unexecuted files if they choose, by implementing the 747 `find_executable_files` method. Thanks, Emil Madsen. 748 749- Minimal IronPython support. You should be able to run IronPython programs 750 under ``coverage run``, though you will still have to do the reporting phase 751 with CPython. 752 753- Coverage.py has long had a special hack to support CPython's need to measure 754 the coverage of the standard library tests. This code was not installed by 755 kitted versions of coverage.py. Now it is. 756 757.. _issue 79: https://bitbucket.org/ned/coveragepy/issues/79/save-prevents-harvesting-on-stop 758.. _issue 96: https://bitbucket.org/ned/coveragepy/issues/96/unhelpful-warnings-produced-when-using 759.. _issue 355: https://bitbucket.org/ned/coveragepy/issues/355/warnings-should-be-suppressable 760.. _issue 448: https://bitbucket.org/ned/coveragepy/issues/448/save-and-html_report-prevent-further 761.. _issue 570: https://bitbucket.org/ned/coveragepy/issues/570/cobertura-coverage-04dtd-support 762 763 764.. _changes_434: 765 766Version 4.3.4 --- 2017-01-17 767---------------------------- 768 769- Fixing 2.6 in version 4.3.3 broke other things, because the too-tricky 770 exception wasn't properly derived from Exception, described in `issue 556`_. 771 A newb mistake; it hasn't been a good few days. 772 773.. _issue 556: https://bitbucket.org/ned/coveragepy/issues/556/43-fails-if-there-are-html-files-in-the 774 775 776.. _changes_433: 777 778Version 4.3.3 --- 2017-01-17 779---------------------------- 780 781- Python 2.6 support was broken due to a testing exception imported for the 782 benefit of the coverage.py test suite. Properly conditionalizing it fixed 783 `issue 554`_ so that Python 2.6 works again. 784 785.. _issue 554: https://bitbucket.org/ned/coveragepy/issues/554/traceback-on-python-26-starting-with-432 786 787 788.. _changes_432: 789 790Version 4.3.2 --- 2017-01-16 791---------------------------- 792 793- Using the ``--skip-covered`` option on an HTML report with 100% coverage 794 would cause a "No data to report" error, as reported in `issue 549`_. This is 795 now fixed; thanks, Loïc Dachary. 796 797- If-statements can be optimized away during compilation, for example, `if 0:` 798 or `if __debug__:`. Coverage.py had problems properly understanding these 799 statements which existed in the source, but not in the compiled bytecode. 800 This problem, reported in `issue 522`_, is now fixed. 801 802- If you specified ``--source`` as a directory, then coverage.py would look for 803 importable Python files in that directory, and could identify ones that had 804 never been executed at all. But if you specified it as a package name, that 805 detection wasn't performed. Now it is, closing `issue 426`_. Thanks to Loïc 806 Dachary for the fix. 807 808- If you started and stopped coverage measurement thousands of times in your 809 process, you could crash Python with a "Fatal Python error: deallocating 810 None" error. This is now fixed. Thanks to Alex Groce for the bug report. 811 812- On PyPy, measuring coverage in subprocesses could produce a warning: "Trace 813 function changed, measurement is likely wrong: None". This was spurious, and 814 has been suppressed. 815 816- Previously, coverage.py couldn't start on Jython, due to that implementation 817 missing the multiprocessing module (`issue 551`_). This problem has now been 818 fixed. Also, `issue 322`_ about not being able to invoke coverage 819 conveniently, seems much better: ``jython -m coverage run myprog.py`` works 820 properly. 821 822- Let's say you ran the HTML report over and over again in the same output 823 directory, with ``--skip-covered``. And imagine due to your heroic 824 test-writing efforts, a file just achieved the goal of 100% coverage. With 825 coverage.py 4.3, the old HTML file with the less-than-100% coverage would be 826 left behind. This file is now properly deleted. 827 828.. _issue 322: https://bitbucket.org/ned/coveragepy/issues/322/cannot-use-coverage-with-jython 829.. _issue 426: https://bitbucket.org/ned/coveragepy/issues/426/difference-between-coverage-results-with 830.. _issue 522: https://bitbucket.org/ned/coveragepy/issues/522/incorrect-branch-reporting 831.. _issue 549: https://bitbucket.org/ned/coveragepy/issues/549/skip-covered-with-100-coverage-throws-a-no 832.. _issue 551: https://bitbucket.org/ned/coveragepy/issues/551/coveragepy-cannot-be-imported-in-jython27 833 834 835.. _changes_431: 836 837Version 4.3.1 --- 2016-12-28 838---------------------------- 839 840- Some environments couldn't install 4.3, as described in `issue 540`_. This is 841 now fixed. 842 843- The check for conflicting ``--source`` and ``--include`` was too simple in a 844 few different ways, breaking a few perfectly reasonable use cases, described 845 in `issue 541`_. The check has been reverted while we re-think the fix for 846 `issue 265`_. 847 848.. _issue 540: https://bitbucket.org/ned/coveragepy/issues/540/cant-install-coverage-v43-into-under 849.. _issue 541: https://bitbucket.org/ned/coveragepy/issues/541/coverage-43-breaks-nosetest-with-coverage 850 851 852.. _changes_43: 853 854Version 4.3 --- 2016-12-27 855-------------------------- 856 857Special thanks to **Loïc Dachary**, who took an extraordinary interest in 858coverage.py and contributed a number of improvements in this release. 859 860- Subprocesses that are measured with `automatic subprocess measurement`_ used 861 to read in any pre-existing data file. This meant data would be incorrectly 862 carried forward from run to run. Now those files are not read, so each 863 subprocess only writes its own data. Fixes `issue 510`_. 864 865- The ``coverage combine`` command will now fail if there are no data files to 866 combine. The combine changes in 4.2 meant that multiple combines could lose 867 data, leaving you with an empty .coverage data file. Fixes 868 `issue 525`_, `issue 412`_, `issue 516`_, and probably `issue 511`_. 869 870- Coverage.py wouldn't execute `sys.excepthook`_ when an exception happened in 871 your program. Now it does, thanks to Andrew Hoos. Closes `issue 535`_. 872 873- Branch coverage fixes: 874 875 - Branch coverage could misunderstand a finally clause on a try block that 876 never continued on to the following statement, as described in `issue 877 493`_. This is now fixed. Thanks to Joe Doherty for the report and Loïc 878 Dachary for the fix. 879 880 - A while loop with a constant condition (while True) and a continue 881 statement would be mis-analyzed, as described in `issue 496`_. This is now 882 fixed, thanks to a bug report by Eli Skeggs and a fix by Loïc Dachary. 883 884 - While loops with constant conditions that were never executed could result 885 in a non-zero coverage report. Artem Dayneko reported this in `issue 886 502`_, and Loïc Dachary provided the fix. 887 888- The HTML report now supports a ``--skip-covered`` option like the other 889 reporting commands. Thanks, Loïc Dachary for the implementation, closing 890 `issue 433`_. 891 892- Options can now be read from a tox.ini file, if any. Like setup.cfg, sections 893 are prefixed with "coverage:", so ``[run]`` options will be read from the 894 ``[coverage:run]`` section of tox.ini. Implements part of `issue 519`_. 895 Thanks, Stephen Finucane. 896 897- Specifying both ``--source`` and ``--include`` no longer silently ignores the 898 include setting, instead it fails with a message. Thanks, Nathan Land and 899 Loïc Dachary. Closes `issue 265`_. 900 901- The ``Coverage.combine`` method has a new parameter, ``strict=False``, to 902 support failing if there are no data files to combine. 903 904- When forking subprocesses, the coverage data files would have the same random 905 number appended to the file name. This didn't cause problems, because the 906 file names had the process id also, making collisions (nearly) impossible. 907 But it was disconcerting. This is now fixed. 908 909- The text report now properly sizes headers when skipping some files, fixing 910 `issue 524`_. Thanks, Anthony Sottile and Loïc Dachary. 911 912- Coverage.py can now search .pex files for source, just as it can .zip and 913 .egg. Thanks, Peter Ebden. 914 915- Data files are now about 15% smaller. 916 917- Improvements in the ``[run] debug`` setting: 918 919 - The "dataio" debug setting now also logs when data files are deleted during 920 combining or erasing. 921 922 - A new debug option, "multiproc", for logging the behavior of 923 ``concurrency=multiprocessing``. 924 925 - If you used the debug options "config" and "callers" together, you'd get a 926 call stack printed for every line in the multi-line config output. This is 927 now fixed. 928 929- Fixed an unusual bug involving multiple coding declarations affecting code 930 containing code in multi-line strings: `issue 529`_. 931 932- Coverage.py will no longer be misled into thinking that a plain file is a 933 package when interpreting ``--source`` options. Thanks, Cosimo Lupo. 934 935- If you try to run a non-Python file with coverage.py, you will now get a more 936 useful error message. `Issue 514`_. 937 938- The default pragma regex changed slightly, but this will only matter to you 939 if you are deranged and use mixed-case pragmas. 940 941- Deal properly with non-ASCII file names in an ASCII-only world, `issue 533`_. 942 943- Programs that set Unicode configuration values could cause UnicodeErrors when 944 generating HTML reports. Pytest-cov is one example. This is now fixed. 945 946- Prevented deprecation warnings from configparser that happened in some 947 circumstances, closing `issue 530`_. 948 949- Corrected the name of the jquery.ba-throttle-debounce.js library. Thanks, 950 Ben Finney. Closes `issue 505`_. 951 952- Testing against PyPy 5.6 and PyPy3 5.5. 953 954- Switched to pytest from nose for running the coverage.py tests. 955 956- Renamed AUTHORS.txt to CONTRIBUTORS.txt, since there are other ways to 957 contribute than by writing code. Also put the count of contributors into the 958 author string in setup.py, though this might be too cute. 959 960.. _sys.excepthook: https://docs.python.org/3/library/sys.html#sys.excepthook 961.. _issue 265: https://bitbucket.org/ned/coveragepy/issues/265/when-using-source-include-is-silently 962.. _issue 412: https://bitbucket.org/ned/coveragepy/issues/412/coverage-combine-should-error-if-no 963.. _issue 433: https://bitbucket.org/ned/coveragepy/issues/433/coverage-html-does-not-suport-skip-covered 964.. _issue 493: https://bitbucket.org/ned/coveragepy/issues/493/confusing-branching-failure 965.. _issue 496: https://bitbucket.org/ned/coveragepy/issues/496/incorrect-coverage-with-branching-and 966.. _issue 502: https://bitbucket.org/ned/coveragepy/issues/502/incorrect-coverage-report-with-cover 967.. _issue 505: https://bitbucket.org/ned/coveragepy/issues/505/use-canonical-filename-for-debounce 968.. _issue 514: https://bitbucket.org/ned/coveragepy/issues/514/path-to-problem-file-not-reported-when 969.. _issue 510: https://bitbucket.org/ned/coveragepy/issues/510/erase-still-needed-in-42 970.. _issue 511: https://bitbucket.org/ned/coveragepy/issues/511/version-42-coverage-combine-empties 971.. _issue 516: https://bitbucket.org/ned/coveragepy/issues/516/running-coverage-combine-twice-deletes-all 972.. _issue 519: https://bitbucket.org/ned/coveragepy/issues/519/coverage-run-sections-in-toxini-or-as 973.. _issue 524: https://bitbucket.org/ned/coveragepy/issues/524/coverage-report-with-skip-covered-column 974.. _issue 525: https://bitbucket.org/ned/coveragepy/issues/525/coverage-combine-when-not-in-parallel-mode 975.. _issue 529: https://bitbucket.org/ned/coveragepy/issues/529/encoding-marker-may-only-appear-on-the 976.. _issue 530: https://bitbucket.org/ned/coveragepy/issues/530/deprecationwarning-you-passed-a-bytestring 977.. _issue 533: https://bitbucket.org/ned/coveragepy/issues/533/exception-on-unencodable-file-name 978.. _issue 535: https://bitbucket.org/ned/coveragepy/issues/535/sysexcepthook-is-not-called 979 980 981.. _changes_42: 982 983Version 4.2 --- 2016-07-26 984-------------------------- 985 986- Since ``concurrency=multiprocessing`` uses subprocesses, options specified on 987 the coverage.py command line will not be communicated down to them. Only 988 options in the configuration file will apply to the subprocesses. 989 Previously, the options didn't apply to the subprocesses, but there was no 990 indication. Now it is an error to use ``--concurrency=multiprocessing`` and 991 other run-affecting options on the command line. This prevents 992 failures like those reported in `issue 495`_. 993 994- Filtering the HTML report is now faster, thanks to Ville Skyttä. 995 996.. _issue 495: https://bitbucket.org/ned/coveragepy/issues/495/branch-and-concurrency-are-conflicting 997 998 999Version 4.2b1 --- 2016-07-04 1000---------------------------- 1001 1002Work from the PyCon 2016 Sprints! 1003 1004- BACKWARD INCOMPATIBILITY: the ``coverage combine`` command now ignores an 1005 existing ``.coverage`` data file. It used to include that file in its 1006 combining. This caused confusing results, and extra tox "clean" steps. If 1007 you want the old behavior, use the new ``coverage combine --append`` option. 1008 1009- The ``concurrency`` option can now take multiple values, to support programs 1010 using multiprocessing and another library such as eventlet. This is only 1011 possible in the configuration file, not from the command line. The 1012 configuration file is the only way for sub-processes to all run with the same 1013 options. Fixes `issue 484`_. Thanks to Josh Williams for prototyping. 1014 1015- Using a ``concurrency`` setting of ``multiprocessing`` now implies 1016 ``--parallel`` so that the main program is measured similarly to the 1017 sub-processes. 1018 1019- When using `automatic subprocess measurement`_, running coverage commands 1020 would create spurious data files. This is now fixed, thanks to diagnosis and 1021 testing by Dan Riti. Closes `issue 492`_. 1022 1023- A new configuration option, ``report:sort``, controls what column of the 1024 text report is used to sort the rows. Thanks to Dan Wandschneider, this 1025 closes `issue 199`_. 1026 1027- The HTML report has a more-visible indicator for which column is being 1028 sorted. Closes `issue 298`_, thanks to Josh Williams. 1029 1030- If the HTML report cannot find the source for a file, the message now 1031 suggests using the ``-i`` flag to allow the report to continue. Closes 1032 `issue 231`_, thanks, Nathan Land. 1033 1034- When reports are ignoring errors, there's now a warning if a file cannot be 1035 parsed, rather than being silently ignored. Closes `issue 396`_. Thanks, 1036 Matthew Boehm. 1037 1038- A new option for ``coverage debug`` is available: ``coverage debug config`` 1039 shows the current configuration. Closes `issue 454`_, thanks to Matthew 1040 Boehm. 1041 1042- Running coverage as a module (``python -m coverage``) no longer shows the 1043 program name as ``__main__.py``. Fixes `issue 478`_. Thanks, Scott Belden. 1044 1045- The `test_helpers` module has been moved into a separate pip-installable 1046 package: `unittest-mixins`_. 1047 1048.. _automatic subprocess measurement: https://coverage.readthedocs.io/en/latest/subprocess.html 1049.. _issue 199: https://bitbucket.org/ned/coveragepy/issues/199/add-a-way-to-sort-the-text-report 1050.. _issue 231: https://bitbucket.org/ned/coveragepy/issues/231/various-default-behavior-in-report-phase 1051.. _issue 298: https://bitbucket.org/ned/coveragepy/issues/298/show-in-html-report-that-the-columns-are 1052.. _issue 396: https://bitbucket.org/ned/coveragepy/issues/396/coverage-xml-shouldnt-bail-out-on-parse 1053.. _issue 454: https://bitbucket.org/ned/coveragepy/issues/454/coverage-debug-config-should-be 1054.. _issue 478: https://bitbucket.org/ned/coveragepy/issues/478/help-shows-silly-program-name-when-running 1055.. _issue 484: https://bitbucket.org/ned/coveragepy/issues/484/multiprocessing-greenlet-concurrency 1056.. _issue 492: https://bitbucket.org/ned/coveragepy/issues/492/subprocess-coverage-strange-detection-of 1057.. _unittest-mixins: https://pypi.org/project/unittest-mixins/ 1058 1059 1060.. _changes_41: 1061 1062Version 4.1 --- 2016-05-21 1063-------------------------- 1064 1065- The internal attribute `Reporter.file_reporters` was removed in 4.1b3. It 1066 should have come has no surprise that there were third-party tools out there 1067 using that attribute. It has been restored, but with a deprecation warning. 1068 1069 1070Version 4.1b3 --- 2016-05-10 1071---------------------------- 1072 1073- When running your program, execution can jump from an ``except X:`` line to 1074 some other line when an exception other than ``X`` happens. This jump is no 1075 longer considered a branch when measuring branch coverage. 1076 1077- When measuring branch coverage, ``yield`` statements that were never resumed 1078 were incorrectly marked as missing, as reported in `issue 440`_. This is now 1079 fixed. 1080 1081- During branch coverage of single-line callables like lambdas and generator 1082 expressions, coverage.py can now distinguish between them never being called, 1083 or being called but not completed. Fixes `issue 90`_, `issue 460`_ and 1084 `issue 475`_. 1085 1086- The HTML report now has a map of the file along the rightmost edge of the 1087 page, giving an overview of where the missed lines are. Thanks, Dmitry 1088 Shishov. 1089 1090- The HTML report now uses different monospaced fonts, favoring Consolas over 1091 Courier. Along the way, `issue 472`_ about not properly handling one-space 1092 indents was fixed. The index page also has slightly different styling, to 1093 try to make the clickable detail pages more apparent. 1094 1095- Missing branches reported with ``coverage report -m`` will now say ``->exit`` 1096 for missed branches to the exit of a function, rather than a negative number. 1097 Fixes `issue 469`_. 1098 1099- ``coverage --help`` and ``coverage --version`` now mention which tracer is 1100 installed, to help diagnose problems. The docs mention which features need 1101 the C extension. (`issue 479`_) 1102 1103- Officially support PyPy 5.1, which required no changes, just updates to the 1104 docs. 1105 1106- The `Coverage.report` function had two parameters with non-None defaults, 1107 which have been changed. `show_missing` used to default to True, but now 1108 defaults to None. If you had been calling `Coverage.report` without 1109 specifying `show_missing`, you'll need to explicitly set it to True to keep 1110 the same behavior. `skip_covered` used to default to False. It is now None, 1111 which doesn't change the behavior. This fixes `issue 485`_. 1112 1113- It's never been possible to pass a namespace module to one of the analysis 1114 functions, but now at least we raise a more specific error message, rather 1115 than getting confused. (`issue 456`_) 1116 1117- The `coverage.process_startup` function now returns the `Coverage` instance 1118 it creates, as suggested in `issue 481`_. 1119 1120- Make a small tweak to how we compare threads, to avoid buggy custom 1121 comparison code in thread classes. (`issue 245`_) 1122 1123.. _issue 90: https://bitbucket.org/ned/coveragepy/issues/90/lambda-expression-confuses-branch 1124.. _issue 245: https://bitbucket.org/ned/coveragepy/issues/245/change-solution-for-issue-164 1125.. _issue 440: https://bitbucket.org/ned/coveragepy/issues/440/yielded-twisted-failure-marked-as-missed 1126.. _issue 456: https://bitbucket.org/ned/coveragepy/issues/456/coverage-breaks-with-implicit-namespaces 1127.. _issue 460: https://bitbucket.org/ned/coveragepy/issues/460/confusing-html-report-for-certain-partial 1128.. _issue 469: https://bitbucket.org/ned/coveragepy/issues/469/strange-1-line-number-in-branch-coverage 1129.. _issue 472: https://bitbucket.org/ned/coveragepy/issues/472/html-report-indents-incorrectly-for-one 1130.. _issue 475: https://bitbucket.org/ned/coveragepy/issues/475/generator-expression-is-marked-as-not 1131.. _issue 479: https://bitbucket.org/ned/coveragepy/issues/479/clarify-the-need-for-the-c-extension 1132.. _issue 481: https://bitbucket.org/ned/coveragepy/issues/481/asyncioprocesspoolexecutor-tracing-not 1133.. _issue 485: https://bitbucket.org/ned/coveragepy/issues/485/coveragereport-ignores-show_missing-and 1134 1135 1136Version 4.1b2 --- 2016-01-23 1137---------------------------- 1138 1139- Problems with the new branch measurement in 4.1 beta 1 were fixed: 1140 1141 - Class docstrings were considered executable. Now they no longer are. 1142 1143 - ``yield from`` and ``await`` were considered returns from functions, since 1144 they could transfer control to the caller. This produced unhelpful 1145 "missing branch" reports in a number of circumstances. Now they no longer 1146 are considered returns. 1147 1148 - In unusual situations, a missing branch to a negative number was reported. 1149 This has been fixed, closing `issue 466`_. 1150 1151- The XML report now produces correct package names for modules found in 1152 directories specified with ``source=``. Fixes `issue 465`_. 1153 1154- ``coverage report`` won't produce trailing whitespace. 1155 1156.. _issue 465: https://bitbucket.org/ned/coveragepy/issues/465/coveragexml-produces-package-names-with-an 1157.. _issue 466: https://bitbucket.org/ned/coveragepy/issues/466/impossible-missed-branch-to-a-negative 1158 1159 1160Version 4.1b1 --- 2016-01-10 1161---------------------------- 1162 1163- Branch analysis has been rewritten: it used to be based on bytecode, but now 1164 uses AST analysis. This has changed a number of things: 1165 1166 - More code paths are now considered runnable, especially in 1167 ``try``/``except`` structures. This may mean that coverage.py will 1168 identify more code paths as uncovered. This could either raise or lower 1169 your overall coverage number. 1170 1171 - Python 3.5's ``async`` and ``await`` keywords are properly supported, 1172 fixing `issue 434`_. 1173 1174 - Some long-standing branch coverage bugs were fixed: 1175 1176 - `issue 129`_: functions with only a docstring for a body would 1177 incorrectly report a missing branch on the ``def`` line. 1178 1179 - `issue 212`_: code in an ``except`` block could be incorrectly marked as 1180 a missing branch. 1181 1182 - `issue 146`_: context managers (``with`` statements) in a loop or ``try`` 1183 block could confuse the branch measurement, reporting incorrect partial 1184 branches. 1185 1186 - `issue 422`_: in Python 3.5, an actual partial branch could be marked as 1187 complete. 1188 1189- Pragmas to disable coverage measurement can now be used on decorator lines, 1190 and they will apply to the entire function or class being decorated. This 1191 implements the feature requested in `issue 131`_. 1192 1193- Multiprocessing support is now available on Windows. Thanks, Rodrigue 1194 Cloutier. 1195 1196- Files with two encoding declarations are properly supported, fixing 1197 `issue 453`_. Thanks, Max Linke. 1198 1199- Non-ascii characters in regexes in the configuration file worked in 3.7, but 1200 stopped working in 4.0. Now they work again, closing `issue 455`_. 1201 1202- Form-feed characters would prevent accurate determination of the beginning of 1203 statements in the rest of the file. This is now fixed, closing `issue 461`_. 1204 1205.. _issue 129: https://bitbucket.org/ned/coveragepy/issues/129/misleading-branch-coverage-of-empty 1206.. _issue 131: https://bitbucket.org/ned/coveragepy/issues/131/pragma-on-a-decorator-line-should-affect 1207.. _issue 146: https://bitbucket.org/ned/coveragepy/issues/146/context-managers-confuse-branch-coverage 1208.. _issue 212: https://bitbucket.org/ned/coveragepy/issues/212/coverage-erroneously-reports-partial 1209.. _issue 422: https://bitbucket.org/ned/coveragepy/issues/422/python35-partial-branch-marked-as-fully 1210.. _issue 434: https://bitbucket.org/ned/coveragepy/issues/434/indexerror-in-python-35 1211.. _issue 453: https://bitbucket.org/ned/coveragepy/issues/453/source-code-encoding-can-only-be-specified 1212.. _issue 455: https://bitbucket.org/ned/coveragepy/issues/455/unusual-exclusions-stopped-working-in 1213.. _issue 461: https://bitbucket.org/ned/coveragepy/issues/461/multiline-asserts-need-too-many-pragma 1214 1215 1216.. _changes_403: 1217 1218Version 4.0.3 --- 2015-11-24 1219---------------------------- 1220 1221- Fixed a mysterious problem that manifested in different ways: sometimes 1222 hanging the process (`issue 420`_), sometimes making database connections 1223 fail (`issue 445`_). 1224 1225- The XML report now has correct ``<source>`` elements when using a 1226 ``--source=`` option somewhere besides the current directory. This fixes 1227 `issue 439`_. Thanks, Arcadiy Ivanov. 1228 1229- Fixed an unusual edge case of detecting source encodings, described in 1230 `issue 443`_. 1231 1232- Help messages that mention the command to use now properly use the actual 1233 command name, which might be different than "coverage". Thanks to Ben 1234 Finney, this closes `issue 438`_. 1235 1236.. _issue 420: https://bitbucket.org/ned/coveragepy/issues/420/coverage-40-hangs-indefinitely-on-python27 1237.. _issue 438: https://bitbucket.org/ned/coveragepy/issues/438/parameterise-coverage-command-name 1238.. _issue 439: https://bitbucket.org/ned/coveragepy/issues/439/incorrect-cobertura-file-sources-generated 1239.. _issue 443: https://bitbucket.org/ned/coveragepy/issues/443/coverage-gets-confused-when-encoding 1240.. _issue 445: https://bitbucket.org/ned/coveragepy/issues/445/django-app-cannot-connect-to-cassandra 1241 1242 1243.. _changes_402: 1244 1245Version 4.0.2 --- 2015-11-04 1246---------------------------- 1247 1248- More work on supporting unusually encoded source. Fixed `issue 431`_. 1249 1250- Files or directories with non-ASCII characters are now handled properly, 1251 fixing `issue 432`_. 1252 1253- Setting a trace function with sys.settrace was broken by a change in 4.0.1, 1254 as reported in `issue 436`_. This is now fixed. 1255 1256- Officially support PyPy 4.0, which required no changes, just updates to the 1257 docs. 1258 1259.. _issue 431: https://bitbucket.org/ned/coveragepy/issues/431/couldnt-parse-python-file-with-cp1252 1260.. _issue 432: https://bitbucket.org/ned/coveragepy/issues/432/path-with-unicode-characters-various 1261.. _issue 436: https://bitbucket.org/ned/coveragepy/issues/436/disabled-coverage-ctracer-may-rise-from 1262 1263 1264.. _changes_401: 1265 1266Version 4.0.1 --- 2015-10-13 1267---------------------------- 1268 1269- When combining data files, unreadable files will now generate a warning 1270 instead of failing the command. This is more in line with the older 1271 coverage.py v3.7.1 behavior, which silently ignored unreadable files. 1272 Prompted by `issue 418`_. 1273 1274- The --skip-covered option would skip reporting on 100% covered files, but 1275 also skipped them when calculating total coverage. This was wrong, it should 1276 only remove lines from the report, not change the final answer. This is now 1277 fixed, closing `issue 423`_. 1278 1279- In 4.0, the data file recorded a summary of the system on which it was run. 1280 Combined data files would keep all of those summaries. This could lead to 1281 enormous data files consisting of mostly repetitive useless information. That 1282 summary is now gone, fixing `issue 415`_. If you want summary information, 1283 get in touch, and we'll figure out a better way to do it. 1284 1285- Test suites that mocked os.path.exists would experience strange failures, due 1286 to coverage.py using their mock inadvertently. This is now fixed, closing 1287 `issue 416`_. 1288 1289- Importing a ``__init__`` module explicitly would lead to an error: 1290 ``AttributeError: 'module' object has no attribute '__path__'``, as reported 1291 in `issue 410`_. This is now fixed. 1292 1293- Code that uses ``sys.settrace(sys.gettrace())`` used to incur a more than 2x 1294 speed penalty. Now there's no penalty at all. Fixes `issue 397`_. 1295 1296- Pyexpat C code will no longer be recorded as a source file, fixing 1297 `issue 419`_. 1298 1299- The source kit now contains all of the files needed to have a complete source 1300 tree, re-fixing `issue 137`_ and closing `issue 281`_. 1301 1302.. _issue 281: https://bitbucket.org/ned/coveragepy/issues/281/supply-scripts-for-testing-in-the 1303.. _issue 397: https://bitbucket.org/ned/coveragepy/issues/397/stopping-and-resuming-coverage-with 1304.. _issue 410: https://bitbucket.org/ned/coveragepy/issues/410/attributeerror-module-object-has-no 1305.. _issue 415: https://bitbucket.org/ned/coveragepy/issues/415/repeated-coveragedataupdates-cause 1306.. _issue 416: https://bitbucket.org/ned/coveragepy/issues/416/mocking-ospathexists-causes-failures 1307.. _issue 418: https://bitbucket.org/ned/coveragepy/issues/418/json-parse-error 1308.. _issue 419: https://bitbucket.org/ned/coveragepy/issues/419/nosource-no-source-for-code-path-to-c 1309.. _issue 423: https://bitbucket.org/ned/coveragepy/issues/423/skip_covered-changes-reported-total 1310 1311 1312.. _changes_40: 1313 1314Version 4.0 --- 2015-09-20 1315-------------------------- 1316 1317No changes from 4.0b3 1318 1319 1320Version 4.0b3 --- 2015-09-07 1321---------------------------- 1322 1323- Reporting on an unmeasured file would fail with a traceback. This is now 1324 fixed, closing `issue 403`_. 1325 1326- The Jenkins ShiningPanda_ plugin looks for an obsolete file name to find the 1327 HTML reports to publish, so it was failing under coverage.py 4.0. Now we 1328 create that file if we are running under Jenkins, to keep things working 1329 smoothly. `issue 404`_. 1330 1331- Kits used to include tests and docs, but didn't install them anywhere, or 1332 provide all of the supporting tools to make them useful. Kits no longer 1333 include tests and docs. If you were using them from the older packages, get 1334 in touch and help me understand how. 1335 1336.. _issue 403: https://bitbucket.org/ned/coveragepy/issues/403/hasherupdate-fails-with-typeerror-nonetype 1337.. _issue 404: https://bitbucket.org/ned/coveragepy/issues/404/shiningpanda-jenkins-plugin-cant-find-html 1338 1339 1340Version 4.0b2 --- 2015-08-22 1341---------------------------- 1342 1343- 4.0b1 broke ``--append`` creating new data files. This is now fixed, closing 1344 `issue 392`_. 1345 1346- ``py.test --cov`` can write empty data, then touch files due to ``--source``, 1347 which made coverage.py mistakenly force the data file to record lines instead 1348 of arcs. This would lead to a "Can't combine line data with arc data" error 1349 message. This is now fixed, and changed some method names in the 1350 CoverageData interface. Fixes `issue 399`_. 1351 1352- `CoverageData.read_fileobj` and `CoverageData.write_fileobj` replace the 1353 `.read` and `.write` methods, and are now properly inverses of each other. 1354 1355- When using ``report --skip-covered``, a message will now be included in the 1356 report output indicating how many files were skipped, and if all files are 1357 skipped, coverage.py won't accidentally scold you for having no data to 1358 report. Thanks, Krystian Kichewko. 1359 1360- A new conversion utility has been added: ``python -m coverage.pickle2json`` 1361 will convert v3.x pickle data files to v4.x JSON data files. Thanks, 1362 Alexander Todorov. Closes `issue 395`_. 1363 1364- A new version identifier is available, `coverage.version_info`, a plain tuple 1365 of values similar to `sys.version_info`_. 1366 1367.. _issue 392: https://bitbucket.org/ned/coveragepy/issues/392/run-append-doesnt-create-coverage-file 1368.. _issue 395: https://bitbucket.org/ned/coveragepy/issues/395/rfe-read-pickled-files-as-well-for 1369.. _issue 399: https://bitbucket.org/ned/coveragepy/issues/399/coverageexception-cant-combine-line-data 1370.. _sys.version_info: https://docs.python.org/3/library/sys.html#sys.version_info 1371 1372 1373Version 4.0b1 --- 2015-08-02 1374---------------------------- 1375 1376- Coverage.py is now licensed under the Apache 2.0 license. See NOTICE.txt for 1377 details. Closes `issue 313`_. 1378 1379- The data storage has been completely revamped. The data file is now 1380 JSON-based instead of a pickle, closing `issue 236`_. The `CoverageData` 1381 class is now a public supported documented API to the data file. 1382 1383- A new configuration option, ``[run] note``, lets you set a note that will be 1384 stored in the `runs` section of the data file. You can use this to annotate 1385 the data file with any information you like. 1386 1387- Unrecognized configuration options will now print an error message and stop 1388 coverage.py. This should help prevent configuration mistakes from passing 1389 silently. Finishes `issue 386`_. 1390 1391- In parallel mode, ``coverage erase`` will now delete all of the data files, 1392 fixing `issue 262`_. 1393 1394- Coverage.py now accepts a directory name for ``coverage run`` and will run a 1395 ``__main__.py`` found there, just like Python will. Fixes `issue 252`_. 1396 Thanks, Dmitry Trofimov. 1397 1398- The XML report now includes a ``missing-branches`` attribute. Thanks, Steve 1399 Peak. This is not a part of the Cobertura DTD, so the XML report no longer 1400 references the DTD. 1401 1402- Missing branches in the HTML report now have a bit more information in the 1403 right-hand annotations. Hopefully this will make their meaning clearer. 1404 1405- All the reporting functions now behave the same if no data had been 1406 collected, exiting with a status code of 1. Fixed ``fail_under`` to be 1407 applied even when the report is empty. Thanks, Ionel Cristian Mărieș. 1408 1409- Plugins are now initialized differently. Instead of looking for a class 1410 called ``Plugin``, coverage.py looks for a function called ``coverage_init``. 1411 1412- A file-tracing plugin can now ask to have built-in Python reporting by 1413 returning `"python"` from its `file_reporter()` method. 1414 1415- Code that was executed with `exec` would be mis-attributed to the file that 1416 called it. This is now fixed, closing `issue 380`_. 1417 1418- The ability to use item access on `Coverage.config` (introduced in 4.0a2) has 1419 been changed to a more explicit `Coverage.get_option` and 1420 `Coverage.set_option` API. 1421 1422- The ``Coverage.use_cache`` method is no longer supported. 1423 1424- The private method ``Coverage._harvest_data`` is now called 1425 ``Coverage.get_data``, and returns the ``CoverageData`` containing the 1426 collected data. 1427 1428- The project is consistently referred to as "coverage.py" throughout the code 1429 and the documentation, closing `issue 275`_. 1430 1431- Combining data files with an explicit configuration file was broken in 4.0a6, 1432 but now works again, closing `issue 385`_. 1433 1434- ``coverage combine`` now accepts files as well as directories. 1435 1436- The speed is back to 3.7.1 levels, after having slowed down due to plugin 1437 support, finishing up `issue 387`_. 1438 1439.. _issue 236: https://bitbucket.org/ned/coveragepy/issues/236/pickles-are-bad-and-you-should-feel-bad 1440.. _issue 252: https://bitbucket.org/ned/coveragepy/issues/252/coverage-wont-run-a-program-with 1441.. _issue 262: https://bitbucket.org/ned/coveragepy/issues/262/when-parallel-true-erase-should-erase-all 1442.. _issue 275: https://bitbucket.org/ned/coveragepy/issues/275/refer-consistently-to-project-as-coverage 1443.. _issue 313: https://bitbucket.org/ned/coveragepy/issues/313/add-license-file-containing-2-3-or-4 1444.. _issue 380: https://bitbucket.org/ned/coveragepy/issues/380/code-executed-by-exec-excluded-from 1445.. _issue 385: https://bitbucket.org/ned/coveragepy/issues/385/coverage-combine-doesnt-work-with-rcfile 1446.. _issue 386: https://bitbucket.org/ned/coveragepy/issues/386/error-on-unrecognised-configuration 1447.. _issue 387: https://bitbucket.org/ned/coveragepy/issues/387/performance-degradation-from-371-to-40 1448 1449.. 40 issues closed in 4.0 below here 1450 1451 1452Version 4.0a6 --- 2015-06-21 1453---------------------------- 1454 1455- Python 3.5b2 and PyPy 2.6.0 are supported. 1456 1457- The original module-level function interface to coverage.py is no longer 1458 supported. You must now create a ``coverage.Coverage`` object, and use 1459 methods on it. 1460 1461- The ``coverage combine`` command now accepts any number of directories as 1462 arguments, and will combine all the data files from those directories. This 1463 means you don't have to copy the files to one directory before combining. 1464 Thanks, Christine Lytwynec. Finishes `issue 354`_. 1465 1466- Branch coverage couldn't properly handle certain extremely long files. This 1467 is now fixed (`issue 359`_). 1468 1469- Branch coverage didn't understand yield statements properly. Mickie Betz 1470 persisted in pursuing this despite Ned's pessimism. Fixes `issue 308`_ and 1471 `issue 324`_. 1472 1473- The COVERAGE_DEBUG environment variable can be used to set the 1474 ``[run] debug`` configuration option to control what internal operations are 1475 logged. 1476 1477- HTML reports were truncated at formfeed characters. This is now fixed 1478 (`issue 360`_). It's always fun when the problem is due to a `bug in the 1479 Python standard library <http://bugs.python.org/issue19035>`_. 1480 1481- Files with incorrect encoding declaration comments are no longer ignored by 1482 the reporting commands, fixing `issue 351`_. 1483 1484- HTML reports now include a timestamp in the footer, closing `issue 299`_. 1485 Thanks, Conrad Ho. 1486 1487- HTML reports now begrudgingly use double-quotes rather than single quotes, 1488 because there are "software engineers" out there writing tools that read HTML 1489 and somehow have no idea that single quotes exist. Capitulates to the absurd 1490 `issue 361`_. Thanks, Jon Chappell. 1491 1492- The ``coverage annotate`` command now handles non-ASCII characters properly, 1493 closing `issue 363`_. Thanks, Leonardo Pistone. 1494 1495- Drive letters on Windows were not normalized correctly, now they are. Thanks, 1496 Ionel Cristian Mărieș. 1497 1498- Plugin support had some bugs fixed, closing `issue 374`_ and `issue 375`_. 1499 Thanks, Stefan Behnel. 1500 1501.. _issue 299: https://bitbucket.org/ned/coveragepy/issues/299/inserted-created-on-yyyy-mm-dd-hh-mm-in 1502.. _issue 308: https://bitbucket.org/ned/coveragepy/issues/308/yield-lambda-branch-coverage 1503.. _issue 324: https://bitbucket.org/ned/coveragepy/issues/324/yield-in-loop-confuses-branch-coverage 1504.. _issue 351: https://bitbucket.org/ned/coveragepy/issues/351/files-with-incorrect-encoding-are-ignored 1505.. _issue 354: https://bitbucket.org/ned/coveragepy/issues/354/coverage-combine-should-take-a-list-of 1506.. _issue 359: https://bitbucket.org/ned/coveragepy/issues/359/xml-report-chunk-error 1507.. _issue 360: https://bitbucket.org/ned/coveragepy/issues/360/html-reports-get-confused-by-l-in-the-code 1508.. _issue 361: https://bitbucket.org/ned/coveragepy/issues/361/use-double-quotes-in-html-output-to 1509.. _issue 363: https://bitbucket.org/ned/coveragepy/issues/363/annotate-command-hits-unicode-happy-fun 1510.. _issue 374: https://bitbucket.org/ned/coveragepy/issues/374/c-tracer-lookups-fail-in 1511.. _issue 375: https://bitbucket.org/ned/coveragepy/issues/375/ctracer_handle_return-reads-byte-code 1512 1513 1514Version 4.0a5 --- 2015-02-16 1515---------------------------- 1516 1517- Plugin support is now implemented in the C tracer instead of the Python 1518 tracer. This greatly improves the speed of tracing projects using plugins. 1519 1520- Coverage.py now always adds the current directory to sys.path, so that 1521 plugins can import files in the current directory (`issue 358`_). 1522 1523- If the `config_file` argument to the Coverage constructor is specified as 1524 ".coveragerc", it is treated as if it were True. This means setup.cfg is 1525 also examined, and a missing file is not considered an error (`issue 357`_). 1526 1527- Wildly experimental: support for measuring processes started by the 1528 multiprocessing module. To use, set ``--concurrency=multiprocessing``, 1529 either on the command line or in the .coveragerc file (`issue 117`_). Thanks, 1530 Eduardo Schettino. Currently, this does not work on Windows. 1531 1532- A new warning is possible, if a desired file isn't measured because it was 1533 imported before coverage.py was started (`issue 353`_). 1534 1535- The `coverage.process_startup` function now will start coverage measurement 1536 only once, no matter how many times it is called. This fixes problems due 1537 to unusual virtualenv configurations (`issue 340`_). 1538 1539- Added 3.5.0a1 to the list of supported CPython versions. 1540 1541.. _issue 117: https://bitbucket.org/ned/coveragepy/issues/117/enable-coverage-measurement-of-code-run-by 1542.. _issue 340: https://bitbucket.org/ned/coveragepy/issues/340/keyerror-subpy 1543.. _issue 353: https://bitbucket.org/ned/coveragepy/issues/353/40a3-introduces-an-unexpected-third-case 1544.. _issue 357: https://bitbucket.org/ned/coveragepy/issues/357/behavior-changed-when-coveragerc-is 1545.. _issue 358: https://bitbucket.org/ned/coveragepy/issues/358/all-coverage-commands-should-adjust 1546 1547 1548Version 4.0a4 --- 2015-01-25 1549---------------------------- 1550 1551- Plugins can now provide sys_info for debugging output. 1552 1553- Started plugins documentation. 1554 1555- Prepared to move the docs to readthedocs.org. 1556 1557 1558Version 4.0a3 --- 2015-01-20 1559---------------------------- 1560 1561- Reports now use file names with extensions. Previously, a report would 1562 describe a/b/c.py as "a/b/c". Now it is shown as "a/b/c.py". This allows 1563 for better support of non-Python files, and also fixed `issue 69`_. 1564 1565- The XML report now reports each directory as a package again. This was a bad 1566 regression, I apologize. This was reported in `issue 235`_, which is now 1567 fixed. 1568 1569- A new configuration option for the XML report: ``[xml] package_depth`` 1570 controls which directories are identified as packages in the report. 1571 Directories deeper than this depth are not reported as packages. 1572 The default is that all directories are reported as packages. 1573 Thanks, Lex Berezhny. 1574 1575- When looking for the source for a frame, check if the file exists. On 1576 Windows, .pyw files are no longer recorded as .py files. Along the way, this 1577 fixed `issue 290`_. 1578 1579- Empty files are now reported as 100% covered in the XML report, not 0% 1580 covered (`issue 345`_). 1581 1582- Regexes in the configuration file are now compiled as soon as they are read, 1583 to provide error messages earlier (`issue 349`_). 1584 1585.. _issue 69: https://bitbucket.org/ned/coveragepy/issues/69/coverage-html-overwrite-files-that-doesnt 1586.. _issue 235: https://bitbucket.org/ned/coveragepy/issues/235/package-name-is-missing-in-xml-report 1587.. _issue 290: https://bitbucket.org/ned/coveragepy/issues/290/running-programmatically-with-pyw-files 1588.. _issue 345: https://bitbucket.org/ned/coveragepy/issues/345/xml-reports-line-rate-0-for-empty-files 1589.. _issue 349: https://bitbucket.org/ned/coveragepy/issues/349/bad-regex-in-config-should-get-an-earlier 1590 1591 1592Version 4.0a2 --- 2015-01-14 1593---------------------------- 1594 1595- Officially support PyPy 2.4, and PyPy3 2.4. Drop support for 1596 CPython 3.2 and older versions of PyPy. The code won't work on CPython 3.2. 1597 It will probably still work on older versions of PyPy, but I'm not testing 1598 against them. 1599 1600- Plugins! 1601 1602- The original command line switches (`-x` to run a program, etc) are no 1603 longer supported. 1604 1605- A new option: `coverage report --skip-covered` will reduce the number of 1606 files reported by skipping files with 100% coverage. Thanks, Krystian 1607 Kichewko. This means that empty `__init__.py` files will be skipped, since 1608 they are 100% covered, closing `issue 315`_. 1609 1610- You can now specify the ``--fail-under`` option in the ``.coveragerc`` file 1611 as the ``[report] fail_under`` option. This closes `issue 314`_. 1612 1613- The ``COVERAGE_OPTIONS`` environment variable is no longer supported. It was 1614 a hack for ``--timid`` before configuration files were available. 1615 1616- The HTML report now has filtering. Type text into the Filter box on the 1617 index page, and only modules with that text in the name will be shown. 1618 Thanks, Danny Allen. 1619 1620- The textual report and the HTML report used to report partial branches 1621 differently for no good reason. Now the text report's "missing branches" 1622 column is a "partial branches" column so that both reports show the same 1623 numbers. This closes `issue 342`_. 1624 1625- If you specify a ``--rcfile`` that cannot be read, you will get an error 1626 message. Fixes `issue 343`_. 1627 1628- The ``--debug`` switch can now be used on any command. 1629 1630- You can now programmatically adjust the configuration of coverage.py by 1631 setting items on `Coverage.config` after construction. 1632 1633- A module run with ``-m`` can be used as the argument to ``--source``, fixing 1634 `issue 328`_. Thanks, Buck Evan. 1635 1636- The regex for matching exclusion pragmas has been fixed to allow more kinds 1637 of whitespace, fixing `issue 334`_. 1638 1639- Made some PyPy-specific tweaks to improve speed under PyPy. Thanks, Alex 1640 Gaynor. 1641 1642- In some cases, with a source file missing a final newline, coverage.py would 1643 count statements incorrectly. This is now fixed, closing `issue 293`_. 1644 1645- The status.dat file that HTML reports use to avoid re-creating files that 1646 haven't changed is now a JSON file instead of a pickle file. This obviates 1647 `issue 287`_ and `issue 237`_. 1648 1649.. _issue 237: https://bitbucket.org/ned/coveragepy/issues/237/htmlcov-with-corrupt-statusdat 1650.. _issue 287: https://bitbucket.org/ned/coveragepy/issues/287/htmlpy-doesnt-specify-pickle-protocol 1651.. _issue 293: https://bitbucket.org/ned/coveragepy/issues/293/number-of-statement-detection-wrong-if-no 1652.. _issue 314: https://bitbucket.org/ned/coveragepy/issues/314/fail_under-param-not-working-in-coveragerc 1653.. _issue 315: https://bitbucket.org/ned/coveragepy/issues/315/option-to-omit-empty-files-eg-__init__py 1654.. _issue 328: https://bitbucket.org/ned/coveragepy/issues/328/misbehavior-in-run-source 1655.. _issue 334: https://bitbucket.org/ned/coveragepy/issues/334/pragma-not-recognized-if-tab-character 1656.. _issue 342: https://bitbucket.org/ned/coveragepy/issues/342/console-and-html-coverage-reports-differ 1657.. _issue 343: https://bitbucket.org/ned/coveragepy/issues/343/an-explicitly-named-non-existent-config 1658 1659 1660Version 4.0a1 --- 2014-09-27 1661---------------------------- 1662 1663- Python versions supported are now CPython 2.6, 2.7, 3.2, 3.3, and 3.4, and 1664 PyPy 2.2. 1665 1666- Gevent, eventlet, and greenlet are now supported, closing `issue 149`_. 1667 The ``concurrency`` setting specifies the concurrency library in use. Huge 1668 thanks to Peter Portante for initial implementation, and to Joe Jevnik for 1669 the final insight that completed the work. 1670 1671- Options are now also read from a setup.cfg file, if any. Sections are 1672 prefixed with "coverage:", so the ``[run]`` options will be read from the 1673 ``[coverage:run]`` section of setup.cfg. Finishes `issue 304`_. 1674 1675- The ``report -m`` command can now show missing branches when reporting on 1676 branch coverage. Thanks, Steve Leonard. Closes `issue 230`_. 1677 1678- The XML report now contains a <source> element, fixing `issue 94`_. Thanks 1679 Stan Hu. 1680 1681- The class defined in the coverage module is now called ``Coverage`` instead 1682 of ``coverage``, though the old name still works, for backward compatibility. 1683 1684- The ``fail-under`` value is now rounded the same as reported results, 1685 preventing paradoxical results, fixing `issue 284`_. 1686 1687- The XML report will now create the output directory if need be, fixing 1688 `issue 285`_. Thanks, Chris Rose. 1689 1690- HTML reports no longer raise UnicodeDecodeError if a Python file has 1691 undecodable characters, fixing `issue 303`_ and `issue 331`_. 1692 1693- The annotate command will now annotate all files, not just ones relative to 1694 the current directory, fixing `issue 57`_. 1695 1696- The coverage module no longer causes deprecation warnings on Python 3.4 by 1697 importing the imp module, fixing `issue 305`_. 1698 1699- Encoding declarations in source files are only considered if they are truly 1700 comments. Thanks, Anthony Sottile. 1701 1702.. _issue 57: https://bitbucket.org/ned/coveragepy/issues/57/annotate-command-fails-to-annotate-many 1703.. _issue 94: https://bitbucket.org/ned/coveragepy/issues/94/coverage-xml-doesnt-produce-sources 1704.. _issue 149: https://bitbucket.org/ned/coveragepy/issues/149/coverage-gevent-looks-broken 1705.. _issue 230: https://bitbucket.org/ned/coveragepy/issues/230/show-line-no-for-missing-branches-in 1706.. _issue 284: https://bitbucket.org/ned/coveragepy/issues/284/fail-under-should-show-more-precision 1707.. _issue 285: https://bitbucket.org/ned/coveragepy/issues/285/xml-report-fails-if-output-file-directory 1708.. _issue 303: https://bitbucket.org/ned/coveragepy/issues/303/unicodedecodeerror 1709.. _issue 304: https://bitbucket.org/ned/coveragepy/issues/304/attempt-to-get-configuration-from-setupcfg 1710.. _issue 305: https://bitbucket.org/ned/coveragepy/issues/305/pendingdeprecationwarning-the-imp-module 1711.. _issue 331: https://bitbucket.org/ned/coveragepy/issues/331/failure-of-encoding-detection-on-python2 1712 1713 1714.. _changes_371: 1715 1716Version 3.7.1 --- 2013-12-13 1717---------------------------- 1718 1719- Improved the speed of HTML report generation by about 20%. 1720 1721- Fixed the mechanism for finding OS-installed static files for the HTML report 1722 so that it will actually find OS-installed static files. 1723 1724 1725.. _changes_37: 1726 1727Version 3.7 --- 2013-10-06 1728-------------------------- 1729 1730- Added the ``--debug`` switch to ``coverage run``. It accepts a list of 1731 options indicating the type of internal activity to log to stderr. 1732 1733- Improved the branch coverage facility, fixing `issue 92`_ and `issue 175`_. 1734 1735- Running code with ``coverage run -m`` now behaves more like Python does, 1736 setting sys.path properly, which fixes `issue 207`_ and `issue 242`_. 1737 1738- Coverage.py can now run .pyc files directly, closing `issue 264`_. 1739 1740- Coverage.py properly supports .pyw files, fixing `issue 261`_. 1741 1742- Omitting files within a tree specified with the ``source`` option would 1743 cause them to be incorrectly marked as unexecuted, as described in 1744 `issue 218`_. This is now fixed. 1745 1746- When specifying paths to alias together during data combining, you can now 1747 specify relative paths, fixing `issue 267`_. 1748 1749- Most file paths can now be specified with username expansion (``~/src``, or 1750 ``~build/src``, for example), and with environment variable expansion 1751 (``build/$BUILDNUM/src``). 1752 1753- Trying to create an XML report with no files to report on, would cause a 1754 ZeroDivideError, but no longer does, fixing `issue 250`_. 1755 1756- When running a threaded program under the Python tracer, coverage.py no 1757 longer issues a spurious warning about the trace function changing: "Trace 1758 function changed, measurement is likely wrong: None." This fixes `issue 1759 164`_. 1760 1761- Static files necessary for HTML reports are found in system-installed places, 1762 to ease OS-level packaging of coverage.py. Closes `issue 259`_. 1763 1764- Source files with encoding declarations, but a blank first line, were not 1765 decoded properly. Now they are. Thanks, Roger Hu. 1766 1767- The source kit now includes the ``__main__.py`` file in the root coverage 1768 directory, fixing `issue 255`_. 1769 1770.. _issue 92: https://bitbucket.org/ned/coveragepy/issues/92/finally-clauses-arent-treated-properly-in 1771.. _issue 164: https://bitbucket.org/ned/coveragepy/issues/164/trace-function-changed-warning-when-using 1772.. _issue 175: https://bitbucket.org/ned/coveragepy/issues/175/branch-coverage-gets-confused-in-certain 1773.. _issue 207: https://bitbucket.org/ned/coveragepy/issues/207/run-m-cannot-find-module-or-package-in 1774.. _issue 242: https://bitbucket.org/ned/coveragepy/issues/242/running-a-two-level-package-doesnt-work 1775.. _issue 218: https://bitbucket.org/ned/coveragepy/issues/218/run-command-does-not-respect-the-omit-flag 1776.. _issue 250: https://bitbucket.org/ned/coveragepy/issues/250/uncaught-zerodivisionerror-when-generating 1777.. _issue 255: https://bitbucket.org/ned/coveragepy/issues/255/directory-level-__main__py-not-included-in 1778.. _issue 259: https://bitbucket.org/ned/coveragepy/issues/259/allow-use-of-system-installed-third-party 1779.. _issue 261: https://bitbucket.org/ned/coveragepy/issues/261/pyw-files-arent-reported-properly 1780.. _issue 264: https://bitbucket.org/ned/coveragepy/issues/264/coverage-wont-run-pyc-files 1781.. _issue 267: https://bitbucket.org/ned/coveragepy/issues/267/relative-path-aliases-dont-work 1782 1783 1784.. _changes_36: 1785 1786Version 3.6 --- 2013-01-05 1787-------------------------- 1788 1789- Added a page to the docs about troublesome situations, closing `issue 226`_, 1790 and added some info to the TODO file, closing `issue 227`_. 1791 1792.. _issue 226: https://bitbucket.org/ned/coveragepy/issues/226/make-readme-section-to-describe-when 1793.. _issue 227: https://bitbucket.org/ned/coveragepy/issues/227/update-todo 1794 1795 1796Version 3.6b3 --- 2012-12-29 1797---------------------------- 1798 1799- Beta 2 broke the nose plugin. It's fixed again, closing `issue 224`_. 1800 1801.. _issue 224: https://bitbucket.org/ned/coveragepy/issues/224/36b2-breaks-nosexcover 1802 1803 1804Version 3.6b2 --- 2012-12-23 1805---------------------------- 1806 1807- Coverage.py runs on Python 2.3 and 2.4 again. It was broken in 3.6b1. 1808 1809- The C extension is optionally compiled using a different more widely-used 1810 technique, taking another stab at fixing `issue 80`_ once and for all. 1811 1812- Combining data files would create entries for phantom files if used with 1813 ``source`` and path aliases. It no longer does. 1814 1815- ``debug sys`` now shows the configuration file path that was read. 1816 1817- If an oddly-behaved package claims that code came from an empty-string 1818 file name, coverage.py no longer associates it with the directory name, 1819 fixing `issue 221`_. 1820 1821.. _issue 221: https://bitbucket.org/ned/coveragepy/issues/221/coveragepy-incompatible-with-pyratemp 1822 1823 1824Version 3.6b1 --- 2012-11-28 1825---------------------------- 1826 1827- Wildcards in ``include=`` and ``omit=`` arguments were not handled properly 1828 in reporting functions, though they were when running. Now they are handled 1829 uniformly, closing `issue 143`_ and `issue 163`_. **NOTE**: it is possible 1830 that your configurations may now be incorrect. If you use ``include`` or 1831 ``omit`` during reporting, whether on the command line, through the API, or 1832 in a configuration file, please check carefully that you were not relying on 1833 the old broken behavior. 1834 1835- The **report**, **html**, and **xml** commands now accept a ``--fail-under`` 1836 switch that indicates in the exit status whether the coverage percentage was 1837 less than a particular value. Closes `issue 139`_. 1838 1839- The reporting functions coverage.report(), coverage.html_report(), and 1840 coverage.xml_report() now all return a float, the total percentage covered 1841 measurement. 1842 1843- The HTML report's title can now be set in the configuration file, with the 1844 ``--title`` switch on the command line, or via the API. 1845 1846- Configuration files now support substitution of environment variables, using 1847 syntax like ``${WORD}``. Closes `issue 97`_. 1848 1849- Embarrassingly, the ``[xml] output=`` setting in the .coveragerc file simply 1850 didn't work. Now it does. 1851 1852- The XML report now consistently uses file names for the file name attribute, 1853 rather than sometimes using module names. Fixes `issue 67`_. 1854 Thanks, Marcus Cobden. 1855 1856- Coverage percentage metrics are now computed slightly differently under 1857 branch coverage. This means that completely unexecuted files will now 1858 correctly have 0% coverage, fixing `issue 156`_. This also means that your 1859 total coverage numbers will generally now be lower if you are measuring 1860 branch coverage. 1861 1862- When installing, now in addition to creating a "coverage" command, two new 1863 aliases are also installed. A "coverage2" or "coverage3" command will be 1864 created, depending on whether you are installing in Python 2.x or 3.x. 1865 A "coverage-X.Y" command will also be created corresponding to your specific 1866 version of Python. Closes `issue 111`_. 1867 1868- The coverage.py installer no longer tries to bootstrap setuptools or 1869 Distribute. You must have one of them installed first, as `issue 202`_ 1870 recommended. 1871 1872- The coverage.py kit now includes docs (closing `issue 137`_) and tests. 1873 1874- On Windows, files are now reported in their correct case, fixing `issue 89`_ 1875 and `issue 203`_. 1876 1877- If a file is missing during reporting, the path shown in the error message 1878 is now correct, rather than an incorrect path in the current directory. 1879 Fixes `issue 60`_. 1880 1881- Running an HTML report in Python 3 in the same directory as an old Python 2 1882 HTML report would fail with a UnicodeDecodeError. This issue (`issue 193`_) 1883 is now fixed. 1884 1885- Fixed yet another error trying to parse non-Python files as Python, this 1886 time an IndentationError, closing `issue 82`_ for the fourth time... 1887 1888- If `coverage xml` fails because there is no data to report, it used to 1889 create a zero-length XML file. Now it doesn't, fixing `issue 210`_. 1890 1891- Jython files now work with the ``--source`` option, fixing `issue 100`_. 1892 1893- Running coverage.py under a debugger is unlikely to work, but it shouldn't 1894 fail with "TypeError: 'NoneType' object is not iterable". Fixes `issue 1895 201`_. 1896 1897- On some Linux distributions, when installed with the OS package manager, 1898 coverage.py would report its own code as part of the results. Now it won't, 1899 fixing `issue 214`_, though this will take some time to be repackaged by the 1900 operating systems. 1901 1902- Docstrings for the legacy singleton methods are more helpful. Thanks Marius 1903 Gedminas. Closes `issue 205`_. 1904 1905- The pydoc tool can now show documentation for the class `coverage.coverage`. 1906 Closes `issue 206`_. 1907 1908- Added a page to the docs about contributing to coverage.py, closing 1909 `issue 171`_. 1910 1911- When coverage.py ended unsuccessfully, it may have reported odd errors like 1912 ``'NoneType' object has no attribute 'isabs'``. It no longer does, 1913 so kiss `issue 153`_ goodbye. 1914 1915.. _issue 60: https://bitbucket.org/ned/coveragepy/issues/60/incorrect-path-to-orphaned-pyc-files 1916.. _issue 67: https://bitbucket.org/ned/coveragepy/issues/67/xml-report-filenames-may-be-generated 1917.. _issue 89: https://bitbucket.org/ned/coveragepy/issues/89/on-windows-all-packages-are-reported-in 1918.. _issue 97: https://bitbucket.org/ned/coveragepy/issues/97/allow-environment-variables-to-be 1919.. _issue 100: https://bitbucket.org/ned/coveragepy/issues/100/source-directive-doesnt-work-for-packages 1920.. _issue 111: https://bitbucket.org/ned/coveragepy/issues/111/when-installing-coverage-with-pip-not 1921.. _issue 137: https://bitbucket.org/ned/coveragepy/issues/137/provide-docs-with-source-distribution 1922.. _issue 139: https://bitbucket.org/ned/coveragepy/issues/139/easy-check-for-a-certain-coverage-in-tests 1923.. _issue 143: https://bitbucket.org/ned/coveragepy/issues/143/omit-doesnt-seem-to-work-in-coverage 1924.. _issue 153: https://bitbucket.org/ned/coveragepy/issues/153/non-existent-filename-triggers 1925.. _issue 156: https://bitbucket.org/ned/coveragepy/issues/156/a-completely-unexecuted-file-shows-14 1926.. _issue 163: https://bitbucket.org/ned/coveragepy/issues/163/problem-with-include-and-omit-filename 1927.. _issue 171: https://bitbucket.org/ned/coveragepy/issues/171/how-to-contribute-and-run-tests 1928.. _issue 193: https://bitbucket.org/ned/coveragepy/issues/193/unicodedecodeerror-on-htmlpy 1929.. _issue 201: https://bitbucket.org/ned/coveragepy/issues/201/coverage-using-django-14-with-pydb-on 1930.. _issue 202: https://bitbucket.org/ned/coveragepy/issues/202/get-rid-of-ez_setuppy-and 1931.. _issue 203: https://bitbucket.org/ned/coveragepy/issues/203/duplicate-filenames-reported-when-filename 1932.. _issue 205: https://bitbucket.org/ned/coveragepy/issues/205/make-pydoc-coverage-more-friendly 1933.. _issue 206: https://bitbucket.org/ned/coveragepy/issues/206/pydoc-coveragecoverage-fails-with-an-error 1934.. _issue 210: https://bitbucket.org/ned/coveragepy/issues/210/if-theres-no-coverage-data-coverage-xml 1935.. _issue 214: https://bitbucket.org/ned/coveragepy/issues/214/coveragepy-measures-itself-on-precise 1936 1937 1938.. _changes_353: 1939 1940Version 3.5.3 --- 2012-09-29 1941---------------------------- 1942 1943- Line numbers in the HTML report line up better with the source lines, fixing 1944 `issue 197`_, thanks Marius Gedminas. 1945 1946- When specifying a directory as the source= option, the directory itself no 1947 longer needs to have a ``__init__.py`` file, though its sub-directories do, 1948 to be considered as source files. 1949 1950- Files encoded as UTF-8 with a BOM are now properly handled, fixing 1951 `issue 179`_. Thanks, Pablo Carballo. 1952 1953- Fixed more cases of non-Python files being reported as Python source, and 1954 then not being able to parse them as Python. Closes `issue 82`_ (again). 1955 Thanks, Julian Berman. 1956 1957- Fixed memory leaks under Python 3, thanks, Brett Cannon. Closes `issue 147`_. 1958 1959- Optimized .pyo files may not have been handled correctly, `issue 195`_. 1960 Thanks, Marius Gedminas. 1961 1962- Certain unusually named file paths could have been mangled during reporting, 1963 `issue 194`_. Thanks, Marius Gedminas. 1964 1965- Try to do a better job of the impossible task of detecting when we can't 1966 build the C extension, fixing `issue 183`_. 1967 1968- Testing is now done with `tox`_, thanks, Marc Abramowitz. 1969 1970.. _issue 147: https://bitbucket.org/ned/coveragepy/issues/147/massive-memory-usage-by-ctracer 1971.. _issue 179: https://bitbucket.org/ned/coveragepy/issues/179/htmlreporter-fails-when-source-file-is 1972.. _issue 183: https://bitbucket.org/ned/coveragepy/issues/183/install-fails-for-python-23 1973.. _issue 194: https://bitbucket.org/ned/coveragepy/issues/194/filelocatorrelative_filename-could-mangle 1974.. _issue 195: https://bitbucket.org/ned/coveragepy/issues/195/pyo-file-handling-in-codeunit 1975.. _issue 197: https://bitbucket.org/ned/coveragepy/issues/197/line-numbers-in-html-report-do-not-align 1976.. _tox: https://tox.readthedocs.io/ 1977 1978 1979.. _changes_352: 1980 1981Version 3.5.2 --- 2012-05-04 1982---------------------------- 1983 1984No changes since 3.5.2.b1 1985 1986 1987Version 3.5.2b1 --- 2012-04-29 1988------------------------------ 1989 1990- The HTML report has slightly tweaked controls: the buttons at the top of 1991 the page are color-coded to the source lines they affect. 1992 1993- Custom CSS can be applied to the HTML report by specifying a CSS file as 1994 the ``extra_css`` configuration value in the ``[html]`` section. 1995 1996- Source files with custom encodings declared in a comment at the top are now 1997 properly handled during reporting on Python 2. Python 3 always handled them 1998 properly. This fixes `issue 157`_. 1999 2000- Backup files left behind by editors are no longer collected by the source= 2001 option, fixing `issue 168`_. 2002 2003- If a file doesn't parse properly as Python, we don't report it as an error 2004 if the file name seems like maybe it wasn't meant to be Python. This is a 2005 pragmatic fix for `issue 82`_. 2006 2007- The ``-m`` switch on ``coverage report``, which includes missing line numbers 2008 in the summary report, can now be specified as ``show_missing`` in the 2009 config file. Closes `issue 173`_. 2010 2011- When running a module with ``coverage run -m <modulename>``, certain details 2012 of the execution environment weren't the same as for 2013 ``python -m <modulename>``. This had the unfortunate side-effect of making 2014 ``coverage run -m unittest discover`` not work if you had tests in a 2015 directory named "test". This fixes `issue 155`_ and `issue 142`_. 2016 2017- Now the exit status of your product code is properly used as the process 2018 status when running ``python -m coverage run ...``. Thanks, JT Olds. 2019 2020- When installing into pypy, we no longer attempt (and fail) to compile 2021 the C tracer function, closing `issue 166`_. 2022 2023.. _issue 142: https://bitbucket.org/ned/coveragepy/issues/142/executing-python-file-syspath-is-replaced 2024.. _issue 155: https://bitbucket.org/ned/coveragepy/issues/155/cant-use-coverage-run-m-unittest-discover 2025.. _issue 157: https://bitbucket.org/ned/coveragepy/issues/157/chokes-on-source-files-with-non-utf-8 2026.. _issue 166: https://bitbucket.org/ned/coveragepy/issues/166/dont-try-to-compile-c-extension-on-pypy 2027.. _issue 168: https://bitbucket.org/ned/coveragepy/issues/168/dont-be-alarmed-by-emacs-droppings 2028.. _issue 173: https://bitbucket.org/ned/coveragepy/issues/173/theres-no-way-to-specify-show-missing-in 2029 2030 2031.. _changes_351: 2032 2033Version 3.5.1 --- 2011-09-23 2034---------------------------- 2035 2036- The ``[paths]`` feature unfortunately didn't work in real world situations 2037 where you wanted to, you know, report on the combined data. Now all paths 2038 stored in the combined file are canonicalized properly. 2039 2040 2041Version 3.5.1b1 --- 2011-08-28 2042------------------------------ 2043 2044- When combining data files from parallel runs, you can now instruct 2045 coverage.py about which directories are equivalent on different machines. A 2046 ``[paths]`` section in the configuration file lists paths that are to be 2047 considered equivalent. Finishes `issue 17`_. 2048 2049- for-else constructs are understood better, and don't cause erroneous partial 2050 branch warnings. Fixes `issue 122`_. 2051 2052- Branch coverage for ``with`` statements is improved, fixing `issue 128`_. 2053 2054- The number of partial branches reported on the HTML summary page was 2055 different than the number reported on the individual file pages. This is 2056 now fixed. 2057 2058- An explicit include directive to measure files in the Python installation 2059 wouldn't work because of the standard library exclusion. Now the include 2060 directive takes precedence, and the files will be measured. Fixes 2061 `issue 138`_. 2062 2063- The HTML report now handles Unicode characters in Python source files 2064 properly. This fixes `issue 124`_ and `issue 144`_. Thanks, Devin 2065 Jeanpierre. 2066 2067- In order to help the core developers measure the test coverage of the 2068 standard library, Brandon Rhodes devised an aggressive hack to trick Python 2069 into running some coverage.py code before anything else in the process. 2070 See the coverage/fullcoverage directory if you are interested. 2071 2072.. _issue 17: https://bitbucket.org/ned/coveragepy/issues/17/support-combining-coverage-data-from 2073.. _issue 122: https://bitbucket.org/ned/coveragepy/issues/122/for-else-always-reports-missing-branch 2074.. _issue 124: https://bitbucket.org/ned/coveragepy/issues/124/no-arbitrary-unicode-in-html-reports-in 2075.. _issue 128: https://bitbucket.org/ned/coveragepy/issues/128/branch-coverage-of-with-statement-in-27 2076.. _issue 138: https://bitbucket.org/ned/coveragepy/issues/138/include-should-take-precedence-over-is 2077.. _issue 144: https://bitbucket.org/ned/coveragepy/issues/144/failure-generating-html-output-for 2078 2079 2080.. _changes_35: 2081 2082Version 3.5 --- 2011-06-29 2083-------------------------- 2084 2085- The HTML report hotkeys now behave slightly differently when the current 2086 chunk isn't visible at all: a chunk on the screen will be selected, 2087 instead of the old behavior of jumping to the literal next chunk. 2088 The hotkeys now work in Google Chrome. Thanks, Guido van Rossum. 2089 2090 2091Version 3.5b1 --- 2011-06-05 2092---------------------------- 2093 2094- The HTML report now has hotkeys. Try ``n``, ``s``, ``m``, ``x``, ``b``, 2095 ``p``, and ``c`` on the overview page to change the column sorting. 2096 On a file page, ``r``, ``m``, ``x``, and ``p`` toggle the run, missing, 2097 excluded, and partial line markings. You can navigate the highlighted 2098 sections of code by using the ``j`` and ``k`` keys for next and previous. 2099 The ``1`` (one) key jumps to the first highlighted section in the file, 2100 and ``0`` (zero) scrolls to the top of the file. 2101 2102- The ``--omit`` and ``--include`` switches now interpret their values more 2103 usefully. If the value starts with a wildcard character, it is used as-is. 2104 If it does not, it is interpreted relative to the current directory. 2105 Closes `issue 121`_. 2106 2107- Partial branch warnings can now be pragma'd away. The configuration option 2108 ``partial_branches`` is a list of regular expressions. Lines matching any of 2109 those expressions will never be marked as a partial branch. In addition, 2110 there's a built-in list of regular expressions marking statements which 2111 should never be marked as partial. This list includes ``while True:``, 2112 ``while 1:``, ``if 1:``, and ``if 0:``. 2113 2114- The ``coverage()`` constructor accepts single strings for the ``omit=`` and 2115 ``include=`` arguments, adapting to a common error in programmatic use. 2116 2117- Modules can now be run directly using ``coverage run -m modulename``, to 2118 mirror Python's ``-m`` flag. Closes `issue 95`_, thanks, Brandon Rhodes. 2119 2120- ``coverage run`` didn't emulate Python accurately in one small detail: the 2121 current directory inserted into ``sys.path`` was relative rather than 2122 absolute. This is now fixed. 2123 2124- HTML reporting is now incremental: a record is kept of the data that 2125 produced the HTML reports, and only files whose data has changed will 2126 be generated. This should make most HTML reporting faster. 2127 2128- Pathological code execution could disable the trace function behind our 2129 backs, leading to incorrect code measurement. Now if this happens, 2130 coverage.py will issue a warning, at least alerting you to the problem. 2131 Closes `issue 93`_. Thanks to Marius Gedminas for the idea. 2132 2133- The C-based trace function now behaves properly when saved and restored 2134 with ``sys.gettrace()`` and ``sys.settrace()``. This fixes `issue 125`_ 2135 and `issue 123`_. Thanks, Devin Jeanpierre. 2136 2137- Source files are now opened with Python 3.2's ``tokenize.open()`` where 2138 possible, to get the best handling of Python source files with encodings. 2139 Closes `issue 107`_, thanks, Brett Cannon. 2140 2141- Syntax errors in supposed Python files can now be ignored during reporting 2142 with the ``-i`` switch just like other source errors. Closes `issue 115`_. 2143 2144- Installation from source now succeeds on machines without a C compiler, 2145 closing `issue 80`_. 2146 2147- Coverage.py can now be run directly from a working tree by specifying 2148 the directory name to python: ``python coverage_py_working_dir run ...``. 2149 Thanks, Brett Cannon. 2150 2151- A little bit of Jython support: `coverage run` can now measure Jython 2152 execution by adapting when $py.class files are traced. Thanks, Adi Roiban. 2153 Jython still doesn't provide the Python libraries needed to make 2154 coverage reporting work, unfortunately. 2155 2156- Internally, files are now closed explicitly, fixing `issue 104`_. Thanks, 2157 Brett Cannon. 2158 2159.. _issue 80: https://bitbucket.org/ned/coveragepy/issues/80/is-there-a-duck-typing-way-to-know-we-cant 2160.. _issue 93: https://bitbucket.org/ned/coveragepy/issues/93/copying-a-mock-object-breaks-coverage 2161.. _issue 95: https://bitbucket.org/ned/coveragepy/issues/95/run-subcommand-should-take-a-module-name 2162.. _issue 104: https://bitbucket.org/ned/coveragepy/issues/104/explicitly-close-files 2163.. _issue 107: https://bitbucket.org/ned/coveragepy/issues/107/codeparser-not-opening-source-files-with 2164.. _issue 115: https://bitbucket.org/ned/coveragepy/issues/115/fail-gracefully-when-reporting-on-file 2165.. _issue 121: https://bitbucket.org/ned/coveragepy/issues/121/filename-patterns-are-applied-stupidly 2166.. _issue 123: https://bitbucket.org/ned/coveragepy/issues/123/pyeval_settrace-used-in-way-that-breaks 2167.. _issue 125: https://bitbucket.org/ned/coveragepy/issues/125/coverage-removes-decoratortoolss-tracing 2168 2169 2170.. _changes_34: 2171 2172Version 3.4 --- 2010-09-19 2173-------------------------- 2174 2175- The XML report is now sorted by package name, fixing `issue 88`_. 2176 2177- Programs that exited with ``sys.exit()`` with no argument weren't handled 2178 properly, producing a coverage.py stack trace. That is now fixed. 2179 2180.. _issue 88: https://bitbucket.org/ned/coveragepy/issues/88/xml-report-lists-packages-in-random-order 2181 2182 2183Version 3.4b2 --- 2010-09-06 2184---------------------------- 2185 2186- Completely unexecuted files can now be included in coverage results, reported 2187 as 0% covered. This only happens if the --source option is specified, since 2188 coverage.py needs guidance about where to look for source files. 2189 2190- The XML report output now properly includes a percentage for branch coverage, 2191 fixing `issue 65`_ and `issue 81`_. 2192 2193- Coverage percentages are now displayed uniformly across reporting methods. 2194 Previously, different reports could round percentages differently. Also, 2195 percentages are only reported as 0% or 100% if they are truly 0 or 100, and 2196 are rounded otherwise. Fixes `issue 41`_ and `issue 70`_. 2197 2198- The precision of reported coverage percentages can be set with the 2199 ``[report] precision`` config file setting. Completes `issue 16`_. 2200 2201- Threads derived from ``threading.Thread`` with an overridden `run` method 2202 would report no coverage for the `run` method. This is now fixed, closing 2203 `issue 85`_. 2204 2205.. _issue 16: https://bitbucket.org/ned/coveragepy/issues/16/allow-configuration-of-accuracy-of-percentage-totals 2206.. _issue 41: https://bitbucket.org/ned/coveragepy/issues/41/report-says-100-when-it-isnt-quite-there 2207.. _issue 65: https://bitbucket.org/ned/coveragepy/issues/65/branch-option-not-reported-in-cobertura 2208.. _issue 70: https://bitbucket.org/ned/coveragepy/issues/70/text-report-and-html-report-disagree-on-coverage 2209.. _issue 81: https://bitbucket.org/ned/coveragepy/issues/81/xml-report-does-not-have-condition-coverage-attribute-for-lines-with-a 2210.. _issue 85: https://bitbucket.org/ned/coveragepy/issues/85/threadrun-isnt-measured 2211 2212 2213Version 3.4b1 --- 2010-08-21 2214---------------------------- 2215 2216- BACKWARD INCOMPATIBILITY: the ``--omit`` and ``--include`` switches now take 2217 file patterns rather than file prefixes, closing `issue 34`_ and `issue 36`_. 2218 2219- BACKWARD INCOMPATIBILITY: the `omit_prefixes` argument is gone throughout 2220 coverage.py, replaced with `omit`, a list of file name patterns suitable for 2221 `fnmatch`. A parallel argument `include` controls what files are included. 2222 2223- The run command now has a ``--source`` switch, a list of directories or 2224 module names. If provided, coverage.py will only measure execution in those 2225 source files. 2226 2227- Various warnings are printed to stderr for problems encountered during data 2228 measurement: if a ``--source`` module has no Python source to measure, or is 2229 never encountered at all, or if no data is collected. 2230 2231- The reporting commands (report, annotate, html, and xml) now have an 2232 ``--include`` switch to restrict reporting to modules matching those file 2233 patterns, similar to the existing ``--omit`` switch. Thanks, Zooko. 2234 2235- The run command now supports ``--include`` and ``--omit`` to control what 2236 modules it measures. This can speed execution and reduce the amount of data 2237 during reporting. Thanks Zooko. 2238 2239- Since coverage.py 3.1, using the Python trace function has been slower than 2240 it needs to be. A cache of tracing decisions was broken, but has now been 2241 fixed. 2242 2243- Python 2.7 and 3.2 have introduced new opcodes that are now supported. 2244 2245- Python files with no statements, for example, empty ``__init__.py`` files, 2246 are now reported as having zero statements instead of one. Fixes `issue 1`_. 2247 2248- Reports now have a column of missed line counts rather than executed line 2249 counts, since developers should focus on reducing the missed lines to zero, 2250 rather than increasing the executed lines to varying targets. Once 2251 suggested, this seemed blindingly obvious. 2252 2253- Line numbers in HTML source pages are clickable, linking directly to that 2254 line, which is highlighted on arrival. Added a link back to the index page 2255 at the bottom of each HTML page. 2256 2257- Programs that call ``os.fork`` will properly collect data from both the child 2258 and parent processes. Use ``coverage run -p`` to get two data files that can 2259 be combined with ``coverage combine``. Fixes `issue 56`_. 2260 2261- Coverage.py is now runnable as a module: ``python -m coverage``. Thanks, 2262 Brett Cannon. 2263 2264- When measuring code running in a virtualenv, most of the system library was 2265 being measured when it shouldn't have been. This is now fixed. 2266 2267- Doctest text files are no longer recorded in the coverage data, since they 2268 can't be reported anyway. Fixes `issue 52`_ and `issue 61`_. 2269 2270- Jinja HTML templates compile into Python code using the HTML file name, 2271 which confused coverage.py. Now these files are no longer traced, fixing 2272 `issue 82`_. 2273 2274- Source files can have more than one dot in them (foo.test.py), and will be 2275 treated properly while reporting. Fixes `issue 46`_. 2276 2277- Source files with DOS line endings are now properly tokenized for syntax 2278 coloring on non-DOS machines. Fixes `issue 53`_. 2279 2280- Unusual code structure that confused exits from methods with exits from 2281 classes is now properly analyzed. See `issue 62`_. 2282 2283- Asking for an HTML report with no files now shows a nice error message rather 2284 than a cryptic failure ('int' object is unsubscriptable). Fixes `issue 59`_. 2285 2286.. _issue 1: https://bitbucket.org/ned/coveragepy/issues/1/empty-__init__py-files-are-reported-as-1-executable 2287.. _issue 34: https://bitbucket.org/ned/coveragepy/issues/34/enhanced-omit-globbing-handling 2288.. _issue 36: https://bitbucket.org/ned/coveragepy/issues/36/provide-regex-style-omit 2289.. _issue 46: https://bitbucket.org/ned/coveragepy/issues/46 2290.. _issue 53: https://bitbucket.org/ned/coveragepy/issues/53 2291.. _issue 52: https://bitbucket.org/ned/coveragepy/issues/52/doctesttestfile-confuses-source-detection 2292.. _issue 56: https://bitbucket.org/ned/coveragepy/issues/56 2293.. _issue 61: https://bitbucket.org/ned/coveragepy/issues/61/annotate-i-doesnt-work 2294.. _issue 62: https://bitbucket.org/ned/coveragepy/issues/62 2295.. _issue 59: https://bitbucket.org/ned/coveragepy/issues/59/html-report-fails-with-int-object-is 2296.. _issue 82: https://bitbucket.org/ned/coveragepy/issues/82/tokenerror-when-generating-html-report 2297 2298 2299.. _changes_331: 2300 2301Version 3.3.1 --- 2010-03-06 2302---------------------------- 2303 2304- Using `parallel=True` in .coveragerc file prevented reporting, but now does 2305 not, fixing `issue 49`_. 2306 2307- When running your code with "coverage run", if you call `sys.exit()`, 2308 coverage.py will exit with that status code, fixing `issue 50`_. 2309 2310.. _issue 49: https://bitbucket.org/ned/coveragepy/issues/49 2311.. _issue 50: https://bitbucket.org/ned/coveragepy/issues/50 2312 2313 2314.. _changes_33: 2315 2316Version 3.3 --- 2010-02-24 2317-------------------------- 2318 2319- Settings are now read from a .coveragerc file. A specific file can be 2320 specified on the command line with --rcfile=FILE. The name of the file can 2321 be programmatically set with the `config_file` argument to the coverage() 2322 constructor, or reading a config file can be disabled with 2323 `config_file=False`. 2324 2325- Fixed a problem with nested loops having their branch possibilities 2326 mischaracterized: `issue 39`_. 2327 2328- Added coverage.process_start to enable coverage measurement when Python 2329 starts. 2330 2331- Parallel data file names now have a random number appended to them in 2332 addition to the machine name and process id. 2333 2334- Parallel data files combined with "coverage combine" are deleted after 2335 they're combined, to clean up unneeded files. Fixes `issue 40`_. 2336 2337- Exceptions thrown from product code run with "coverage run" are now displayed 2338 without internal coverage.py frames, so the output is the same as when the 2339 code is run without coverage.py. 2340 2341- The `data_suffix` argument to the coverage constructor is now appended with 2342 an added dot rather than simply appended, so that .coveragerc files will not 2343 be confused for data files. 2344 2345- Python source files that don't end with a newline can now be executed, fixing 2346 `issue 47`_. 2347 2348- Added an AUTHORS.txt file. 2349 2350.. _issue 39: https://bitbucket.org/ned/coveragepy/issues/39 2351.. _issue 40: https://bitbucket.org/ned/coveragepy/issues/40 2352.. _issue 47: https://bitbucket.org/ned/coveragepy/issues/47 2353 2354 2355.. _changes_32: 2356 2357Version 3.2 --- 2009-12-05 2358-------------------------- 2359 2360- Added a ``--version`` option on the command line. 2361 2362 2363Version 3.2b4 --- 2009-12-01 2364---------------------------- 2365 2366- Branch coverage improvements: 2367 2368 - The XML report now includes branch information. 2369 2370- Click-to-sort HTML report columns are now persisted in a cookie. Viewing 2371 a report will sort it first the way you last had a coverage report sorted. 2372 Thanks, `Chris Adams`_. 2373 2374- On Python 3.x, setuptools has been replaced by `Distribute`_. 2375 2376.. _Distribute: https://pypi.org/project/distribute/ 2377 2378 2379Version 3.2b3 --- 2009-11-23 2380---------------------------- 2381 2382- Fixed a memory leak in the C tracer that was introduced in 3.2b1. 2383 2384- Branch coverage improvements: 2385 2386 - Branches to excluded code are ignored. 2387 2388- The table of contents in the HTML report is now sortable: click the headers 2389 on any column. Thanks, `Chris Adams`_. 2390 2391.. _Chris Adams: http://chris.improbable.org 2392 2393 2394Version 3.2b2 --- 2009-11-19 2395---------------------------- 2396 2397- Branch coverage improvements: 2398 2399 - Classes are no longer incorrectly marked as branches: `issue 32`_. 2400 2401 - "except" clauses with types are no longer incorrectly marked as branches: 2402 `issue 35`_. 2403 2404- Fixed some problems syntax coloring sources with line continuations and 2405 source with tabs: `issue 30`_ and `issue 31`_. 2406 2407- The --omit option now works much better than before, fixing `issue 14`_ and 2408 `issue 33`_. Thanks, Danek Duvall. 2409 2410.. _issue 14: https://bitbucket.org/ned/coveragepy/issues/14 2411.. _issue 30: https://bitbucket.org/ned/coveragepy/issues/30 2412.. _issue 31: https://bitbucket.org/ned/coveragepy/issues/31 2413.. _issue 32: https://bitbucket.org/ned/coveragepy/issues/32 2414.. _issue 33: https://bitbucket.org/ned/coveragepy/issues/33 2415.. _issue 35: https://bitbucket.org/ned/coveragepy/issues/35 2416 2417 2418Version 3.2b1 --- 2009-11-10 2419---------------------------- 2420 2421- Branch coverage! 2422 2423- XML reporting has file paths that let Cobertura find the source code. 2424 2425- The tracer code has changed, it's a few percent faster. 2426 2427- Some exceptions reported by the command line interface have been cleaned up 2428 so that tracebacks inside coverage.py aren't shown. Fixes `issue 23`_. 2429 2430.. _issue 23: https://bitbucket.org/ned/coveragepy/issues/23 2431 2432 2433.. _changes_31: 2434 2435Version 3.1 --- 2009-10-04 2436-------------------------- 2437 2438- Source code can now be read from eggs. Thanks, Ross Lawley. Fixes 2439 `issue 25`_. 2440 2441.. _issue 25: https://bitbucket.org/ned/coveragepy/issues/25 2442 2443 2444Version 3.1b1 --- 2009-09-27 2445---------------------------- 2446 2447- Python 3.1 is now supported. 2448 2449- Coverage.py has a new command line syntax with sub-commands. This expands 2450 the possibilities for adding features and options in the future. The old 2451 syntax is still supported. Try "coverage help" to see the new commands. 2452 Thanks to Ben Finney for early help. 2453 2454- Added an experimental "coverage xml" command for producing coverage reports 2455 in a Cobertura-compatible XML format. Thanks, Bill Hart. 2456 2457- Added the --timid option to enable a simpler slower trace function that works 2458 for DecoratorTools projects, including TurboGears. Fixed `issue 12`_ and 2459 `issue 13`_. 2460 2461- HTML reports show modules from other directories. Fixed `issue 11`_. 2462 2463- HTML reports now display syntax-colored Python source. 2464 2465- Programs that change directory will still write .coverage files in the 2466 directory where execution started. Fixed `issue 24`_. 2467 2468- Added a "coverage debug" command for getting diagnostic information about the 2469 coverage.py installation. 2470 2471.. _issue 11: https://bitbucket.org/ned/coveragepy/issues/11 2472.. _issue 12: https://bitbucket.org/ned/coveragepy/issues/12 2473.. _issue 13: https://bitbucket.org/ned/coveragepy/issues/13 2474.. _issue 24: https://bitbucket.org/ned/coveragepy/issues/24 2475 2476 2477.. _changes_301: 2478 2479Version 3.0.1 --- 2009-07-07 2480---------------------------- 2481 2482- Removed the recursion limit in the tracer function. Previously, code that 2483 ran more than 500 frames deep would crash. Fixed `issue 9`_. 2484 2485- Fixed a bizarre problem involving pyexpat, whereby lines following XML parser 2486 invocations could be overlooked. Fixed `issue 10`_. 2487 2488- On Python 2.3, coverage.py could mis-measure code with exceptions being 2489 raised. This is now fixed. 2490 2491- The coverage.py code itself will now not be measured by coverage.py, and no 2492 coverage.py modules will be mentioned in the nose --with-cover plug-in. 2493 Fixed `issue 8`_. 2494 2495- When running source files, coverage.py now opens them in universal newline 2496 mode just like Python does. This lets it run Windows files on Mac, for 2497 example. 2498 2499.. _issue 9: https://bitbucket.org/ned/coveragepy/issues/9 2500.. _issue 10: https://bitbucket.org/ned/coveragepy/issues/10 2501.. _issue 8: https://bitbucket.org/ned/coveragepy/issues/8 2502 2503 2504.. _changes_30: 2505 2506Version 3.0 --- 2009-06-13 2507-------------------------- 2508 2509- Fixed the way the Python library was ignored. Too much code was being 2510 excluded the old way. 2511 2512- Tabs are now properly converted in HTML reports. Previously indentation was 2513 lost. Fixed `issue 6`_. 2514 2515- Nested modules now get a proper flat_rootname. Thanks, Christian Heimes. 2516 2517.. _issue 6: https://bitbucket.org/ned/coveragepy/issues/6 2518 2519 2520Version 3.0b3 --- 2009-05-16 2521---------------------------- 2522 2523- Added parameters to coverage.__init__ for options that had been set on the 2524 coverage object itself. 2525 2526- Added clear_exclude() and get_exclude_list() methods for programmatic 2527 manipulation of the exclude regexes. 2528 2529- Added coverage.load() to read previously-saved data from the data file. 2530 2531- Improved the finding of code files. For example, .pyc files that have been 2532 installed after compiling are now located correctly. Thanks, Detlev 2533 Offenbach. 2534 2535- When using the object API (that is, constructing a coverage() object), data 2536 is no longer saved automatically on process exit. You can re-enable it with 2537 the auto_data=True parameter on the coverage() constructor. The module-level 2538 interface still uses automatic saving. 2539 2540 2541Version 3.0b --- 2009-04-30 2542--------------------------- 2543 2544HTML reporting, and continued refactoring. 2545 2546- HTML reports and annotation of source files: use the new -b (browser) switch. 2547 Thanks to George Song for code, inspiration and guidance. 2548 2549- Code in the Python standard library is not measured by default. If you need 2550 to measure standard library code, use the -L command-line switch during 2551 execution, or the cover_pylib=True argument to the coverage() constructor. 2552 2553- Source annotation into a directory (-a -d) behaves differently. The 2554 annotated files are named with their hierarchy flattened so that same-named 2555 files from different directories no longer collide. Also, only files in the 2556 current tree are included. 2557 2558- coverage.annotate_file is no longer available. 2559 2560- Programs executed with -x now behave more as they should, for example, 2561 __file__ has the correct value. 2562 2563- .coverage data files have a new pickle-based format designed for better 2564 extensibility. 2565 2566- Removed the undocumented cache_file argument to coverage.usecache(). 2567 2568 2569Version 3.0b1 --- 2009-03-07 2570---------------------------- 2571 2572Major overhaul. 2573 2574- Coverage.py is now a package rather than a module. Functionality has been 2575 split into classes. 2576 2577- The trace function is implemented in C for speed. Coverage.py runs are now 2578 much faster. Thanks to David Christian for productive micro-sprints and 2579 other encouragement. 2580 2581- Executable lines are identified by reading the line number tables in the 2582 compiled code, removing a great deal of complicated analysis code. 2583 2584- Precisely which lines are considered executable has changed in some cases. 2585 Therefore, your coverage stats may also change slightly. 2586 2587- The singleton coverage object is only created if the module-level functions 2588 are used. This maintains the old interface while allowing better 2589 programmatic use of coverage.py. 2590 2591- The minimum supported Python version is 2.3. 2592 2593 2594Version 2.85 --- 2008-09-14 2595--------------------------- 2596 2597- Add support for finding source files in eggs. Don't check for 2598 morf's being instances of ModuleType, instead use duck typing so that 2599 pseudo-modules can participate. Thanks, Imri Goldberg. 2600 2601- Use os.realpath as part of the fixing of file names so that symlinks won't 2602 confuse things. Thanks, Patrick Mezard. 2603 2604 2605Version 2.80 --- 2008-05-25 2606--------------------------- 2607 2608- Open files in rU mode to avoid line ending craziness. Thanks, Edward Loper. 2609 2610 2611Version 2.78 --- 2007-09-30 2612--------------------------- 2613 2614- Don't try to predict whether a file is Python source based on the extension. 2615 Extension-less files are often Pythons scripts. Instead, simply parse the 2616 file and catch the syntax errors. Hat tip to Ben Finney. 2617 2618 2619Version 2.77 --- 2007-07-29 2620--------------------------- 2621 2622- Better packaging. 2623 2624 2625Version 2.76 --- 2007-07-23 2626--------------------------- 2627 2628- Now Python 2.5 is *really* fully supported: the body of the new with 2629 statement is counted as executable. 2630 2631 2632Version 2.75 --- 2007-07-22 2633--------------------------- 2634 2635- Python 2.5 now fully supported. The method of dealing with multi-line 2636 statements is now less sensitive to the exact line that Python reports during 2637 execution. Pass statements are handled specially so that their disappearance 2638 during execution won't throw off the measurement. 2639 2640 2641Version 2.7 --- 2007-07-21 2642-------------------------- 2643 2644- "#pragma: nocover" is excluded by default. 2645 2646- Properly ignore docstrings and other constant expressions that appear in the 2647 middle of a function, a problem reported by Tim Leslie. 2648 2649- coverage.erase() shouldn't clobber the exclude regex. Change how parallel 2650 mode is invoked, and fix erase() so that it erases the cache when called 2651 programmatically. 2652 2653- In reports, ignore code executed from strings, since we can't do anything 2654 useful with it anyway. 2655 2656- Better file handling on Linux, thanks Guillaume Chazarain. 2657 2658- Better shell support on Windows, thanks Noel O'Boyle. 2659 2660- Python 2.2 support maintained, thanks Catherine Proulx. 2661 2662- Minor changes to avoid lint warnings. 2663 2664 2665Version 2.6 --- 2006-08-23 2666-------------------------- 2667 2668- Applied Joseph Tate's patch for function decorators. 2669 2670- Applied Sigve Tjora and Mark van der Wal's fixes for argument handling. 2671 2672- Applied Geoff Bache's parallel mode patch. 2673 2674- Refactorings to improve testability. Fixes to command-line logic for parallel 2675 mode and collect. 2676 2677 2678Version 2.5 --- 2005-12-04 2679-------------------------- 2680 2681- Call threading.settrace so that all threads are measured. Thanks Martin 2682 Fuzzey. 2683 2684- Add a file argument to report so that reports can be captured to a different 2685 destination. 2686 2687- Coverage.py can now measure itself. 2688 2689- Adapted Greg Rogers' patch for using relative file names, and sorting and 2690 omitting files to report on. 2691 2692 2693Version 2.2 --- 2004-12-31 2694-------------------------- 2695 2696- Allow for keyword arguments in the module global functions. Thanks, Allen. 2697 2698 2699Version 2.1 --- 2004-12-14 2700-------------------------- 2701 2702- Return 'analysis' to its original behavior and add 'analysis2'. Add a global 2703 for 'annotate', and factor it, adding 'annotate_file'. 2704 2705 2706Version 2.0 --- 2004-12-12 2707-------------------------- 2708 2709Significant code changes. 2710 2711- Finding executable statements has been rewritten so that docstrings and 2712 other quirks of Python execution aren't mistakenly identified as missing 2713 lines. 2714 2715- Lines can be excluded from consideration, even entire suites of lines. 2716 2717- The file system cache of covered lines can be disabled programmatically. 2718 2719- Modernized the code. 2720 2721 2722Earlier History 2723--------------- 2724 27252001-12-04 GDR Created. 2726 27272001-12-06 GDR Added command-line interface and source code annotation. 2728 27292001-12-09 GDR Moved design and interface to separate documents. 2730 27312001-12-10 GDR Open cache file as binary on Windows. Allow simultaneous -e and 2732-x, or -a and -r. 2733 27342001-12-12 GDR Added command-line help. Cache analysis so that it only needs to 2735be done once when you specify -a and -r. 2736 27372001-12-13 GDR Improved speed while recording. Portable between Python 1.5.2 2738and 2.1.1. 2739 27402002-01-03 GDR Module-level functions work correctly. 2741 27422002-01-07 GDR Update sys.path when running a file with the -x option, so that 2743it matches the value the program would get if it were run on its own. 2744