diff --git a/.github/codecov.yml b/.github/codecov.yml new file mode 100644 index 000000000..167a6c11a --- /dev/null +++ b/.github/codecov.yml @@ -0,0 +1,17 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +coverage: + status: + # Codecov shouldn't put red x's on pull requests + # https://docs.codecov.io/docs/common-recipe-list#set-non-blocking-status-checks + project: + default: + informational: true + patch: + default: + informational: true + +comment: + layout: diff, files + behavior: new diff --git a/.github/workflows/cancel.yml b/.github/workflows/cancel.yml new file mode 100644 index 000000000..a0da0a1ea --- /dev/null +++ b/.github/workflows/cancel.yml @@ -0,0 +1,20 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +# This action finds in-progress Action jobs for the same branch, and cancels +# them. There's little point in continuing to run superceded jobs. + +name: Cancel + +on: + push: + +jobs: + cancel: + runs-on: ubuntu-latest + steps: + - name: Cancel Previous Runs + uses: styfle/cancel-workflow-action@0.6.0 + with: + access_token: ${{ github.token }} + workflow_id: coverage.yml, kit.yml, quality.yml, testsuite.yml diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml new file mode 100644 index 000000000..ad5a21cf8 --- /dev/null +++ b/.github/workflows/coverage.yml @@ -0,0 +1,99 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +name: "Coverage" + +on: + push: + branches: ["master"] + pull_request: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + coverage: + name: "Python ${{ matrix.python-version }}" + runs-on: ubuntu-latest + + strategy: + matrix: + python-version: + - "2.7" + - "3.5" + - "3.9" + - "pypy3" + fail-fast: false + + steps: + - name: "Check out the repo" + uses: "actions/checkout@v2" + + - name: "Set up Python" + uses: "actions/setup-python@v2" + with: + python-version: "${{ matrix.python-version }}" + + - name: "Install dependencies" + run: | + set -xe + python -VV + python -m site + python -m pip install -r requirements/ci.pip + python -m pip install -c requirements/pins.pip tox-gh-actions + + - name: "Run tox coverage for ${{ matrix.python-version }}" + env: + COVERAGE_COVERAGE: "yes" + run: | + set -xe + python -m tox + python -m igor combine_html + mv .metacov .coverage.${{ matrix.python-version }} + + - name: "Upload coverage data" + uses: actions/upload-artifact@v2 + with: + name: metacov + path: .coverage.* + + combine: + name: "Combine coverage data" + needs: coverage + runs-on: ubuntu-latest + + steps: + - name: "Check out the repo" + uses: "actions/checkout@v2" + + - name: "Set up Python" + uses: "actions/setup-python@v2" + with: + python-version: "3.9" + + - name: "Install dependencies" + run: | + set -xe + python -VV + python -m site + python -m pip install -r requirements/ci.pip + python setup.py --quiet clean develop + python igor.py zip_mods install_egg + + - name: "Download coverage data" + uses: actions/download-artifact@v2 + with: + name: metacov + + - name: "Combine and report" + run: | + set -xe + coverage combine + coverage xml + + - name: "Upload to codecov" + uses: codecov/codecov-action@v1 + with: + file: coverage.xml diff --git a/.github/workflows/kit.yml b/.github/workflows/kit.yml new file mode 100644 index 000000000..437e7d31b --- /dev/null +++ b/.github/workflows/kit.yml @@ -0,0 +1,103 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +# Based on: +# https://github.com/joerick/cibuildwheel/blob/master/examples/github-deploy.yml + +name: Build kits + +on: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + build_wheels: + name: Build wheels on ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, windows-latest, macos-latest] + fail-fast: false + + steps: + - name: Check out the repo + uses: actions/checkout@v2 + + - name: Install Python 3.7 + uses: actions/setup-python@v2 + with: + python-version: "3.7" + + - name: Install cibuildwheel + run: | + python -m pip install -c requirements/pins.pip cibuildwheel + + - name: Install Visual C++ for Python 2.7 + if: runner.os == 'Windows' + run: | + choco install vcpython27 -f -y + + - name: Build wheels + env: + # Don't build wheels for PyPy. + CIBW_SKIP: pp* + run: | + python -m cibuildwheel --output-dir wheelhouse + + - name: Upload wheels + uses: actions/upload-artifact@v2 + with: + name: dist + path: ./wheelhouse/*.whl + + build_sdist: + name: Build source distribution + runs-on: ubuntu-latest + steps: + - name: Check out the repo + uses: actions/checkout@v2 + + - name: Install Python 3.7 + uses: actions/setup-python@v2 + with: + python-version: "3.7" + + - name: Build sdist + run: | + python setup.py sdist + + - name: Upload sdist + uses: actions/upload-artifact@v2 + with: + name: dist + path: dist/*.tar.gz + + build_pypy: + name: Build PyPy wheels + runs-on: ubuntu-latest + steps: + - name: Check out the repo + uses: actions/checkout@v2 + + - name: Install PyPy + uses: actions/setup-python@v2 + with: + python-version: "pypy3" + + - name: Install requirements + run: | + pypy3 -m pip install -r requirements/wheel.pip + + - name: Build wheels + run: | + pypy3 setup.py bdist_wheel --python-tag pp36 + pypy3 setup.py bdist_wheel --python-tag pp37 + + - name: Upload wheels + uses: actions/upload-artifact@v2 + with: + name: dist + path: dist/*.whl diff --git a/.github/workflows/quality.yml b/.github/workflows/quality.yml new file mode 100644 index 000000000..ad45b2eef --- /dev/null +++ b/.github/workflows/quality.yml @@ -0,0 +1,63 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +name: "Quality checks" + +on: + push: + branches: ["master"] + pull_request: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + lint: + name: Pylint etc + runs-on: ubuntu-latest + + steps: + - name: "Check out the repo" + uses: "actions/checkout@v2" + + - name: "Install Python" + uses: "actions/setup-python@v2" + with: + python-version: "3.8" + + - name: "Install dependencies" + run: | + set -xe + python -VV + python -m site + python -m pip install -r requirements/tox.pip + + - name: "Tox lint" + run: | + python -m tox -e lint + + doc: + name: Build docs + runs-on: ubuntu-latest + + steps: + - name: "Check out the repo" + uses: "actions/checkout@v2" + + - name: "Install Python" + uses: "actions/setup-python@v2" + with: + python-version: "3.8" + + - name: "Install dependencies" + run: | + set -xe + python -VV + python -m site + python -m pip install -r requirements/tox.pip + + - name: "Tox doc" + run: | + python -m tox -e doc diff --git a/.github/workflows/testsuite.yml b/.github/workflows/testsuite.yml new file mode 100644 index 000000000..59f5380b2 --- /dev/null +++ b/.github/workflows/testsuite.yml @@ -0,0 +1,77 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +name: "Test Suite" + +on: + push: + branches: ["master"] + pull_request: + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + tests: + name: "Python ${{ matrix.python-version }} on ${{ matrix.os }}" + runs-on: "${{ matrix.os }}" + + strategy: + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + python-version: + - "2.7" + - "3.5" + - "3.6" + - "3.7" + - "3.8" + - "3.9" + - "pypy3" + exclude: + # Windows PyPy doesn't seem to work? + - os: windows-latest + python-version: "pypy3" + fail-fast: false + + steps: + - name: "Check out the repo" + uses: "actions/checkout@v2" + + - name: "Set up Python" + uses: "actions/setup-python@v2" + with: + python-version: "${{ matrix.python-version }}" + + - name: "Install Visual C++ if needed" + if: runner.os == 'Windows' && matrix.python-version == '2.7' + run: | + choco install vcpython27 -f -y + + - name: "Install dependencies" + run: | + set -xe + python -VV + python -m site + python -m pip install -r requirements/ci.pip + python -m pip install -c requirements/pins.pip tox-gh-actions + + - name: "Run tox for ${{ matrix.python-version }}" + continue-on-error: true + id: tox1 + run: | + python -m tox + + - name: "Retry tox for ${{ matrix.python-version }}" + id: tox2 + if: steps.tox1.outcome == 'failure' + run: | + python -m tox + + - name: "Set status" + if: always() + run: | + if ${{ steps.tox1.outcome != 'success' && steps.tox2.outcome != 'success' }}; then + exit 1 + fi diff --git a/.readthedocs.yml b/.readthedocs.yml index ed3737fbe..8c96c02fd 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -10,8 +10,11 @@ sphinx: builder: html configuration: doc/conf.py -# No other formats than HTML -formats: [] +# Build all the formats +formats: + - epub + - htmlzip + - pdf python: version: 3.7 diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index f5e8fad19..000000000 --- a/.travis.yml +++ /dev/null @@ -1,52 +0,0 @@ -# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 -# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt -# -# Tell Travis what to do -# https://travis-ci.com/nedbat/coveragepy - -dist: xenial -language: python - -cache: pip - -python: - - '2.7' - - '3.5' - - '3.6' - - '3.7' - - '3.8' - - 'pypy2.7-6.0' - - 'pypy3.5-6.0' - -# Only testing it for python3.8 on aarch64 platform, since it already has a lot -# of jobs to test and takes long time. -matrix: - include: - - python: 3.8 - arch: arm64 - env: - - COVERAGE_COVERAGE=no - - python: 3.8 - arch: arm64 - env: - - COVERAGE_COVERAGE=yes - -env: - matrix: - - COVERAGE_COVERAGE=no - - COVERAGE_COVERAGE=yes - -install: - - pip install -r requirements/ci.pip - - pip freeze - -script: - - tox - -after_script: - - | - if [[ $COVERAGE_COVERAGE == 'yes' ]]; then - python igor.py combine_html - pip install codecov - codecov -X gcov --file coverage.xml - fi diff --git a/CHANGES.rst b/CHANGES.rst index 5819a4010..a4f13ff05 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -21,6 +21,31 @@ want to know what's different in 5.0 since 4.5.x, see :ref:`whatsnew5x`. .. Version 9.8.1 --- 2027-07-27 .. ---------------------------- +.. _changes_531: + +Version 5.3.1 --- 2020-12-19 +---------------------------- + +- When using ``--source`` on a large source tree, v5.x was slower than previous + versions. This performance regression is now fixed, closing `issue 1037`_. + +- Mysterious SQLite errors can happen on PyPy, as reported in `issue 1010`_. An + immediate retry seems to fix the problem, although it is an unsatisfying + solution. + +- The HTML report now saves the sort order in a more widely supported way, + fixing `issue 986`_. Thanks, Sebastián Ramírez (`pull request 1066`_). + +- The HTML report pages now have a :ref:`Sleepy Snake ` favicon. + +- Wheels are now provided for manylinux2010, and for PyPy3 (pp36 and pp37). + +- Continuous integration has moved from Travis and AppVeyor to GitHub Actions. + +.. _issue 986: https://github.com/nedbat/coveragepy/issues/986 +.. _issue 1037: https://github.com/nedbat/coveragepy/issues/1037 +.. _issue 1010: https://github.com/nedbat/coveragepy/issues/1010 +.. _pull request 1066: https://github.com/nedbat/coveragepy/pull/1066 .. _changes_53: diff --git a/CONTRIBUTORS.txt b/CONTRIBUTORS.txt index 7af8202b7..3e52e45e9 100644 --- a/CONTRIBUTORS.txt +++ b/CONTRIBUTORS.txt @@ -120,6 +120,7 @@ Roy Williams Salvatore Zagaria Sandra Martocchia Scott Belden +Sebastián Ramírez Sigve Tjora Simon Willison Stan Hu diff --git a/MANIFEST.in b/MANIFEST.in index 75257c606..60da201de 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -16,8 +16,6 @@ include Makefile include NOTICE.txt include README.rst include __main__.py -include .travis.yml -include appveyor.yml include howto.txt include igor.py include metacov.ini @@ -31,6 +29,8 @@ include .readthedocs.yml recursive-include ci * exclude ci/*.token +recursive-include .github * + recursive-include coverage/fullcoverage *.py recursive-include coverage/ctracer *.c *.h diff --git a/Makefile b/Makefile index a72f9ee61..ec1a5aa81 100644 --- a/Makefile +++ b/Makefile @@ -35,7 +35,6 @@ clean: clean_platform ## Remove artifacts of test execution, i sterile: clean ## Remove all non-controlled content, even if expensive. rm -rf .tox - -docker image rm -f quay.io/pypa/manylinux1_i686 quay.io/pypa/manylinux1_x86_64 CSS = coverage/htmlfiles/style.css @@ -68,20 +67,6 @@ smoke: ## Run tests quickly with the C tracer in the lowest supported Pytho pysmoke: ## Run tests quickly with the Python tracer in the lowest supported Python versions. COVERAGE_NO_CTRACER=1 tox -q -e py27,py35 -- $(PYTEST_SMOKE_ARGS) -DOCKER_RUN = docker run -it --init --rm -v `pwd`:/io -RUN_MANYLINUX_X86 = $(DOCKER_RUN) quay.io/pypa/manylinux1_x86_64 /io/ci/manylinux.sh -RUN_MANYLINUX_I686 = $(DOCKER_RUN) quay.io/pypa/manylinux1_i686 /io/ci/manylinux.sh - -test_linux: ## Run the tests in Linux under Docker. - # The Linux .pyc files clash with the host's because of file path - # changes, so clean them before and after running tests. - make clean_platform - $(RUN_MANYLINUX_X86) test $(ARGS) - make clean_platform - -meta_linux: ## Run meta-coverage in Linux under Docker. - ARGS="meta $(ARGS)" make test_linux - # Coverage measurement of coverage.py itself (meta-coverage). See metacov.ini # for details. @@ -96,13 +81,6 @@ metahtml: ## Produce meta-coverage HTML reports. kit: ## Make the source distribution. python setup.py sdist -wheel: ## Make the wheels for distribution. - tox -c tox_wheels.ini $(ARGS) - -kit_linux: ## Make the Linux wheels. - $(RUN_MANYLINUX_X86) build - $(RUN_MANYLINUX_I686) build - kit_upload: ## Upload the built distributions to PyPI. twine upload --verbose dist/* @@ -118,8 +96,8 @@ kit_local: # don't go crazy trying to figure out why our new code isn't installing. find ~/Library/Caches/pip/wheels -name 'coverage-*' -delete -download_appveyor: ## Download the latest Windows artifacts from AppVeyor. - python ci/download_appveyor.py nedbat/coveragepy +download_kits: ## Download the built kits from GitHub + python ci/download_gha_artifacts.py build_ext: python setup.py build_ext diff --git a/README.rst b/README.rst index babda472c..7708e9c6c 100644 --- a/README.rst +++ b/README.rst @@ -8,7 +8,7 @@ Coverage.py Code coverage testing for Python. | |license| |versions| |status| -| |ci-status| |win-ci-status| |docs| |codecov| +| |ci-status| |docs| |codecov| | |kit| |format| |repos| |downloads| | |stars| |forks| |contributors| | |tidelift| |twitter-coveragepy| |twitter-nedbat| @@ -20,7 +20,7 @@ library to determine which lines are executable, and which have been executed. Coverage.py runs on many versions of Python: * CPython 2.7. -* CPython 3.5 through 3.9 beta. +* CPython 3.5 through 3.10 alpha. * PyPy2 7.3.1 and PyPy3 7.3.1. Documentation is on `Read the Docs`_. Code repository and issue tracker are on @@ -95,12 +95,9 @@ Licensed under the `Apache 2.0 License`_. For details, see `NOTICE.txt`_. .. _NOTICE.txt: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt -.. |ci-status| image:: https://travis-ci.com/nedbat/coveragepy.svg?branch=master - :target: https://travis-ci.com/nedbat/coveragepy +.. |ci-status| image:: https://github.com/nedbat/coveragepy/workflows/Test%20Suite/badge.svg + :target: https://github.com/nedbat/coveragepy/actions?query=workflow%3A%22Test+Suite%22 :alt: Build status -.. |win-ci-status| image:: https://ci.appveyor.com/api/projects/status/kmeqpdje7h9r6vsf/branch/master?svg=true - :target: https://ci.appveyor.com/project/nedbat/coveragepy - :alt: Windows build status .. |docs| image:: https://readthedocs.org/projects/coverage/badge/?version=latest&style=flat :target: https://coverage.readthedocs.io/ :alt: Documentation diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 6baccd81f..000000000 --- a/appveyor.yml +++ /dev/null @@ -1,167 +0,0 @@ -# Appveyor, continuous integration for Windows -# https://ci.appveyor.com/project/nedbat/coveragepy - -version: '{branch}-{build}' - -shallow_clone: true - -cache: - - '%LOCALAPPDATA%\pip\Cache' - -environment: - - CMD_IN_ENV: "cmd /E:ON /V:ON /C .\\ci\\run_with_env.cmd" - - PYTEST_ADDOPTS: "-n auto" - - # Note: There is logic to install Python version $PYTHON_VERSION if the - # $PYTHON directory doesn't exist. $PYTHON_VERSION is visible in the job - # descriptions, but can be wrong in the minor version, since we use the - # version pre-installed on AppVeyor. - # - matrix: - - JOB: "2.7 64-bit" - TOXENV: "py27" - PYTHON: "C:\\Python27-x64" - PYTHON_VERSION: "2.7.18" - PYTHON_ARCH: "64" - - - JOB: "3.5 64-bit" - TOXENV: "py35" - PYTHON: "C:\\Python35-x64" - PYTHON_VERSION: "3.5.9" - PYTHON_ARCH: "64" - - - JOB: "3.6 64-bit" - TOXENV: "py36" - PYTHON: "C:\\Python36-x64" - PYTHON_VERSION: "3.6.11" - PYTHON_ARCH: "64" - - - JOB: "3.7 64-bit" - TOXENV: "py37" - PYTHON: "C:\\Python37-x64" - PYTHON_VERSION: "3.7.8" - PYTHON_ARCH: "64" - - - JOB: "3.8 64-bit" - TOXENV: "py38" - PYTHON: "C:\\Python38-x64" - PYTHON_VERSION: "3.8.5" - PYTHON_ARCH: "64" - - - JOB: "3.9 64-bit" - TOXENV: "py39" - PYTHON: "C:\\Python39-x64" - PYTHON_VERSION: "3.9.0b5" - PYTHON_ARCH: "64" - - # 32-bit jobs don't run the tests under the Python tracer, since that should - # be exactly the same as 64-bit. - - JOB: "2.7 32-bit" - TOXENV: "py27" - PYTHON: "C:\\Python27" - PYTHON_VERSION: "2.7.18" - PYTHON_ARCH: "32" - COVERAGE_NO_PYTRACER: "1" - - - JOB: "3.5 32-bit" - TOXENV: "py35" - PYTHON: "C:\\Python35" - PYTHON_VERSION: "3.5.9" - PYTHON_ARCH: "32" - COVERAGE_NO_PYTRACER: "1" - - - JOB: "3.6 32-bit" - TOXENV: "py36" - PYTHON: "C:\\Python36" - PYTHON_VERSION: "3.6.11" - PYTHON_ARCH: "32" - COVERAGE_NO_PYTRACER: "1" - - - JOB: "3.7 32-bit" - TOXENV: "py37" - PYTHON: "C:\\Python37" - PYTHON_VERSION: "3.7.8" - PYTHON_ARCH: "32" - COVERAGE_NO_PYTRACER: "1" - - - JOB: "3.8 32-bit" - TOXENV: "py38" - PYTHON: "C:\\Python38" - PYTHON_VERSION: "3.8.5" - PYTHON_ARCH: "32" - COVERAGE_NO_PYTRACER: "1" - - - JOB: "3.9 32-bit" - TOXENV: "py39" - PYTHON: "C:\\Python39" - PYTHON_VERSION: "3.9.0b5" - PYTHON_ARCH: "32" - COVERAGE_NO_PYTRACER: "1" - - # Meta coverage - - JOB: "Meta 2.7" - TOXENV: "py27" - PYTHON: "C:\\Python27" - PYTHON_VERSION: "2.7.18" - PYTHON_ARCH: "32" - COVERAGE_COVERAGE: "yes" - - - JOB: "Meta 3.6" - TOXENV: "py36" - PYTHON: "C:\\Python36" - PYTHON_VERSION: "3.6.11" - PYTHON_ARCH: "32" - COVERAGE_COVERAGE: "yes" - -init: - - "ECHO %TOXENV%" - -install: - # Install Python (from the official .msi of http://python.org) and pip when - # not already installed. - - ps: if (-not(Test-Path($env:PYTHON))) { & ci\install.ps1 } - - # Prepend newly installed Python to the PATH of this build (this cannot be - # done from inside the powershell script as it would require to restart - # the parent CMD process). - - "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%" - - # Check that we have the expected version and architecture for Python - - "python -c \"import struct, sys; print('{}\\n{}-bit'.format(sys.version, struct.calcsize('P') * 8))\"" - - # Upgrade to the right version of pip to avoid it displaying warnings - # about it being out of date. - - "python -m pip install --disable-pip-version-check -r requirements/pip.pip" - - # Install requirements. - - "%CMD_IN_ENV% pip install -r requirements/ci.pip" - - # Make a pythonX.Y.bat file in the current directory so that tox will find it - # and pythonX.Y will mean what we want it to. - - "python -c \"import os; open('python{}.{}.bat'.format(*os.environ['TOXENV'][2:]), 'w').write('@{}\\\\python \\x25*\\n'.format(os.environ['PYTHON']))\"" - -build_script: - # If not a metacov job, then build wheel installers. - - if NOT "%COVERAGE_COVERAGE%" == "yes" %CMD_IN_ENV% %PYTHON%\python setup.py bdist_wheel - - # Push everything in dist\ as an artifact. - - ps: if ( Test-Path 'dist' -PathType Container ) { Get-ChildItem dist\*.* | % { Push-AppveyorArtifact $_.FullName -FileName ('dist\' + $_.Name) } } - -test_script: - - "%CMD_IN_ENV% %PYTHON%\\Scripts\\tox" - -after_test: - - if "%COVERAGE_COVERAGE%" == "yes" 7z a metacov-win-%TOXENV%.zip %APPVEYOR_BUILD_FOLDER%\.metacov* - - if "%COVERAGE_COVERAGE%" == "yes" %CMD_IN_ENV% %PYTHON%\python igor.py combine_html - - if "%COVERAGE_COVERAGE%" == "yes" %CMD_IN_ENV% pip install codecov - - if "%COVERAGE_COVERAGE%" == "yes" %CMD_IN_ENV% codecov -X gcov --file coverage.xml - -# Uncomment this to enable RDP access to the build when done. -# https://www.appveyor.com/docs/how-to/rdp-to-build-worker/ -# on_finish: -# - ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1')) - -artifacts: - - path: "metacov-*.zip" diff --git a/ci/download_appveyor.py b/ci/download_appveyor.py deleted file mode 100644 index a3d814962..000000000 --- a/ci/download_appveyor.py +++ /dev/null @@ -1,95 +0,0 @@ -# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 -# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt - -"""Use the Appveyor API to download Windows artifacts.""" - -import os -import os.path -import sys -import zipfile - -import requests - - -def make_auth_headers(): - """Make the authentication headers needed to use the Appveyor API.""" - with open("ci/appveyor.token") as f: - token = f.read().strip() - - headers = { - 'Authorization': 'Bearer {}'.format(token), - } - return headers - - -def make_url(url, **kwargs): - """Build an Appveyor API url.""" - return "https://ci.appveyor.com/api" + url.format(**kwargs) - - -def get_project_build(account_project): - """Get the details of the latest Appveyor build.""" - url = make_url("/projects/{account_project}", account_project=account_project) - response = requests.get(url, headers=make_auth_headers()) - return response.json() - - -def download_latest_artifacts(account_project): - """Download all the artifacts from the latest build.""" - build = get_project_build(account_project) - jobs = build['build']['jobs'] - print("Build {0[build][version]}, {1} jobs: {0[build][message]}".format(build, len(jobs))) - for job in jobs: - name = job['name'].partition(':')[2].split(',')[0].strip() - print(" {0}: {1[status]}, {1[artifactsCount]} artifacts".format(name, job)) - - url = make_url("/buildjobs/{jobid}/artifacts", jobid=job['jobId']) - response = requests.get(url, headers=make_auth_headers()) - artifacts = response.json() - - for artifact in artifacts: - is_zip = artifact['type'] == "Zip" - filename = artifact['fileName'] - print(" {}, {} bytes".format(filename, artifact['size'])) - - url = make_url( - "/buildjobs/{jobid}/artifacts/{filename}", - jobid=job['jobId'], - filename=filename - ) - download_url(url, filename, make_auth_headers()) - - if is_zip: - unpack_zipfile(filename) - os.remove(filename) - - -def ensure_dirs(filename): - """Make sure the directories exist for `filename`.""" - dirname, _ = os.path.split(filename) - if dirname and not os.path.exists(dirname): - os.makedirs(dirname) - - -def download_url(url, filename, headers): - """Download a file from `url` to `filename`.""" - ensure_dirs(filename) - response = requests.get(url, headers=headers, stream=True) - if response.status_code == 200: - with open(filename, 'wb') as f: - for chunk in response.iter_content(16*1024): - f.write(chunk) - - -def unpack_zipfile(filename): - """Unpack a zipfile, using the names in the zip.""" - with open(filename, 'rb') as fzip: - z = zipfile.ZipFile(fzip) - for name in z.namelist(): - print(" extracting {}".format(name)) - ensure_dirs(name) - z.extract(name) - - -if __name__ == "__main__": - download_latest_artifacts(sys.argv[1]) diff --git a/ci/download_gha_artifacts.py b/ci/download_gha_artifacts.py new file mode 100644 index 000000000..ed0bbe259 --- /dev/null +++ b/ci/download_gha_artifacts.py @@ -0,0 +1,60 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +"""Use the GitHub API to download built artifacts.""" + +import datetime +import os +import os.path +import time +import zipfile + +import requests + +def download_url(url, filename): + """Download a file from `url` to `filename`.""" + response = requests.get(url, stream=True) + if response.status_code == 200: + with open(filename, "wb") as f: + for chunk in response.iter_content(16*1024): + f.write(chunk) + +def unpack_zipfile(filename): + """Unpack a zipfile, using the names in the zip.""" + with open(filename, "rb") as fzip: + z = zipfile.ZipFile(fzip) + for name in z.namelist(): + print(f" extracting {name}") + z.extract(name) + +def utc2local(timestring): + """Convert a UTC time into local time in a more readable form. + + For example: '20201208T122900Z' to '2020-12-08 07:29:00'. + + """ + dt = datetime.datetime + utc = dt.fromisoformat(timestring.rstrip("Z")) + epoch = time.mktime(utc.timetuple()) + offset = dt.fromtimestamp(epoch) - dt.utcfromtimestamp(epoch) + local = utc + offset + return local.strftime("%Y-%m-%d %H:%M:%S") + +dest = "dist" +repo_owner = "nedbat/coveragepy" +temp_zip = "artifacts.zip" + +if not os.path.exists(dest): + os.makedirs(dest) +os.chdir(dest) + +r = requests.get(f"https://api.github.com/repos/{repo_owner}/actions/artifacts") +dists = [a for a in r.json()["artifacts"] if a["name"] == "dist"] +if not dists: + print("No recent dists!") +else: + latest = max(dists, key=lambda a: a["created_at"]) + print(f"Artifacts created at {utc2local(latest['created_at'])}") + download_url(latest["archive_download_url"], temp_zip) + unpack_zipfile(temp_zip) + os.remove(temp_zip) diff --git a/ci/install.ps1 b/ci/install.ps1 deleted file mode 100644 index fd5ab2202..000000000 --- a/ci/install.ps1 +++ /dev/null @@ -1,203 +0,0 @@ -# From: https://github.com/ogrisel/python-appveyor-demo/blob/master/appveyor/install.ps1 -# -# -# Sample script to install Python and pip under Windows -# Authors: Olivier Grisel, Jonathan Helmus, Kyle Kastner, and Alex Willmer -# License: CC0 1.0 Universal: http://creativecommons.org/publicdomain/zero/1.0/ - -$MINICONDA_URL = "http://repo.continuum.io/miniconda/" -$BASE_URL = "https://www.python.org/ftp/python/" -$GET_PIP_URL = "https://bootstrap.pypa.io/get-pip.py" -$GET_PIP_PATH = "C:\get-pip.py" - -$PYTHON_PRERELEASE_REGEX = @" -(?x) -(?\d+) -\. -(?\d+) -\. -(?\d+) -(?[a-z]{1,2}\d+) -"@ - - -function Download ($filename, $url) { - $webclient = New-Object System.Net.WebClient - - $basedir = $pwd.Path + "\" - $filepath = $basedir + $filename - if (Test-Path $filename) { - Write-Host "Reusing" $filepath - return $filepath - } - - # Download and retry up to 3 times in case of network transient errors. - Write-Host "Downloading" $filename "from" $url - $retry_attempts = 2 - for ($i = 0; $i -lt $retry_attempts; $i++) { - try { - $webclient.DownloadFile($url, $filepath) - break - } - Catch [Exception]{ - Start-Sleep 1 - } - } - if (Test-Path $filepath) { - Write-Host "File saved at" $filepath - } else { - # Retry once to get the error message if any at the last try - $webclient.DownloadFile($url, $filepath) - } - return $filepath -} - - -function ParsePythonVersion ($python_version) { - if ($python_version -match $PYTHON_PRERELEASE_REGEX) { - return ([int]$matches.major, [int]$matches.minor, [int]$matches.micro, - $matches.prerelease) - } - $version_obj = [version]$python_version - return ($version_obj.major, $version_obj.minor, $version_obj.build, "") -} - - -function DownloadPython ($python_version, $platform_suffix) { - $major, $minor, $micro, $prerelease = ParsePythonVersion $python_version - - $dir = "$major.$minor.$micro" - $ext = "exe" - if ($platform_suffix) { - $platform_suffix = "-$platform_suffix" - } - - $filename = "python-$python_version$platform_suffix.$ext" - $url = "$BASE_URL$dir/$filename" - $filepath = Download $filename $url - return $filepath -} - - -function InstallPython ($python_version, $architecture, $python_home) { - Write-Host "Installing Python" $python_version "for" $architecture "bit architecture to" $python_home - if (Test-Path $python_home) { - Write-Host $python_home "already exists, skipping." - return $false - } - if ($architecture -eq "32") { - $platform_suffix = "" - } else { - $platform_suffix = "amd64" - } - $installer_path = DownloadPython $python_version $platform_suffix - $installer_ext = [System.IO.Path]::GetExtension($installer_path) - Write-Host "Installing $installer_path to $python_home" - $install_log = $python_home + ".log" - if ($installer_ext -eq '.msi') { - InstallPythonMSI $installer_path $python_home $install_log - } else { - InstallPythonEXE $installer_path $python_home $install_log - } - if (Test-Path $python_home) { - Write-Host "Python $python_version ($architecture) installation complete" - } else { - Write-Host "Failed to install Python in $python_home" - Get-Content -Path $install_log - Exit 1 - } -} - - -function InstallPythonEXE ($exepath, $python_home, $install_log) { - $install_args = "/quiet InstallAllUsers=1 TargetDir=$python_home" - RunCommand $exepath $install_args -} - - -function InstallPythonMSI ($msipath, $python_home, $install_log) { - $install_args = "/qn /log $install_log /i $msipath TARGETDIR=$python_home" - $uninstall_args = "/qn /x $msipath" - RunCommand "msiexec.exe" $install_args - if (-not(Test-Path $python_home)) { - Write-Host "Python seems to be installed else-where, reinstalling." - RunCommand "msiexec.exe" $uninstall_args - RunCommand "msiexec.exe" $install_args - } -} - -function RunCommand ($command, $command_args) { - Write-Host $command $command_args - Start-Process -FilePath $command -ArgumentList $command_args -Wait -Passthru -} - - -function InstallPip ($python_home) { - $pip_path = $python_home + "\Scripts\pip.exe" - $python_path = $python_home + "\python.exe" - if (-not(Test-Path $pip_path)) { - Write-Host "Installing pip..." - $webclient = New-Object System.Net.WebClient - $webclient.DownloadFile($GET_PIP_URL, $GET_PIP_PATH) - Write-Host "Executing:" $python_path $GET_PIP_PATH - & $python_path $GET_PIP_PATH - } else { - Write-Host "pip already installed." - } -} - - -function DownloadMiniconda ($python_version, $platform_suffix) { - $filename = "Miniconda-3.5.5-Windows-" + $platform_suffix + ".exe" - $url = $MINICONDA_URL + $filename - $filepath = Download $filename $url - return $filepath -} - - -function InstallMiniconda ($python_version, $architecture, $python_home) { - Write-Host "Installing Python" $python_version "for" $architecture "bit architecture to" $python_home - if (Test-Path $python_home) { - Write-Host $python_home "already exists, skipping." - return $false - } - if ($architecture -eq "32") { - $platform_suffix = "x86" - } else { - $platform_suffix = "x86_64" - } - $filepath = DownloadMiniconda $python_version $platform_suffix - Write-Host "Installing" $filepath "to" $python_home - $install_log = $python_home + ".log" - $args = "/S /D=$python_home" - Write-Host $filepath $args - Start-Process -FilePath $filepath -ArgumentList $args -Wait -Passthru - if (Test-Path $python_home) { - Write-Host "Python $python_version ($architecture) installation complete" - } else { - Write-Host "Failed to install Python in $python_home" - Get-Content -Path $install_log - Exit 1 - } -} - - -function InstallMinicondaPip ($python_home) { - $pip_path = $python_home + "\Scripts\pip.exe" - $conda_path = $python_home + "\Scripts\conda.exe" - if (-not(Test-Path $pip_path)) { - Write-Host "Installing pip..." - $args = "install --yes pip" - Write-Host $conda_path $args - Start-Process -FilePath "$conda_path" -ArgumentList $args -Wait -Passthru - } else { - Write-Host "pip already installed." - } -} - -function main () { - InstallPython $env:PYTHON_VERSION $env:PYTHON_ARCH $env:PYTHON - InstallPip $env:PYTHON -} - -main diff --git a/ci/manylinux.sh b/ci/manylinux.sh deleted file mode 100755 index 1fafec9de..000000000 --- a/ci/manylinux.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/bin/bash -# From: https://github.com/pypa/python-manylinux-demo/blob/master/travis/build-wheels.sh -# which is in the public domain. -# -# This is run inside a CentOS 5 virtual machine to build manylinux wheels: -# -# $ docker run -v `pwd`:/io quay.io/pypa/manylinux1_x86_64 /io/ci/build_manylinux.sh -# - -set -e -x - -action=$1 -shift - -if [[ $action == "build" ]]; then - # Compile wheels - cd /io - for PYBIN in /opt/python/*/bin; do - if [[ $PYBIN == *cp34* ]]; then - # manylinux docker images have Python 3.4, but we don't use it. - continue - fi - "$PYBIN/pip" install -r requirements/wheel.pip - "$PYBIN/python" setup.py clean -a - "$PYBIN/python" setup.py bdist_wheel -d ~/wheelhouse/ - done - cd ~ - - # Bundle external shared libraries into the wheels - for whl in wheelhouse/*.whl; do - auditwheel repair "$whl" -w /io/dist/ - done - -elif [[ $action == "test" ]]; then - # Create "pythonX.Y" links - for PYBIN in /opt/python/*/bin/; do - if [[ $PYBIN == *cp34* ]]; then - # manylinux docker images have Python 3.4, but we don't use it. - continue - fi - PYNAME=$("$PYBIN/python" -c "import sys; print('python{0[0]}.{0[1]}'.format(sys.version_info))") - ln -sf "$PYBIN/$PYNAME" /usr/local/bin/$PYNAME - done - - # Install packages and test - TOXBIN=/opt/python/cp36-cp36m/bin - "$TOXBIN/pip" install -r /io/requirements/tox.pip - - cd /io - export PYTHONPYCACHEPREFIX=/opt/pyc - if [[ $1 == "meta" ]]; then - shift - export COVERAGE_COVERAGE=yes - fi - TOXWORKDIR=.tox/linux "$TOXBIN/tox" "$@" || true - cd ~ - -else - echo "Need an action to perform!" -fi diff --git a/ci/run_with_env.cmd b/ci/run_with_env.cmd deleted file mode 100644 index 66b9252ef..000000000 --- a/ci/run_with_env.cmd +++ /dev/null @@ -1,91 +0,0 @@ -:: From: https://github.com/ogrisel/python-appveyor-demo/blob/master/appveyor/run_with_env.cmd -:: -:: -:: To build extensions for 64 bit Python 3, we need to configure environment -:: variables to use the MSVC 2010 C++ compilers from GRMSDKX_EN_DVD.iso of: -:: MS Windows SDK for Windows 7 and .NET Framework 4 (SDK v7.1) -:: -:: To build extensions for 64 bit Python 2, we need to configure environment -:: variables to use the MSVC 2008 C++ compilers from GRMSDKX_EN_DVD.iso of: -:: MS Windows SDK for Windows 7 and .NET Framework 3.5 (SDK v7.0) -:: -:: 32 bit builds, and 64-bit builds for 3.5 and beyond, do not require specific -:: environment configurations. -:: -:: Note: this script needs to be run with the /E:ON and /V:ON flags for the -:: cmd interpreter, at least for (SDK v7.0) -:: -:: More details at: -:: https://github.com/cython/cython/wiki/64BitCythonExtensionsOnWindows -:: http://stackoverflow.com/a/13751649/163740 -:: -:: Author: Olivier Grisel -:: License: CC0 1.0 Universal: http://creativecommons.org/publicdomain/zero/1.0/ -:: -:: Notes about batch files for Python people: -:: -:: Quotes in values are literally part of the values: -:: SET FOO="bar" -:: FOO is now five characters long: " b a r " -:: If you don't want quotes, don't include them on the right-hand side. -:: -:: The CALL lines at the end of this file look redundant, but if you move them -:: outside of the IF clauses, they do not run properly in the SET_SDK_64==Y -:: case, I don't know why. -@ECHO OFF - -SET COMMAND_TO_RUN=%* -SET WIN_SDK_ROOT=C:\Program Files\Microsoft SDKs\Windows -SET WIN_WDK=c:\Program Files (x86)\Windows Kits\10\Include\wdf - -:: Extract the major and minor versions, and allow for the minor version to be -:: more than 9. This requires the version number to have two dots in it. -SET MAJOR_PYTHON_VERSION=%PYTHON_VERSION:~0,1% -IF "%PYTHON_VERSION:~3,1%" == "." ( - SET MINOR_PYTHON_VERSION=%PYTHON_VERSION:~2,1% -) ELSE ( - SET MINOR_PYTHON_VERSION=%PYTHON_VERSION:~2,2% -) - -:: Based on the Python version, determine what SDK version to use, and whether -:: to set the SDK for 64-bit. -IF %MAJOR_PYTHON_VERSION% == 2 ( - SET WINDOWS_SDK_VERSION="v7.0" - SET SET_SDK_64=Y -) ELSE ( - IF %MAJOR_PYTHON_VERSION% == 3 ( - SET WINDOWS_SDK_VERSION="v7.1" - IF %MINOR_PYTHON_VERSION% LEQ 4 ( - SET SET_SDK_64=Y - ) ELSE ( - SET SET_SDK_64=N - IF EXIST "%WIN_WDK%" ( - :: See: https://connect.microsoft.com/VisualStudio/feedback/details/1610302/ - REN "%WIN_WDK%" 0wdf - ) - ) - ) ELSE ( - ECHO Unsupported Python version: "%MAJOR_PYTHON_VERSION%" - EXIT 1 - ) -) - -IF %PYTHON_ARCH% == 64 ( - IF %SET_SDK_64% == Y ( - ECHO Configuring Windows SDK %WINDOWS_SDK_VERSION% for Python %MAJOR_PYTHON_VERSION% on a 64 bit architecture - SET DISTUTILS_USE_SDK=1 - SET MSSdk=1 - "%WIN_SDK_ROOT%\%WINDOWS_SDK_VERSION%\Setup\WindowsSdkVer.exe" -q -version:%WINDOWS_SDK_VERSION% - "%WIN_SDK_ROOT%\%WINDOWS_SDK_VERSION%\Bin\SetEnv.cmd" /x64 /release - ECHO Executing: %COMMAND_TO_RUN% - call %COMMAND_TO_RUN% || EXIT 1 - ) ELSE ( - ECHO Using default MSVC build environment for 64 bit architecture - ECHO Executing: %COMMAND_TO_RUN% - call %COMMAND_TO_RUN% || EXIT 1 - ) -) ELSE ( - ECHO Using default MSVC build environment for 32 bit architecture - ECHO Executing: %COMMAND_TO_RUN% - call %COMMAND_TO_RUN% || EXIT 1 -) diff --git a/coverage/control.py b/coverage/control.py index 2d75417e2..086490730 100644 --- a/coverage/control.py +++ b/coverage/control.py @@ -4,6 +4,7 @@ """Core control stuff for coverage.py.""" import atexit +import collections import contextlib import os import os.path @@ -737,9 +738,12 @@ def _post_save_work(self): # Touch all the files that could have executed, so that we can # mark completely unexecuted files as 0% covered. if self._data is not None: + file_paths = collections.defaultdict(list) for file_path, plugin_name in self._inorout.find_possibly_unexecuted_files(): file_path = self._file_mapper(file_path) - self._data.touch_file(file_path, plugin_name) + file_paths[plugin_name].append(file_path) + for plugin_name, paths in file_paths.items(): + self._data.touch_files(paths, plugin_name) if self.config.note: self._warn("The '[run] note' setting is no longer supported.") diff --git a/coverage/env.py b/coverage/env.py index b5da3b471..80153ecf1 100644 --- a/coverage/env.py +++ b/coverage/env.py @@ -66,7 +66,7 @@ class PYBEHAVIOR(object): # used to be an empty string (meaning the current directory). It changed # to be the actual path to the current directory, so that os.chdir wouldn't # affect the outcome. - actual_syspath0_dash_m = (PYVERSION >= (3, 7, 0, 'beta', 3)) + actual_syspath0_dash_m = (not PYPY) and (PYVERSION >= (3, 7, 0, 'beta', 3)) # When a break/continue/return statement in a try block jumps to a finally # block, does the finally block do the break/continue/return (pre-3.8), or diff --git a/coverage/html.py b/coverage/html.py index 3596bbe1d..247d2ae19 100644 --- a/coverage/html.py +++ b/coverage/html.py @@ -166,6 +166,7 @@ class HtmlReporter(object): ("coverage_html.js", ""), ("keybd_closed.png", ""), ("keybd_open.png", ""), + ("favicon_32.png", ""), ] def __init__(self, cov): diff --git a/coverage/htmlfiles/coverage_html.js b/coverage/htmlfiles/coverage_html.js index 3bf04bf92..6bc9fdf59 100644 --- a/coverage/htmlfiles/coverage_html.js +++ b/coverage/htmlfiles/coverage_html.js @@ -224,7 +224,7 @@ coverage.index_ready = function ($) { coverage.wire_up_filter(); // Watch for page unload events so we can save the final sort settings: - $(window).unload(function () { + $(window).on("unload", function () { try { localStorage.setItem(storage_name, sort_list.toString()) } catch(err) {} diff --git a/coverage/htmlfiles/favicon_32.png b/coverage/htmlfiles/favicon_32.png new file mode 100644 index 000000000..8649f0475 Binary files /dev/null and b/coverage/htmlfiles/favicon_32.png differ diff --git a/coverage/htmlfiles/index.html b/coverage/htmlfiles/index.html index 4129bc31b..983db0612 100644 --- a/coverage/htmlfiles/index.html +++ b/coverage/htmlfiles/index.html @@ -6,6 +6,7 @@ {{ title|escape }} + {% if extra_css %} diff --git a/coverage/htmlfiles/pyfile.html b/coverage/htmlfiles/pyfile.html index ec0f416ff..e15be066f 100644 --- a/coverage/htmlfiles/pyfile.html +++ b/coverage/htmlfiles/pyfile.html @@ -9,6 +9,7 @@ {# http://social.msdn.microsoft.com/Forums/en-US/iewebdevelopment/thread/7684445e-f080-4d8f-8529-132763348e21 #} Coverage for {{relative_filename|escape}}: {{nums.pc_covered_str}}% + {% if extra_css %} diff --git a/coverage/optional.py b/coverage/optional.py index ee617b625..507a1ada7 100644 --- a/coverage/optional.py +++ b/coverage/optional.py @@ -14,6 +14,14 @@ Bad:: + # MyModule.py + import unsure + + def use_unsure(): + unsure.something() + +Also bad:: + # MyModule.py from coverage.optional import unsure diff --git a/coverage/pytracer.py b/coverage/pytracer.py index 44bfc8d6a..7d7a519b7 100644 --- a/coverage/pytracer.py +++ b/coverage/pytracer.py @@ -107,7 +107,7 @@ def _trace(self, frame, event, arg_unused): if event == 'call': # Should we start a new context? if self.should_start_context and self.context is None: - context_maybe = self.should_start_context(frame) + context_maybe = self.should_start_context(frame) # pylint: disable=not-callable if context_maybe is not None: self.context = context_maybe self.started_context = True @@ -132,15 +132,15 @@ def _trace(self, frame, event, arg_unused): self.cur_file_name = filename disp = self.should_trace_cache.get(filename) if disp is None: - disp = self.should_trace(filename, frame) - self.should_trace_cache[filename] = disp + disp = self.should_trace(filename, frame) # pylint: disable=not-callable + self.should_trace_cache[filename] = disp # pylint: disable=unsupported-assignment-operation self.cur_file_dict = None if disp.trace: tracename = disp.source_filename - if tracename not in self.data: - self.data[tracename] = {} - self.cur_file_dict = self.data[tracename] + if tracename not in self.data: # pylint: disable=unsupported-membership-test + self.data[tracename] = {} # pylint: disable=unsupported-assignment-operation + self.cur_file_dict = self.data[tracename] # pylint: disable=unsubscriptable-object # The call event is really a "start frame" event, and happens for # function calls and re-entering generators. The f_lasti field is # -1 for calls, and a real offset for generators. Use <0 as the @@ -227,7 +227,7 @@ def stop(self): # has changed to None. dont_warn = (env.PYPY and env.PYPYVERSION >= (5, 4) and self.in_atexit and tf is None) if (not dont_warn) and tf != self._trace: # pylint: disable=comparison-with-callable - self.warn( + self.warn( # pylint: disable=not-callable "Trace function changed, measurement is likely wrong: %r" % (tf,), slug="trace-changed", ) diff --git a/coverage/sqldata.py b/coverage/sqldata.py index b8ee88532..7a3b5c795 100644 --- a/coverage/sqldata.py +++ b/coverage/sqldata.py @@ -167,7 +167,8 @@ class CoverageData(SimpleReprMixin): To record data for contexts, use :meth:`set_context` to set a context to be used for subsequent :meth:`add_lines` and :meth:`add_arcs` calls. - To add a source file without any measured data, use :meth:`touch_file`. + To add a source file without any measured data, use :meth:`touch_file`, + or :meth:`touch_files` for a list of such files. Write the data to its file with :meth:`write`. @@ -536,16 +537,26 @@ def touch_file(self, filename, plugin_name=""): `plugin_name` is the name of the plugin responsible for this file. It is used to associate the right filereporter, etc. """ + self.touch_files([filename], plugin_name) + + def touch_files(self, filenames, plugin_name=""): + """Ensure that `filenames` appear in the data, empty if needed. + + `plugin_name` is the name of the plugin responsible for these files. It is used + to associate the right filereporter, etc. + """ if self._debug.should('dataop'): - self._debug.write("Touching %r" % (filename,)) + self._debug.write("Touching %r" % (filenames,)) self._start_using() - if not self._has_arcs and not self._has_lines: - raise CoverageException("Can't touch files in an empty CoverageData") + with self._connect(): # Use this to get one transaction. + if not self._has_arcs and not self._has_lines: + raise CoverageException("Can't touch files in an empty CoverageData") - self._file_id(filename, add=True) - if plugin_name: - # Set the tracer for this file - self.add_file_tracers({filename: plugin_name}) + for filename in filenames: + self._file_id(filename, add=True) + if plugin_name: + # Set the tracer for this file + self.add_file_tracers({filename: plugin_name}) def update(self, other_data, aliases=None): """Update this data with data from several other :class:`CoverageData` instances. @@ -1045,7 +1056,13 @@ def execute(self, sql, parameters=()): tail = " with {!r}".format(parameters) if parameters else "" self.debug.write("Executing {!r}{}".format(sql, tail)) try: - return self.con.execute(sql, parameters) + try: + return self.con.execute(sql, parameters) + except Exception: + # In some cases, an error might happen that isn't really an + # error. Try again immediately. + # https://github.com/nedbat/coveragepy/issues/1010 + return self.con.execute(sql, parameters) except sqlite3.Error as exc: msg = str(exc) try: diff --git a/coverage/version.py b/coverage/version.py index 2f29dd28f..f10206db2 100644 --- a/coverage/version.py +++ b/coverage/version.py @@ -5,7 +5,7 @@ # This file is exec'ed in setup.py, don't import anything! # Same semantics as sys.version_info. -version_info = (5, 3, 0, "final", 0) +version_info = (5, 3, 1, "final", 0) def _make_version(major, minor, micro, releaselevel, serial): diff --git a/doc/conf.py b/doc/conf.py index fb6a88eab..2fbf6c1e9 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -66,11 +66,11 @@ # built documents. # # The short X.Y version. -version = "5.3" # CHANGEME +version = "5.3.1" # CHANGEME # The full version, including alpha/beta/rc tags. -release = "5.3" # CHANGEME +release = "5.3.1" # CHANGEME # The date of release, in "monthname day, year" format. -release_date = "September 13, 2020" # CHANGEME +release_date = "December 19, 2020" # CHANGEME rst_epilog = """ .. |release_date| replace:: {release_date} diff --git a/doc/excluding.rst b/doc/excluding.rst index fc2bc116f..b2792c877 100644 --- a/doc/excluding.rst +++ b/doc/excluding.rst @@ -86,6 +86,7 @@ For example, here's a list of exclusions I've used:: raise NotImplementedError if 0: if __name__ == .__main__.: + class .*\bProtocol\): Note that when using the ``exclude_lines`` option in a configuration file, you are taking control of the entire list of regexes, so you need to re-specify the diff --git a/doc/index.rst b/doc/index.rst index d235dcf8a..0e7eb22ee 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -16,14 +16,14 @@ not. The latest version is coverage.py |release|, released |release_date|. It is supported on: -* Python versions 2.7, 3.5, 3.6, 3.7, 3.8, and 3.9 beta. +* Python versions 2.7, 3.5, 3.6, 3.7, 3.8, 3.9, and 3.10 alpha. * PyPy2 7.3.1 and PyPy3 7.3.1. .. ifconfig:: prerelease **This is a pre-release build. The usual warnings about possible bugs - apply.** The latest stable version is coverage.py 5.3, `described here`_. + apply.** The latest stable version is coverage.py 5.3.1, `described here`_. .. _described here: http://coverage.readthedocs.io/ diff --git a/doc/requirements.pip b/doc/requirements.pip index fb47cd29f..26d03b8f5 100644 --- a/doc/requirements.pip +++ b/doc/requirements.pip @@ -4,9 +4,10 @@ doc8==0.8.1 pyenchant==3.1.1 -sphinx==3.2.1 +sphinx==2.4.3 sphinx-rst-builder==0.0.3 -sphinxcontrib-spelling==5.3.0 +# 5.x requires Sphinx 3 +sphinxcontrib-spelling==4.3.0 sphinx_rtd_theme==0.5.0 sphinx-autobuild==0.7.1 sphinx-tabs==1.2.0 diff --git a/doc/sample_html/cogapp___init___py.html b/doc/sample_html/cogapp___init___py.html index f18ea24b5..d4d31a79e 100644 --- a/doc/sample_html/cogapp___init___py.html +++ b/doc/sample_html/cogapp___init___py.html @@ -4,6 +4,7 @@ Coverage for cogapp/__init__.py: 100.00% + @@ -65,8 +66,8 @@

diff --git a/doc/sample_html/cogapp___main___py.html b/doc/sample_html/cogapp___main___py.html index 0223c84e7..97140bde7 100644 --- a/doc/sample_html/cogapp___main___py.html +++ b/doc/sample_html/cogapp___main___py.html @@ -4,6 +4,7 @@ Coverage for cogapp/__main__.py: 0.00% + @@ -61,8 +62,8 @@

diff --git a/doc/sample_html/cogapp_backward_py.html b/doc/sample_html/cogapp_backward_py.html index 8f62840a6..17149a30a 100644 --- a/doc/sample_html/cogapp_backward_py.html +++ b/doc/sample_html/cogapp_backward_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/backward.py: 69.23% + @@ -98,8 +99,8 @@

diff --git a/doc/sample_html/cogapp_cogapp_py.html b/doc/sample_html/cogapp_cogapp_py.html index 3b1737649..3f0e5a567 100644 --- a/doc/sample_html/cogapp_cogapp_py.html +++ b/doc/sample_html/cogapp_cogapp_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/cogapp.py: 49.34% + @@ -864,8 +865,8 @@

diff --git a/doc/sample_html/cogapp_makefiles_py.html b/doc/sample_html/cogapp_makefiles_py.html index d266132d7..df5fd59e5 100644 --- a/doc/sample_html/cogapp_makefiles_py.html +++ b/doc/sample_html/cogapp_makefiles_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/makefiles.py: 17.07% + @@ -102,8 +103,8 @@

diff --git a/doc/sample_html/cogapp_test_cogapp_py.html b/doc/sample_html/cogapp_test_cogapp_py.html index 43513a5e3..4894b141d 100644 --- a/doc/sample_html/cogapp_test_cogapp_py.html +++ b/doc/sample_html/cogapp_test_cogapp_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/test_cogapp.py: 30.00% + @@ -2534,8 +2535,8 @@

diff --git a/doc/sample_html/cogapp_test_makefiles_py.html b/doc/sample_html/cogapp_test_makefiles_py.html index d0a261060..26028b2f8 100644 --- a/doc/sample_html/cogapp_test_makefiles_py.html +++ b/doc/sample_html/cogapp_test_makefiles_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/test_makefiles.py: 23.38% + @@ -178,8 +179,8 @@

diff --git a/doc/sample_html/cogapp_test_whiteutils_py.html b/doc/sample_html/cogapp_test_whiteutils_py.html index 93610e456..88c631b2e 100644 --- a/doc/sample_html/cogapp_test_whiteutils_py.html +++ b/doc/sample_html/cogapp_test_whiteutils_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/test_whiteutils.py: 27.54% + @@ -157,8 +158,8 @@

diff --git a/doc/sample_html/cogapp_whiteutils_py.html b/doc/sample_html/cogapp_whiteutils_py.html index 2b1372f1a..b7f2d7d50 100644 --- a/doc/sample_html/cogapp_whiteutils_py.html +++ b/doc/sample_html/cogapp_whiteutils_py.html @@ -4,6 +4,7 @@ Coverage for cogapp/whiteutils.py: 88.61% + @@ -129,8 +130,8 @@

diff --git a/doc/sample_html/coverage_html.js b/doc/sample_html/coverage_html.js index 3bf04bf92..6bc9fdf59 100644 --- a/doc/sample_html/coverage_html.js +++ b/doc/sample_html/coverage_html.js @@ -224,7 +224,7 @@ coverage.index_ready = function ($) { coverage.wire_up_filter(); // Watch for page unload events so we can save the final sort settings: - $(window).unload(function () { + $(window).on("unload", function () { try { localStorage.setItem(storage_name, sort_list.toString()) } catch(err) {} diff --git a/doc/sample_html/favicon_32.png b/doc/sample_html/favicon_32.png new file mode 100644 index 000000000..8649f0475 Binary files /dev/null and b/doc/sample_html/favicon_32.png differ diff --git a/doc/sample_html/index.html b/doc/sample_html/index.html index f69704794..be4b02c74 100644 --- a/doc/sample_html/index.html +++ b/doc/sample_html/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -155,8 +156,8 @@

Coverage report: diff --git a/doc/sample_html/status.json b/doc/sample_html/status.json index b57cdfbc1..fe49a4d49 100644 --- a/doc/sample_html/status.json +++ b/doc/sample_html/status.json @@ -1 +1 @@ -{"format":2,"version":"5.3","globals":"ea0e0ec5d6d9849e6fc73b34af46a2dc","files":{"cogapp___init___py":{"hash":"6010eef3af87123028eb691d70094593","index":{"nums":[1,2,0,0,0,0,0],"html_filename":"cogapp___init___py.html","relative_filename":"cogapp/__init__.py"}},"cogapp___main___py":{"hash":"2cec3551dfd9a5818a6550318658ccd4","index":{"nums":[1,3,0,3,0,0,0],"html_filename":"cogapp___main___py.html","relative_filename":"cogapp/__main__.py"}},"cogapp_backward_py":{"hash":"f95e44a818c73b2187e6fadc6257f8ce","index":{"nums":[1,22,0,6,4,2,2],"html_filename":"cogapp_backward_py.html","relative_filename":"cogapp/backward.py"}},"cogapp_cogapp_py":{"hash":"f85acbdbacefaccb9c499ef6cbe2ffc4","index":{"nums":[1,485,1,215,200,28,132],"html_filename":"cogapp_cogapp_py.html","relative_filename":"cogapp/cogapp.py"}},"cogapp_makefiles_py":{"hash":"4fd2add44238312a5567022fe28737de","index":{"nums":[1,27,0,20,14,0,14],"html_filename":"cogapp_makefiles_py.html","relative_filename":"cogapp/makefiles.py"}},"cogapp_test_cogapp_py":{"hash":"ee9b3c832eaa47b9e3940133c58827af","index":{"nums":[1,790,6,549,20,0,18],"html_filename":"cogapp_test_cogapp_py.html","relative_filename":"cogapp/test_cogapp.py"}},"cogapp_test_makefiles_py":{"hash":"66093f767a400ce1720b94a7371de48b","index":{"nums":[1,71,0,53,6,0,6],"html_filename":"cogapp_test_makefiles_py.html","relative_filename":"cogapp/test_makefiles.py"}},"cogapp_test_whiteutils_py":{"hash":"068beefb2872fe6739fad2471c36a4f1","index":{"nums":[1,69,0,50,0,0,0],"html_filename":"cogapp_test_whiteutils_py.html","relative_filename":"cogapp/test_whiteutils.py"}},"cogapp_whiteutils_py":{"hash":"b16b0e7f940175106b11230fea9e8c8c","index":{"nums":[1,45,0,5,34,4,4],"html_filename":"cogapp_whiteutils_py.html","relative_filename":"cogapp/whiteutils.py"}}}} \ No newline at end of file +{"format":2,"version":"5.3.1","globals":"28441ac12ca4ad5182670460eb380fe5","files":{"cogapp___init___py":{"hash":"6010eef3af87123028eb691d70094593","index":{"nums":[1,2,0,0,0,0,0],"html_filename":"cogapp___init___py.html","relative_filename":"cogapp/__init__.py"}},"cogapp___main___py":{"hash":"2cec3551dfd9a5818a6550318658ccd4","index":{"nums":[1,3,0,3,0,0,0],"html_filename":"cogapp___main___py.html","relative_filename":"cogapp/__main__.py"}},"cogapp_backward_py":{"hash":"f95e44a818c73b2187e6fadc6257f8ce","index":{"nums":[1,22,0,6,4,2,2],"html_filename":"cogapp_backward_py.html","relative_filename":"cogapp/backward.py"}},"cogapp_cogapp_py":{"hash":"f85acbdbacefaccb9c499ef6cbe2ffc4","index":{"nums":[1,485,1,215,200,28,132],"html_filename":"cogapp_cogapp_py.html","relative_filename":"cogapp/cogapp.py"}},"cogapp_makefiles_py":{"hash":"4fd2add44238312a5567022fe28737de","index":{"nums":[1,27,0,20,14,0,14],"html_filename":"cogapp_makefiles_py.html","relative_filename":"cogapp/makefiles.py"}},"cogapp_test_cogapp_py":{"hash":"ee9b3c832eaa47b9e3940133c58827af","index":{"nums":[1,790,6,549,20,0,18],"html_filename":"cogapp_test_cogapp_py.html","relative_filename":"cogapp/test_cogapp.py"}},"cogapp_test_makefiles_py":{"hash":"66093f767a400ce1720b94a7371de48b","index":{"nums":[1,71,0,53,6,0,6],"html_filename":"cogapp_test_makefiles_py.html","relative_filename":"cogapp/test_makefiles.py"}},"cogapp_test_whiteutils_py":{"hash":"068beefb2872fe6739fad2471c36a4f1","index":{"nums":[1,69,0,50,0,0,0],"html_filename":"cogapp_test_whiteutils_py.html","relative_filename":"cogapp/test_whiteutils.py"}},"cogapp_whiteutils_py":{"hash":"b16b0e7f940175106b11230fea9e8c8c","index":{"nums":[1,45,0,5,34,4,4],"html_filename":"cogapp_whiteutils_py.html","relative_filename":"cogapp/whiteutils.py"}}}} \ No newline at end of file diff --git a/howto.txt b/howto.txt index 1ad455d35..8a912833d 100644 --- a/howto.txt +++ b/howto.txt @@ -8,7 +8,6 @@ version_info = (4, 0, 2, "final", 0) - Python version number in classifiers in setup.py - Copyright date in NOTICE.txt -- Update specific Python versions in appveyor.yml ("PYTHON_VERSION") - Update CHANGES.rst, including release date. - don't forget the jump target - Update README.rst @@ -45,16 +44,10 @@ - ELSE: $ make publish - Kits: - - Start fresh: - $ make sterile - - Source kit and wheels: - $ make kit wheel - - Linux wheels: - $ make kit_linux - - Windows kits - - wait for over an hour for Appveyor to build kits. - - https://ci.appveyor.com/project/nedbat/coveragepy - $ make download_appveyor + - Manually trigger the kit GitHub Action + - https://github.com/nedbat/coveragepy/actions?query=workflow%3A%22Build+kits%22 + - Download built kits from GitHub Actions: + $ make clean download_kits - examine the dist directory, and remove anything that looks malformed. - check the dist directory: $ python -m twine check dist/* diff --git a/igor.py b/igor.py index 9a632b577..31d4bacc2 100644 --- a/igor.py +++ b/igor.py @@ -310,9 +310,10 @@ def check_files(root, patterns, **kwargs): check_file("setup.py") check_file("igor.py") check_file("Makefile") - check_file(".travis.yml") check_files(".", ["*.rst", "*.txt"]) check_files(".", ["*.pip"]) + check_files(".github", ["*"]) + check_files("ci", ["*"]) def print_banner(label): diff --git a/requirements/ci.pip b/requirements/ci.pip index c36045685..060d1de3f 100644 --- a/requirements/ci.pip +++ b/requirements/ci.pip @@ -1,8 +1,7 @@ # Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt -# Things CI servers need to succeeed. +# Things CI servers need for running tests. -r tox.pip -r pytest.pip -r wheel.pip -tox-travis==0.12 diff --git a/requirements/pins.pip b/requirements/pins.pip new file mode 100644 index 000000000..223e7cbdf --- /dev/null +++ b/requirements/pins.pip @@ -0,0 +1,7 @@ +# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 +# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt + +# Version pins, for use as a constraints file. + +cibuildwheel==1.7.0 +tox-gh-actions==2.2.0 diff --git a/requirements/pip.pip b/requirements/pip.pip index 01ee89bb7..c7c4895f2 100644 --- a/requirements/pip.pip +++ b/requirements/pip.pip @@ -1,5 +1,5 @@ # Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0 # For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt -pip==20.2.2 -virtualenv==20.0.31 +pip==20.2.4 +virtualenv==20.2.1 diff --git a/requirements/pytest.pip b/requirements/pytest.pip index 5149e0736..43d4efe51 100644 --- a/requirements/pytest.pip +++ b/requirements/pytest.pip @@ -5,8 +5,9 @@ # 4.x is last to support py2 pytest==4.6.11 -pytest-xdist==1.32.0 -flaky==3.6.1 +# 1.34 is last to support py2 +pytest-xdist==1.34.0 +flaky==3.7.0 # 4.x is py3-only mock==3.0.5 # Use a fork of PyContracts that supports Python 3.9 diff --git a/requirements/tox.pip b/requirements/tox.pip index 7ba31f447..0e0f20f2f 100644 --- a/requirements/tox.pip +++ b/requirements/tox.pip @@ -2,4 +2,4 @@ # For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt # The version of tox used by coverage.py -tox==3.19.0 +tox==3.20.1 diff --git a/requirements/wheel.pip b/requirements/wheel.pip index 2fd03ad2e..ae84163ab 100644 --- a/requirements/wheel.pip +++ b/requirements/wheel.pip @@ -3,5 +3,6 @@ # Things needed to make wheels for coverage.py +# setuptools 45.x is py3-only setuptools==44.1.1 -wheel==0.34.2 +wheel==0.35.1 diff --git a/setup.cfg b/setup.cfg index 00b7acc28..16e2bc6cc 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [tool:pytest] -addopts = -q -n3 --strict --no-flaky-report -rfe --failed-first +addopts = -q -n3 --strict --force-flaky --no-flaky-report -rfe --failed-first markers = expensive: too slow to run during "make smoke" # How come this warning is suppressed successfully here, but not in conftest.py?? diff --git a/setup.py b/setup.py index 8c837d72c..86a054ab2 100644 --- a/setup.py +++ b/setup.py @@ -33,6 +33,7 @@ Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.8 Programming Language :: Python :: 3.9 +Programming Language :: Python :: 3.10 Programming Language :: Python :: Implementation :: CPython Programming Language :: Python :: Implementation :: PyPy Topic :: Software Development :: Quality Assurance diff --git a/tests/gold/html/a/a_py.html b/tests/gold/html/a/a_py.html index af5d72a19..5bfb1c898 100644 --- a/tests/gold/html/a/a_py.html +++ b/tests/gold/html/a/a_py.html @@ -4,6 +4,7 @@ Coverage for a.py: 67% + @@ -60,8 +61,8 @@

diff --git a/tests/gold/html/a/index.html b/tests/gold/html/a/index.html index 3276f1d65..2520e1563 100644 --- a/tests/gold/html/a/index.html +++ b/tests/gold/html/a/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -75,8 +76,8 @@

Coverage report: diff --git a/tests/gold/html/b_branch/b_py.html b/tests/gold/html/b_branch/b_py.html index ee28735e5..2be085b91 100644 --- a/tests/gold/html/b_branch/b_py.html +++ b/tests/gold/html/b_branch/b_py.html @@ -4,6 +4,7 @@ Coverage for b.py: 70% + @@ -83,8 +84,8 @@

diff --git a/tests/gold/html/b_branch/index.html b/tests/gold/html/b_branch/index.html index 0dfc20cad..284599970 100644 --- a/tests/gold/html/b_branch/index.html +++ b/tests/gold/html/b_branch/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -83,8 +84,8 @@

Coverage report: diff --git a/tests/gold/html/bom/2/bom_py.html b/tests/gold/html/bom/2/bom_py.html index a66988452..b38312aed 100644 --- a/tests/gold/html/bom/2/bom_py.html +++ b/tests/gold/html/bom/2/bom_py.html @@ -4,6 +4,7 @@ Coverage for bom.py: 71% + @@ -66,8 +67,8 @@

diff --git a/tests/gold/html/bom/2/index.html b/tests/gold/html/bom/2/index.html index 28abec0a6..85b712df8 100644 --- a/tests/gold/html/bom/2/index.html +++ b/tests/gold/html/bom/2/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -75,8 +76,8 @@

Coverage report: diff --git a/tests/gold/html/bom/bom_py.html b/tests/gold/html/bom/bom_py.html index 3b181c633..cf0de385c 100644 --- a/tests/gold/html/bom/bom_py.html +++ b/tests/gold/html/bom/bom_py.html @@ -4,6 +4,7 @@ Coverage for bom.py: 71% + @@ -66,8 +67,8 @@

diff --git a/tests/gold/html/bom/index.html b/tests/gold/html/bom/index.html index 0e56a99a6..598116cd9 100644 --- a/tests/gold/html/bom/index.html +++ b/tests/gold/html/bom/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -75,8 +76,8 @@

Coverage report: diff --git a/tests/gold/html/isolatin1/index.html b/tests/gold/html/isolatin1/index.html index ec9c50b52..3a4700b35 100644 --- a/tests/gold/html/isolatin1/index.html +++ b/tests/gold/html/isolatin1/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -75,8 +76,8 @@

Coverage report: diff --git a/tests/gold/html/isolatin1/isolatin1_py.html b/tests/gold/html/isolatin1/isolatin1_py.html index 3dd8c8fd0..9a5891374 100644 --- a/tests/gold/html/isolatin1/isolatin1_py.html +++ b/tests/gold/html/isolatin1/isolatin1_py.html @@ -4,6 +4,7 @@ Coverage for isolatin1.py: 100% + @@ -60,8 +61,8 @@

diff --git a/tests/gold/html/omit_1/index.html b/tests/gold/html/omit_1/index.html index a97add0f6..5590b82bd 100644 --- a/tests/gold/html/omit_1/index.html +++ b/tests/gold/html/omit_1/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -96,8 +97,8 @@

Coverage report: diff --git a/tests/gold/html/omit_1/m1_py.html b/tests/gold/html/omit_1/m1_py.html index 94fba21eb..2257fd094 100644 --- a/tests/gold/html/omit_1/m1_py.html +++ b/tests/gold/html/omit_1/m1_py.html @@ -4,6 +4,7 @@ Coverage for m1.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_1/m2_py.html b/tests/gold/html/omit_1/m2_py.html index ade526d30..0a5ca20eb 100644 --- a/tests/gold/html/omit_1/m2_py.html +++ b/tests/gold/html/omit_1/m2_py.html @@ -4,6 +4,7 @@ Coverage for m2.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_1/m3_py.html b/tests/gold/html/omit_1/m3_py.html index d6b4756d1..f9f56f7c8 100644 --- a/tests/gold/html/omit_1/m3_py.html +++ b/tests/gold/html/omit_1/m3_py.html @@ -4,6 +4,7 @@ Coverage for m3.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_1/main_py.html b/tests/gold/html/omit_1/main_py.html index 5d4781245..5ff014aef 100644 --- a/tests/gold/html/omit_1/main_py.html +++ b/tests/gold/html/omit_1/main_py.html @@ -4,6 +4,7 @@ Coverage for main.py: 100% + @@ -65,8 +66,8 @@

diff --git a/tests/gold/html/omit_2/index.html b/tests/gold/html/omit_2/index.html index 5b5e3c6ea..ebe8195b5 100644 --- a/tests/gold/html/omit_2/index.html +++ b/tests/gold/html/omit_2/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -89,8 +90,8 @@

Coverage report: diff --git a/tests/gold/html/omit_2/m2_py.html b/tests/gold/html/omit_2/m2_py.html index ade526d30..0a5ca20eb 100644 --- a/tests/gold/html/omit_2/m2_py.html +++ b/tests/gold/html/omit_2/m2_py.html @@ -4,6 +4,7 @@ Coverage for m2.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_2/m3_py.html b/tests/gold/html/omit_2/m3_py.html index d6b4756d1..f9f56f7c8 100644 --- a/tests/gold/html/omit_2/m3_py.html +++ b/tests/gold/html/omit_2/m3_py.html @@ -4,6 +4,7 @@ Coverage for m3.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_2/main_py.html b/tests/gold/html/omit_2/main_py.html index 5d4781245..5ff014aef 100644 --- a/tests/gold/html/omit_2/main_py.html +++ b/tests/gold/html/omit_2/main_py.html @@ -4,6 +4,7 @@ Coverage for main.py: 100% + @@ -65,8 +66,8 @@

diff --git a/tests/gold/html/omit_3/index.html b/tests/gold/html/omit_3/index.html index f5bc1aaeb..8f304c478 100644 --- a/tests/gold/html/omit_3/index.html +++ b/tests/gold/html/omit_3/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -82,8 +83,8 @@

Coverage report: diff --git a/tests/gold/html/omit_3/m3_py.html b/tests/gold/html/omit_3/m3_py.html index d6b4756d1..f9f56f7c8 100644 --- a/tests/gold/html/omit_3/m3_py.html +++ b/tests/gold/html/omit_3/m3_py.html @@ -4,6 +4,7 @@ Coverage for m3.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_3/main_py.html b/tests/gold/html/omit_3/main_py.html index 5d4781245..5ff014aef 100644 --- a/tests/gold/html/omit_3/main_py.html +++ b/tests/gold/html/omit_3/main_py.html @@ -4,6 +4,7 @@ Coverage for main.py: 100% + @@ -65,8 +66,8 @@

diff --git a/tests/gold/html/omit_4/index.html b/tests/gold/html/omit_4/index.html index 861ba02e3..96e45bafa 100644 --- a/tests/gold/html/omit_4/index.html +++ b/tests/gold/html/omit_4/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -89,8 +90,8 @@

Coverage report: diff --git a/tests/gold/html/omit_4/m1_py.html b/tests/gold/html/omit_4/m1_py.html index 94fba21eb..2257fd094 100644 --- a/tests/gold/html/omit_4/m1_py.html +++ b/tests/gold/html/omit_4/m1_py.html @@ -4,6 +4,7 @@ Coverage for m1.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_4/m3_py.html b/tests/gold/html/omit_4/m3_py.html index d6b4756d1..f9f56f7c8 100644 --- a/tests/gold/html/omit_4/m3_py.html +++ b/tests/gold/html/omit_4/m3_py.html @@ -4,6 +4,7 @@ Coverage for m3.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_4/main_py.html b/tests/gold/html/omit_4/main_py.html index 5d4781245..5ff014aef 100644 --- a/tests/gold/html/omit_4/main_py.html +++ b/tests/gold/html/omit_4/main_py.html @@ -4,6 +4,7 @@ Coverage for main.py: 100% + @@ -65,8 +66,8 @@

diff --git a/tests/gold/html/omit_5/index.html b/tests/gold/html/omit_5/index.html index 8afbebad5..8c1c95243 100644 --- a/tests/gold/html/omit_5/index.html +++ b/tests/gold/html/omit_5/index.html @@ -3,6 +3,7 @@ Coverage report + @@ -82,8 +83,8 @@

Coverage report: diff --git a/tests/gold/html/omit_5/m1_py.html b/tests/gold/html/omit_5/m1_py.html index 94fba21eb..2257fd094 100644 --- a/tests/gold/html/omit_5/m1_py.html +++ b/tests/gold/html/omit_5/m1_py.html @@ -4,6 +4,7 @@ Coverage for m1.py: 100% + @@ -57,8 +58,8 @@

diff --git a/tests/gold/html/omit_5/main_py.html b/tests/gold/html/omit_5/main_py.html index 5d4781245..5ff014aef 100644 --- a/tests/gold/html/omit_5/main_py.html +++ b/tests/gold/html/omit_5/main_py.html @@ -4,6 +4,7 @@ Coverage for main.py: 100% + @@ -65,8 +66,8 @@

diff --git a/tests/gold/html/other/blah_blah_other_py.html b/tests/gold/html/other/blah_blah_other_py.html index d88e21e56..b286e1e2d 100644 --- a/tests/gold/html/other/blah_blah_other_py.html +++ b/tests/gold/html/other/blah_blah_other_py.html @@ -3,7 +3,8 @@ - Coverage for /private/var/folders/j2/gr3cj3jn63s5q8g3bjvw57hm0000gp/T/coverage_test/tests_test_html_HtmlGoldTests_test_other_08291136/othersrc/other.py: 100% + Coverage for /private/var/folders/j2/gr3cj3jn63s5q8g3bjvw57hm0000gp/T/coverage_test/tests_test_html_HtmlGoldTests_test_other_58265363/othersrc/other.py: 100% + @@ -16,7 +17,7 @@