8000 ci: light gate on pull requests, full gate before a release by rafatahmed · Pull Request #220 · rafatahmed/Flahax · GitHub
[go: up one dir, main page]

Skip to content

ci: light gate on pull requests, full gate before a release - #220

Closed
rafatahmed wants to merge 3 commits into
mainfrom
ci/pr-gate-and-full-gate
Closed

rafatahmed wants to merge 3 commits into
mainfrom
ci/pr-gate-and-full-gate

Conversation

@rafatahmed
@rafatahmed rafatahmed commented Nov 5, 2026 •
Copy link
Copy Markdown
Owner

Summary

 Test workflow
+  scope               light or full? did code change?
   style
   docs
   phreeqc-live
   test (matrix)
-    3.11 3.12 3.13 3.14 + windows + macos, every PR
+    light (PR, push to main): linux 3.11 3.12 3.13
+    full  (manual run):       + 3.14, windows, macos
-    coverage on 3.13 on three OSes, every PR
+    coverage only in the full tier
   coverage-gate
-    exact 3-OS coverage + Codecov upload, every PR
+    light: prerequisites must pass; full: exact 3-OS coverage + Codecov
+  a newer push cancels the run still going on the same PR
+  docs-only PR (docs/, top-level .md): lint, docs build, docs tests; no PHREEQC replay
+    decided by tools/ci_scope.py; a failed git comparison fails the job, never reads as docs-only

 publish.yml
+  full-gate   calls test.yml in full mode on the tagged commit; build needs it

Required check names are unchanged (test (3.11), test (3.12), test (3.13), phreeqc-live, coverage-gate), so branch protection needs no edit. Decision recorded in docs/adr/0002-light-pull-request-gate.md.

Evidence

  • Before: PR 219 jobs took 27 min (3.14), 35 min (3.13), 38 to 41 min (macOS) and 56 min (Windows); the Windows coverage step alone ran past 59 min. Dependabot PRs 217 and 218 failed coverage-gate because the Codecov token is empty for Dependabot.
    After (measured on this PR's first run): the test step took 346 s on Linux 3.13, 455 s on 3.12 and 575 s on 3.11, with no coverage; the Codecov upload runs only in the full tier. No end-to-end time for the whole gate is claimed yet; it is measured below once the run finishes.
test_the_light_tier_reports_every_required_test_check_on_linux_only
  light matrix == {test (3.11), test (3.12), test (3.13)}, all ubuntu-latest

test_coverage_and_codecov_run_only_in_the_full_tier
  coverage step if == COVERAGE_RUN; every coverage-gate step after the prerequisites is full-tier only
  • tests/test_ci_workflow.py (7 tests) and the existing test_ci_coverage contract test pass locally; ruff clean. The contract test failed on the first light run because it still listed the old needs and matrix, and is updated here.
  • Not yet run: the full tier and the release path. They need one manual 8000 run (Actions > Test > Run workflow) on this branch, and a release to exercise publish.yml.

Merge Danger

Door: two-way. Reverting this one file restores the old gate.

Blast Radius: CI

  • A coverage gap or a Windows, macOS or Python 3.14 only failure is no longer caught on the pull request; it shows up in the full run before a release.
  • A release now also runs the full tier (3.11 to 3.14, Windows, macOS, exact three-OS coverage) through publish.yml, and build waits for it. A coverage gap found then stops the publication until it is fixed. The publish.yml change cannot be exercised before a release.
  • Branch protection strict: true still reruns every open PR after any merge.

@rafatahmed rafatahmed added the github_actions Pull requests that update GitHub Actions code label Nov 5, 2026
@rafatahmed rafatahmed self-assigned this Nov 5, 2026
@rafatahmed rafatahmed closed this Nov 5, 2026
@rafatahmed
rafatahmed deleted the ci/pr-gate-and-full-gate branch November 7, 2026 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Pull requests that update GitHub Actions code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0