From bd076376be1b9ffcfa2e5eab0bc8ee9fb970e0ed Mon Sep 17 00:00:00 2001 From: "mudler's LocalAI [bot]" <139863280+localai-bot@users.noreply.github.com> Date: Mon, 3 Aug 2026 19:18:56 +0200 Subject: [PATCH] fix(ci): install the Go the module asks for when building the site (#11322) Deploy site to GitHub Pages failed on five of the last eight master pushes, always in the build job before Hugo runs: Setup go version spec 1.22 ... go: downloading go1.26.0 (linux/amd64) go: download go1.26.0: golang.org/toolchain@v0.0.1-go1.26.0.linux-amd64: Get "https://proxy.golang.org/...": connect: network is unreachable ##[error]Command failed: go env GOPATH The workflow pinned setup-go to 1.22 while go.mod declares go 1.26.0, so the `go run ./.github/ci/modelslist.go` step that generates the gallery page had to fetch the real toolchain from proxy.golang.org first. That fetch is not reliably reachable from the runner, which is why the deploy alternated between passing and failing rather than failing outright. Track go.mod instead of a literal. The version the module needs is then installed directly and there is no toolchain download to fail. This matters beyond CI noise: the docs and the site, including the release blog post, ship through this workflow. Scoped deliberately to gh-pages, the workflow with the observed failure. test-extra.yml pins 1.25.4 in a dozen places and is below go.mod for the same reason, so those jobs also download a toolchain, but they are currently green and rewriting twelve pins on a hunch risks more than it fixes. Worth a follow-up. Assisted-by: Claude Code:claude-opus-5 [Read] [Edit] [Bash] Signed-off-by: Ettore Di Giacinto Co-authored-by: Ettore Di Giacinto --- .github/workflows/gh-pages.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml index abcd0aa45..746ed923d 100644 --- a/.github/workflows/gh-pages.yml +++ b/.github/workflows/gh-pages.yml @@ -51,7 +51,16 @@ jobs: - name: Setup Go uses: actions/setup-go@v5 with: - go-version: '1.22' + # Track go.mod rather than a literal. Pinned at 1.22 this installed a + # toolchain older than the module's `go 1.26.0`, so the `go run` below + # downloaded the real one from proxy.golang.org on every run. That + # fetch is not always reachable from the runner and the deploy failed + # on five of eight consecutive master pushes with: + # go: download go1.26.0: ... connect: network is unreachable + # ##[error]Command failed: go env GOPATH + # Installing the version the module asks for removes the download + # instead of depending on it succeeding. + go-version-file: go.mod cache: false - name: Setup Hugo