From a7a246903f7f148ce85297b734888184c5065959 Mon Sep 17 00:00:00 2001 From: Pengfei Hu Date: Fri, 22 May 2026 22:46:45 -0700 Subject: [PATCH] Raise CI coverage gate 75 -> 85 (v0.21 E7) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Round-4 review item E7: "Threshold bump to 85% (free signal — actual is 87.87%)". Actual aggregate coverage on current `main` measures 88.09% (re-confirmed locally), so the gate is +10pp tighter with ~3pp headroom for day-to-day movement. No source change needed to land; the gate is simply closer to the actual signal. Changes: - ``.github/workflows/ci.yml`` line 48: ``--cov-fail-under=75`` -> ``85`` - ``.github/workflows/release.yml`` line 37: same bump so the release path cannot bypass the tighter floor - ``CHANGELOG.md`` Unreleased entry documenting the bump The bump catches the next time a refactor lands materially less-covered code without corresponding tests. Per-file coverage is not enforced; teams adding lower-covered modules must keep the aggregate >= 85. Verification: - ``python -m pytest --cov-fail-under=85 -q`` exits 0; coverage 88.09% - ``python -m ruff check .`` clean - No source under ``src/`` touched Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/workflows/ci.yml | 7 ++++++- .github/workflows/release.yml | 4 +++- CHANGELOG.md | 10 ++++++++++ 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 72d06385..0a9699a3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,7 +45,12 @@ jobs: # run as part of the main Test step below. - name: Test - run: python -m pytest --cov=agents_shipgate --cov-report=term-missing --cov-fail-under=75 + # v0.21 (E7): bumped from 75 → 85. Actual aggregate coverage on + # current main is ~88%, so the gate is +10pp tighter with ~3pp + # headroom for day-to-day movement. The bump catches the next + # time a refactor lands materially less-covered code without + # a corresponding test pass. + run: python -m pytest --cov=agents_shipgate --cov-report=term-missing --cov-fail-under=85 - name: Build package run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d8b39738..b5e15b1a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -31,10 +31,12 @@ jobs: python -m pip install "uv==0.11.7" - name: Lint and test + # v0.21 (E7): coverage threshold bumped from 75 → 85, matching + # CI gate so release cannot bypass the tighter floor. run: | python -m ruff check . python -m compileall -q src tests - python -m pytest --cov=agents_shipgate --cov-report=term-missing --cov-fail-under=75 + python -m pytest --cov=agents_shipgate --cov-report=term-missing --cov-fail-under=85 - name: Build package run: | diff --git a/CHANGELOG.md b/CHANGELOG.md index 8307066a..95e309cf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,16 @@ ## Unreleased +- **v0.21 — CI coverage gate raised from 75% → 85% (E7 from round-4 review).** + Both `.github/workflows/ci.yml` and `.github/workflows/release.yml` now + pass `--cov-fail-under=85`. Aggregate coverage on `main` at the time of + the bump is ~88%, so the gate is +10pp tighter with ~3pp headroom for + day-to-day movement. The bump catches the next time a refactor lands + materially less-covered code without corresponding tests. No source + change required to land — the gate is simply closer to the actual + signal. Per-file coverage is not enforced; the aggregate floor only + rises in step with what's already proven on `main`. + - **v0.20 — third-party adapter entry-point discovery (E4 from round-3 review).** Opens the same extension surface for adapters (input loaders) that M5 already opened for check plugins. Discovery is gated by the existing