Skip to content

ci: fix Go workflow versions#142

Merged
pquerna merged 1 commit into
mainfrom
paul.querna/fix-golangci-lint-ci
Jun 26, 2026
Merged

ci: fix Go workflow versions#142
pquerna merged 1 commit into
mainfrom
paul.querna/fix-golangci-lint-ci

Conversation

@c1-squire-dev

@c1-squire-dev c1-squire-dev Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

What changed

  • Update go.mod to Go 1.26.
  • Run actions/checkout before actions/setup-go in both CI workflows so setup-go can see go.sum and restore Go module/build caches correctly.
  • Use go-version-file: go.mod in CI and release workflows so GitHub Actions tracks the repo's declared Go version instead of carrying stale hardcoded Go versions.
  • Update checkout/setup-go to current Node 24-compatible major versions.
  • Update main ci from golangci/golangci-lint-action@v3 with version: latest to golangci/golangci-lint-action@v9 pinned to golangci-lint v2.9.0.
  • Keep pull-request CI aligned with main CI by using the same golangci-lint action/version there too.
  • Update guyarb/golang-test-annotations to v0.9.0 to avoid the old Node 20 action warning.
  • Update release Docker helper actions to current majors while touching the release workflow Go setup.

Why

The failed main CI run at https://github.com/ConductorOne/cone/actions/runs/28218801447/job/83595346715 failed in go-lint because golangci-lint-action@v3 resolved latest to golangci-lint v1.64.8, but this repo's .golangci.yml is a v2 config. The same run also warned that setup-go could not find go.sum because checkout happened after setup-go.

The first PR run exposed additional workflow drift: CI was still pinned to Go 1.23.x while the repo had already moved past that. Using go-version-file removes that drift, and the module directive now carries the requested Go 1.26 baseline through CI and release.

Validation

  • go run github.com/rhysd/actionlint/cmd/actionlint@latest .github/workflows/ci.yaml .github/workflows/main.yaml .github/workflows/release.yaml
  • go mod verify
  • make lint
  • go test ./...
  • git diff --check

@c1-squire-dev c1-squire-dev Bot force-pushed the paul.querna/fix-golangci-lint-ci branch from a7480a3 to e779c38 Compare June 26, 2026 05:29
Checkout before setup-go so dependency caching can see go.sum, use go.mod as the workflow Go version source of truth, and pin golangci-lint to a v2 release compatible with the repo's v2 config.

Update the module directive to Go 1.26 and carry that through release workflows instead of stale hardcoded Go versions.

Co-authored-by: c1-squire-dev[bot] <c1-squire-dev[bot]@users.noreply.github.com>
@c1-squire-dev c1-squire-dev Bot force-pushed the paul.querna/fix-golangci-lint-ci branch from e779c38 to 0fc8e7b Compare June 26, 2026 05:34
@c1-squire-dev c1-squire-dev Bot changed the title ci: fix golangci-lint workflow ci: fix Go workflow versions Jun 26, 2026
@pquerna pquerna merged commit 1c53c2a into main Jun 26, 2026
2 checks passed
@pquerna pquerna deleted the paul.querna/fix-golangci-lint-ci branch June 26, 2026 05:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant