Repository navigation
The Windows release build takes protoc from protobuf's own pinned zip and stops at once without it - #301
Conversation
…ip, checked by SHA-256, and fails at once without it
Review (
|
…ip, checked by SHA-256, and fails at once without it
Review (
|
What changed
.github/workflows/release.yml, Windows job: protoc no longer comes from Chocolatey. The "Rust and protoc" step downloads protobuf's own release zip,protoc-36.2-win64.zipfrom github.com/protocolbuffers/protobuf (curl -f --retry 5), checks it against its pinned SHA-256 (sha256sum -c; the hash matches the one GitHub lists for the asset and a local download), unpacks it with 7-Zip into$RUNNER_TEMP/protocand puts itsbinonGITHUB_PATH. A failed download, a wrong hash or a broken zip fails that step.protoc --version, so the build looks protoc up the same way the build scripts do (PATH), and a missing protoc fails the step at once (exit 127), not 4 minutes later in spqr's build script.protoc-36.2-win64.zip, in run 46309832317's log) and what local macOS builds use;prost-build0.14.4 (core/Cargo.lock) works with it.contents: read,contents: writeonly on the two upload jobs,GH_TOKENonly on the Upload steps,persist-credentials: false. The download needs no token.apt-get install -yq ... protobuf-compiler, which exits 100 when a package can't be found or fetched, and the step's shell isbash -e: it can't succeed with protoc missing the waychocodid (0/0 packages installed, exit 0).Why
The v0.1.2 Windows job (run 46310803851) failed:
choco install protocgot an error from the Chocolatey community feed, installed 0/0 packages, exited 0, and the build died minutes later with "Could not find protoc".How it was tested
Release workflows run from the tag's commit, so each run below is a throwaway pre-release on a throwaway branch; all three releases, their tags (remote and local) and the branches were deleted afterwards. No
v…release was touched.test-299-1, this PR's commit b6517b3), both jobs green. Windows:protoc.zip: OK, unpacked, the protoc step took 10 s (Chocolatey's took over a minute); the Build step printedlibprotoc 36.2and built in 12m35s; the start check passed (hush.loghasHush started version=test-299-1); uploadedHush-test-299-1-windows-x64.zip(25 MB). Linux: green as before, uploaded its tarball.test-299-2, one digit ofPROTOC_SHA256changed):sha256sum: WARNING: 1 computed checksum did NOT match,protoc.zip: FAILED, the step failed 25 s into the job; nothing after it ran.test-299-3, theGITHUB_PATHline removed): the Build step's first line failed withprotoc: command not found(exit 127), 27 s into the job, before cargo started. This also shows the runner image has no protoc of its own, so the build uses the pinned one.actionlint1.7.12 withshellcheck0.11: clean (installed into a scratch folder).make checkon the head, up to date with main: pass (fmt, both clippy runs, 402 + 553 tests).Closes #299