Repository navigation
chore: require Go 1.27.1 (go directive) - #81
Merged
Merged
Conversation
go.mod: go 1.27.1 (was go 1.25.0 + toolchain go1.27.1); go mod tidy drops the now-redundant toolchain line. Importers need Go 1.27.1 or later (GOTOOLCHAIN=auto downloads it). No exported identifier changes. - bff.NewSingleHostProxy keeps httputil.ReverseProxy.Director (deprecated since Go 1.26, SA1019 at go 1.27): callers wrap it, so a Rewrite-based proxy must be a new, additive constructor; the two lines carry a reasoned nolint until then. - CI: the toolchain check reads the go line when there is no toolchain line; govulncheck pinned to v1.8.0. - README, CLIENT-INTEGRATION, CONTRIBUTING and CLAUDE.md state the new requirement. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GKRxaeYxyDhmt42cehLsGA
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.
What and why
This aligns backendkit with the rest of the suite, which builds and ships with Go 1.27.1 (go-oauth2 #306 does the same for Socrate):
go.mod:go 1.27.1, wasgo 1.25.0plustoolchain go1.27.1.go mod tidydrops atoolchainline equal to thegoline. The language level andGODEBUGdefaults now match the Go that CI tests.toolchainline, or thegoline when there is none.@latest. It's built with the job's Go 1.27.1; a govulncheck built with an older Go refuses ago 1.27module.docs/CLIENT-INTEGRATION.md,CONTRIBUTING.mdandCLAUDE.mdstate the new requirement.Compatibility, please confirm:
GOTOOLCHAIN=auto(the default), an oldergocommand downloads it. WithGOTOOLCHAIN=localand an older Go, the build fails with "requires go >= 1.27.1".go 1.25.0precisely so Go 1.25 consumers could import backendkit. Go 1.25 is out of support, and both consoles build with 1.27.1.httputil.ReverseProxy.Director, deprecated since Go 1.26 and flagged by staticcheck SA1019 atgo 1.27:bff.NewSingleHostProxybuilds its proxy withDirector, and its doc tells callers to wrapDirector, which both consoles do. Switching it toRewritewould break those callers (v1 rule), andRewritealso changes howX-Forwarded-Foris built, which Socrate's rate limiting and audit attribution rely on.//nolint:staticcheckwith that reason.Directorremains supported under the Go 1 compatibility promise.Rewrite-based constructor, in its own PR, which the consoles adopt when they move off backendkit v1.15.How it was tested
go mod tidy && git diff --exit-code go.sumleavesgo.sumunchangedgo build ./...passesgo vet ./...passesgo test -race -count=1 -timeout=120s ./...passesgolangci-lint run ./...(v2.14.0, built with Go 1.27.1) reports no issuegovulncheck ./...: CI (the sandbox can't reach vuln.go.dev)## [Unreleased]inCHANGELOG.mdCI's toolchain check run locally passes:
go1.27.1from go.mod againstgo1.27.1from thegocommand.Compatibility
GOTOOLCHAIN=local. Raising thegodirective is normally done in a minor release, but by this repo's own rule it's for you to accept.🤖 Generated with Claude Code
https://claude.ai/code/session_01GKRxaeYxyDhmt42cehLsGA
Generated by Claude Code