Repository navigation
ci(release): the release page's wheels and sdist are in SHA256SUMS and the build-provenance attestation (#1466) - #1510
Draft
DrunkOnJava wants to merge 6 commits into
Draft
DrunkOnJava wants to merge 6 commits into
DrunkOnJava wants to merge 6 commits into
Conversation
…d the build-provenance attestation, and a dispatch rehearses it (#1466) SHA256SUMS now hashes every file the page carries but the provenance bundle, and one attestation covers dist/* (the CLI archives, the seven wheels, the sdist and SHA256SUMS), so gh attestation verify works for each file and the attested SHA256SUMS checks the page. The attestation moves to its own job, which checks the page against SHA256SUMS before signing and hands the signed page to upload as one artifact; upload keeps contents: write and no longer holds the OIDC token. A workflow_dispatch input, python, builds one wheel and the sdist under publish.yml's artifact names so the same checksum and attestation jobs can be run before a tag (nothing is attached or pushed). check-workflows.py fails when the checksums, attest and upload jobs stop describing the same files.
…nd upload jobs behind it (#1466) The first design put the job-level if on the python rehearsal job and a status check on checksums. In a pull request run the python job was skipped, checksums ran, and image, attest and upload were skipped behind it (run 42134335447), which a release would have done too and published nothing. The rehearsal job now always runs and its steps carry the if, and check-workflows.py fails a job-level if on build, python and checksums.
…he wheels and the sdist (#1466)
DrunkOnJava
marked this pull request as ready for review
November 6, 2026 01:04
DrunkOnJava
marked this pull request as draft
November 6, 2026 01:12
…release with no page, and verification names the tag's ref (#1466) A dispatch with python signs real attestations for a branch build, and gh attestation verify -R alone accepts them, so the documented commands add --source-ref refs/tags/<tag>. checksums requires exactly seven wheels for a release (one for a rehearsal), counted against publish.yml's build-wheels matrix by check-workflows.py. A page job after upload fails when the release does not hold the fifteen attested files, so a skipped upload goes red. check-workflows.py now fails the shapes that would let a tag run go green with no page: attest or upload not running on inputs.upload, upload needing more than attest, a job between them, a job-level if above upload or image. RELEASE.md documents the rehearsal's limits and how to recover a release whose page chain failed; install.md, release-checklist.md and the changelog fragment say SHA256SUMS does not list itself.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The Python wheels and the sdist on a release page go into
SHA256SUMSand the build-provenance attestation, sogh attestation verify <file> -R DrunkOnJava/rvt-rsworks for each of them and the one attestedSHA256SUMSchecks every file on the page but the provenance bundle.docs/install.mdandRELEASE.mdstop saying coverage is the CLI archives only.Motivation
#1466: the release page carries seven wheels and the sdist beside the CLI archives, and none of them was in
SHA256SUMSor the attestation. The checksum job is the hardest job of a release to test before a real tag, so this adds a way to run it on any ref and was proved that way (below).Changes
.github/workflows/release-binaries.yml:checksumshashes every file the run holds for the page (the archives, and for a release or apythonrehearsal thewheel-*andsdistartifacts); the attestation moves fromuploadto a newattestjob, which checks the page againstSHA256SUMS(every line has its file with that hash, every file a line) before signingdist/*, and hands the signed page touploadas therelease-pageartifact;uploadkeepscontents: write, loses the OIDC token andattestations: write, and attaches that artifact only;imagedownloads the archives andSHA256SUMSinstead of every artifact (so the new artifacts cannot race into its directory); aworkflow_dispatchinputpythonbuilds one wheel and the sdist so the same jobs run before a tag. Thepythonjob always runs and its steps carry theif: a job-levelifskippedimage,attestanduploadbehind it in the first design's pull request run (42134335447), which a release would have done too..github/workflows/publish.yml:release-binariesnamesbuild-wheelsandbuild-sdistinneeds(already transitive throughpublish-crate), and its comment says what the page carries.tools/ci/check-workflows.pyand its failure-first tests: fails whenchecksums,attestanduploadstop describing the same files, and on a job-levelifonbuild,pythonorchecksums.docs/install.md,RELEASE.md(including how to rehearse the page before a tag),docs/maintaining.md,changelog.d/changed/1457-release-preflight.md(its "in neither (Release page: add the wheels and the sdist to SHA256SUMS and the build-provenance attestation #1466)" clause), and a new fragment.docker/stage.shandtools/ci/release_preflight.pyare unchanged:stage.shchecks with--ignore-missing, and the preflight decides nothing about the page.Testing
Unit tests are banned in this repository: do not add them. Show the change working end to end on real files instead.
tools/check-local.sh: not applicable, nosrc/change.actionlintandpython3 tools/ci/check-workflows.pyare clean;zizmoris clean (7 suppressed, 8 before) and at the auditor persona has 7 findings against 8 on main, none new.workflow_dispatchwithpython=trueon this branch: every job passed,Attach to the GitHub Releaseskipped, the image's login, push and attestation steps skipped. The downloadedrelease-pageartifact holds the five archives, one wheel, the sdist,SHA256SUMSand the bundle;sha256sum -c SHA256SUMSpasses for the seven files it lists; a realgh attestation verify -R DrunkOnJava/rvt-rspasses on the wheel, the sdist,SHA256SUMS, the Linux x86_64 archive and the Windows archive; the attestation's eight subjects are exactly the seven lines ofSHA256SUMSplusSHA256SUMS.docker/stage.shpasses on that directory and on the two Linux archives withSHA256SUMSalone (lines of absent files skipped).SHA256SUMSlists the five archives, the image job'sstage.shand smoke test pass,attestanduploadskipped.imageskipped behind the skippedpythonjob, fixed in 872f6b6.uploadjob, of the seven-wheel set where the rehearsal builds one, and of the image push after its two-step download);workflow_callitself, whoseinputs.uploadside of the conditions the dispatch cannot set.refs/heads/ci/1466-release-page-checksums, triggerworkflow_dispatch, runs 42134282381 and 42137536209) for their own wheels, sdist, archives andSHA256SUMS, none of them a release file; the public Sigstore log keeps them. Both runs' artifacts are deleted.Audit-honesty checklist
changelog.d/<section>/Breaking changes
None.
Related issues
Closes #1466
Refs #1457