Skip to content

ci: release-rust: certify only a fully green release at least N days old - #1758

Merged
zackees merged 2 commits into
masterfrom
infra/1757-certify-gate
Oct 22, 2026
Merged

zackees merged 2 commits into
masterfrom
infra/1757-certify-gate

Conversation

@zackees

@zackees zackees commented Oct 22, 2026

Copy link
Copy Markdown
Member

Stacked: builds on #1742; the new commits are d4658a7 (RED) and 45ce1f7 (GREEN). Retarget to master after #1742 merges.

Fixes #1757

The certify job now refuses a tag unless:

  1. the release-rust.yaml run that published it (newest run for the tag's commit whose "Publish pre-release 🚀" job succeeded) concluded success and every job succeeded. Only the certify job and a reusable workflow's own sub-jobs (Release gate 🚦 / …, AppImage 📦 / …, which their caller job already decided) may be skipped; a skipped top-level job (a build, a smoke test, the gate) refuses.
  2. the release is at least min_age_days old: a new workflow_dispatch input, default 2. 0 is the emergency override and is logged as ::warning::; negative values are refused.
  • ci/update_feed.py check-certifiable --facts facts.json --min-age-days N [--now ISO]: a pure decision over a JSON document (tag, tag commit, release, runs with jobs).
  • release-rust.yaml "Check the release 🔎" assembles that document with gh api (commit, workflow runs for the commit, each run's jobs, gh release view) and runs the check before anything is downloaded or uploaded.
  • Docs: docs/rust-port/release-criteria.md (certified releases section) and the frontend: Update from certified obs-rust releases #1742 ledger entry in docs/features.md.

RED → GREEN

  • RED d4658a7: check_certifiable stub raises NotImplementedError. uv run python -m unittest ci/test_update_feed.py: 19 tests, 15 errors (all CheckCertifiableTests), 2 failures (CLI has no check-certifiable; the workflow test finds no check-certifiable/min_age_days).
  • GREEN 45ce1f7: same command, OK (19 tests). Fixture JSON only, no live API calls.

Also passing: ci/test_release_step_pitfalls.py, ci/test_no_upstream_updater.py, ci/test_release_*.py, ci/test_workflow_*.py; ./lint ok.

Checked against a real release (read-only)

I ran the step's gh api/jq commands by hand against obs-studio-rust-v0.1.0-beta.20261020 (run 39437208726, 38 jobs). The first version of the rule refused it for AppImage 📦 / Publish to GitHub Releases 🚀 (skipped), which is why reusable-workflow sub-jobs may skip. With the final rule: --min-age-days 2 refuses it (1.7 days old), and --min-age-days 0 passes with the warning.

Tiers: CI script only. Tier 1 is the Python unit tests; Tiers 2 to 4 do not apply. Not verified: a real certify dispatch (the maintainer asked us not to run release workflows).

@zackees
zackees force-pushed the fix/updater-certified-releases branch 2 times, most recently from 44d8ec2 to a580063 Compare October 22, 2026 09:20
@zackees
zackees force-pushed the infra/1757-certify-gate branch from 45ce1f7 to e4f38ae Compare October 22, 2026 09:20
@zackees
zackees changed the base branch from fix/updater-certified-releases to master October 22, 2026 11:10
check-certifiable is a stub; 15 CheckCertifiableTests error with
NotImplementedError, the CLI test and the workflow test fail.
)

ci/update_feed.py check-certifiable refuses a tag unless the release-rust
run that published it succeeded in every job (only certify and reusable
workflow sub-jobs may skip) and the release is min_age_days old (default
2; 0 is an emergency override logged as a warning). release-rust.yaml's
certify job gathers the facts with gh api and runs it in Check the release.

Fixes #1757
@zackees
zackees force-pushed the infra/1757-certify-gate branch from e4f38ae to 65f7c0e Compare October 22, 2026 11:10
@zackees
zackees enabled auto-merge October 22, 2026 11:10
@zackees
zackees added this pull request to the merge queue Oct 22, 2026
Merged via the queue into master with commit faa8818 Oct 22, 2026
27 checks passed
@zackees
zackees deleted the infra/1757-certify-gate branch October 26, 2026 15:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

ci: release-rust: certify only a fully green release that is at least N days old

1 participant