From bc81bfe88494f8320e87e560a0b494d7bae434cd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Nov 2026 23:37:46 +0000 Subject: [PATCH 1/2] Bump pytest-cov from 6.2.1 to 7.1.0 in the pip group Bumps the pip group with 1 update: [pytest-cov](https://github.com/pytest-dev/pytest-cov). Updates `pytest-cov` from 6.2.1 to 7.1.0 - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v6.2.1...v7.1.0) --- updated-dependencies: - dependency-name: pytest-cov dependency-version: 7.1.0 dependency-type: direct:development update-type: version-update:semver-major dependency-group: pip ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 90ccf27c..ed5988ce 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -30,7 +30,7 @@ test = [ "filelock==4.2.9", "pyright==1.1.414", "pytest==9.2.0", - "pytest-cov==6.2.1", + "pytest-cov==7.1.0", "pytest-xdist==3.8.0", ] From b4e55790028bf6b7b9b6c003293c429328d257e7 Mon Sep 17 00:00:00 2001 From: Savannah Ostrowski Date: Fri, 13 Nov 2026 11:15:53 -0800 Subject: [PATCH 2/2] Migrate subprocess coverage to pytest-cov 7 --- bench_runner/__main__.py | 10 ---------- bench_runner/scripts/run_benchmarks.py | 9 --------- pyproject.toml | 3 +++ 3 files changed, 3 insertions(+), 19 deletions(-) diff --git a/bench_runner/__main__.py b/bench_runner/__main__.py index 9b191221..5d294874 100644 --- a/bench_runner/__main__.py +++ b/bench_runner/__main__.py @@ -1,5 +1,4 @@ import importlib -import os import sys @@ -26,15 +25,6 @@ } if __name__ == "__main__": - # This lets pytest-cov collect coverage data in a subprocess - if "COV_CORE_SOURCE" in os.environ: - try: - from pytest_cov.embed import init - - init() - except Exception: - sys.stderr.write("pytest-cov: Failed to setup subprocess coverage.") - command = len(sys.argv) >= 2 and sys.argv[1] or "" if command not in COMMANDS: diff --git a/bench_runner/scripts/run_benchmarks.py b/bench_runner/scripts/run_benchmarks.py index 54d6f1dd..c6688431 100644 --- a/bench_runner/scripts/run_benchmarks.py +++ b/bench_runner/scripts/run_benchmarks.py @@ -462,13 +462,4 @@ def dummy(*args, **kwargs): if __name__ == "__main__": - # This lets pytest-cov collect coverage data in a subprocess - if "COV_CORE_SOURCE" in os.environ: - try: - from pytest_cov.embed import init - - init() - except Exception: - sys.stderr.write("pytest-cov: Failed to setup subprocess coverage.") - main() diff --git a/pyproject.toml b/pyproject.toml index ed5988ce..baccfaaa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,6 +56,9 @@ markers = [ "long_running: marks tests as long_running (deselect with '-m \"not running\"')", ] +[tool.coverage.run] +patch = ["subprocess"] + [tool.coverage.paths] source = [ "bench_runner",