fix(release): the checksum key is singular, so GoReleaser rejected the whole config - #210
Merged
Merged
Conversation
…e whole config
`checksums:` is not a field in GoReleaser v2 — the key has always been `checksum:`. The plural made
it an unknown field, and GoReleaser refuses to start rather than ignoring it:
starting release
release failed after 0s
error=
| yaml: unmarshal errors:
| line 71: field checksums not found in type config.Project
So the release path produced NOTHING: no archives, no checksums.txt, no assets. Not a wrong
filename — a pipeline that never began.
Mine, from #141 (b08e543). What makes it worth stating plainly: #141 added `release.yaml` with a
`workflow_dispatch` snapshot entry, and its own commit body said that entry exists so "the release
path gets exercised before there is a tag to regret". That workflow had never been run. The first
run of it failed on this line, before a tag existed — which is the outcome it was added for, at the
cost of the release it was supposed to protect being broken the whole time in between.
The `name_template: checksums.txt` under it was correct and is now actually in effect. It matters:
GoReleaser's default checksum filename is `{{.ProjectName}}_{{.Version}}_checksums.txt`, and the
plugin's install.sh fetches `checksums.txt` — that is the only integrity check in the download path,
and it is fail-closed, so a mismatch there refuses the install rather than trusting the tarball.
Verified by re-running the same snapshot workflow on this branch rather than by reading: the run
that failed on `main` succeeds here, and builds all four archives.
Signed-off-by: DAVID AMID <DAVIDA@il.ibm.com>
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.
One word:
checksums:→checksum:. It blocks every release, and it is mine, from #141.What was broken
GoReleaser v2 has no
checksumsfield — the key has always been singular. An unknown field is not ignored; GoReleaser refuses to start:So the release path produced nothing: no archives, no
checksums.txt, no assets. Not a wrong filename — a pipeline that never began. Anyv*tag pushed tomaintoday publishes a release with zero artifacts, and the tag is public by the time anyone finds out.Introduced in
b08e5435(#141), and worth stating rather than glossing: #141 added theworkflow_dispatchsnapshot entry torelease.yaml, whose stated purpose in that same commit was that "the release path gets exercised before there is a tag to regret". It had never been run. Its first run failed on this line — which is the outcome it was added to produce, at the cost of the release being broken for every day in between. The lesson is not about the field name: a workflow that has never executed is not a safeguard, it is an intention.A second defect on the same line, quietly
The
name_template: checksums.txtunder that key was correct all along, and inert. GoReleaser's default checksum filename is{{ .ProjectName }}_{{ .Version }}_checksums.txt, while the plugin'sinstall.shfetcheschecksums.txt— and that is the only integrity check in the download path, deliberately fail-closed (checksum_unavailable→ refuse, never install-anyway).So even in a world where the config had loaded, every install would have refused with a missing checksums file. Fixing the key fixes both.
Verified by running it, not by reading it
Same workflow, same snapshot mode, on this branch — run 33877011327, success, against the identical run on
mainthat failed (33876270319):All four platforms, and the archive names match exactly what
install.shconstructs (context-guru_${VERSION#v}_${OS}_${ARCH}.tar.gz). The pure-Go assertion step passed as part of the same run.What this still does not prove
Snapshot mode deliberately does not publish, so the publish half — creating the GitHub release, uploading assets, the
contents: writetoken path — remains unexercised until a real tag. That is irreducible without cutting one; the firstv*tag is still the first time that code runs.Context
v0.1.0already exists as a tag (2026-07-27,e7c59907, by @OsherElhadad) with a release attached and zero assets — it predatesrelease.yaml, so nothing ever built for it. The next real release therefore wants to bev0.1.1, which is also what GoReleaser's ownincpatchchose for the snapshot above.Committed through the contents API rather than a local checkout so that #160's worktree stayed untouched; the branch is one commit off
mainand touches one file.