Skip to content

chore: build with Go 1.26 and update vulnerable dependencies - #1097

Merged
anupam-sl merged 1 commit into
mainfrom
chore/build-with-go-1.26
Jul 30, 2026
Merged

anupam-sl merged 1 commit into
mainfrom
chore/build-with-go-1.26

Conversation

@anupam-sl

Copy link
Copy Markdown
Contributor

Why

saucectl release binaries are currently built with Go 1.23 (go1.23.12), a toolchain line that stopped receiving security patches in August 2025. Vulnerability scanners therefore flag the released binaries for the unpatched Go standard library (38 known CVEs to date per OSV, none of which will ever be fixed on the 1.23 line), alongside outdated golang.org/x/net v0.33.0, golang.org/x/crypto v0.31.0 and go-git v5.13.1 module versions embedded in the build metadata. Users who package saucectl into container images see these findings in their image scans.

What

  • Build and CI now take the Go version from go.mod (go-version-file), bumped to Go 1.26 — one place to bump going forward. Applies to the release, test and CodeQL workflows plus the Dockerfile build stage.
  • Dependency upgrades for the flagged modules: go-git v5.13.1 → v5.19.2, x/net v0.33.0 → v0.57.0, x/crypto v0.31.0 → v0.54.0, plus transitive x/* bumps via go mod tidy.
  • golangci-lint bumped to v2 (action @v9): the v1.64 line is built with Go 1.24 and cannot typecheck a go 1.26 module. .golangci.yml is migrated to the v2 config format preserving the previous behavior — same linters, v1's implicit default exclusions now declared explicitly, goimports moved to the formatters section.

Supersedes #1026, #1055 and #1070.

Verification

  • go build ./... and go test ./... pass with go1.26.5.
  • golangci-lint run (v2.12.2): 0 issues.
  • govulncheck ./...: 0 vulnerabilities affecting saucectl code. The only remaining module-level advisory is GO-2026-5932 — the deprecated x/crypto/openpgp package, which saucectl does not import and which has no fixed version to upgrade to.
  • go version -m on a test build (the metadata that version-based scanners inspect) now reports go1.26.5 and the updated module versions.

🤖 Generated with Claude Code

Go 1.23 stopped receiving security patches in August 2025, so binaries built with it are flagged by vulnerability scanners for unpatched stdlib CVEs, alongside outdated x/net, x/crypto and go-git module versions embedded in the build metadata.

- Bump go.mod to Go 1.26 and point setup-go at it via go-version-file (release, test and CodeQL workflows) and the Dockerfile build stage.
- Upgrade go-git to v5.19.2, x/net to v0.57.0, x/crypto to v0.54.0, plus transitive x/* bumps via go mod tidy.
- Migrate golangci-lint to v2 (action @v9): the v1.64 line is built with Go 1.24 and cannot typecheck a go 1.26 module. Lint behavior is preserved (v1's implicit default exclusions are now declared explicitly; goimports moved to the formatters section).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@anupam-sl
anupam-sl requested a review from a team as a code owner July 29, 2026 18:11
@anupam-sl anupam-sl added go Pull requests that update Go code dependencies Pull requests that update a dependency file claude-code-assisted labels Jul 29, 2026
@anupam-sl

Copy link
Copy Markdown
Contributor Author

CI note: the failing xctest check is unrelated to this change — the same job fails identically on unmodified main (still built with the current Go 1.23 toolchain): https://github.com/saucelabs/saucectl/actions/runs/30482963346

The failure is an assertion inside the fixture app itself (RunnerTests.testFirstTestingScenarioIncrement5Decrement3((success) is true) failed - Instance of 'FlutterErrorDetails'), reproduced across three different device allocations (iPhone 12, iPhone 16 Pro on this PR's runs; iPhone 15 Pro on the main control run), all on iOS 18.7.2, three in-run retries each. The same fixture passed on 2026-07-23 (https://github.com/saucelabs/saucectl/actions/runs/30004577406), so it regressed on the device-cloud side between Jul 23 and Jul 29 independently of any code change. In every one of these runs saucectl uploads, schedules, retries and reports correctly.

All 16 other checks on this PR are green.

@anupam-sl
anupam-sl merged commit 70a09ca into main Jul 30, 2026
31 of 34 checks passed
@anupam-sl
anupam-sl deleted the chore/build-with-go-1.26 branch July 30, 2026 06:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claude-code-assisted dependencies Pull requests that update a dependency file go Pull requests that update Go code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants