Skip to content

go version seems broken somehow... #71869

Not planned
Not planned
@rayjlinden

Description

@rayjlinden

Go version

1.23.6

Output of go env in your module/workspace:

GO111MODULE=''
GOARCH='amd64'
GOBIN=''
GOCACHE='/home/rayj/.cache/go-build'
GOENV='/home/rayj/.config/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='amd64'
GOHOSTOS='linux'
GOINSECURE=''
GOMODCACHE='/var/tmp/rayj/gocode/pkg/mod'
GONOPROXY='github.com/lindenlab/*'
GONOSUMDB='github.com/lindenlab/*'
GOOS='linux'
GOPATH='/var/tmp/rayj/gocode'
GOPRIVATE='github.com/lindenlab/*'
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/var/tmp/rayj/gocode/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.linux-amd64'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='go1.22.4'
GOTOOLDIR='/var/tmp/rayj/gocode/pkg/mod/golang.org/toolchain@v0.0.1-go1.22.4.linux-amd64/pkg/tool/linux_amd64'
GOVCS=''
GOVERSION='go1.22.4'
GCCGO='gccgo'
GOAMD64='v1'
AR='ar'
CC='gcc'
CXX='g++'
CGO_ENABLED='1'
GOMOD='/dev/null'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build3428743121=/tmp/go-build -gno-record-gcc-switches'

What did you do?

I just installed go 1.23.6 (replacing go1.22.4). However the NEW binary still reports the old version!!!

What did you see happen?

rayj@bullseye(gobuild123)$ go version
go version go1.22.4 linux/amd64
rayj@bullseye(gobuild123)$ which go
/var/tmp/mw_pkgs/go/bin/go
rayj@bullseye(gobuild123)$ go version /var/tmp/mw_pkgs/go/bin/go
/var/tmp/mw_pkgs/go/bin/go: go1.23.6

I also see the go env command returns GOVERSION='go1.22.4' among all the other vars.

This never used to happen during previous upgrades so this is rather confusing...

Why would the go binary return an old version number?

What did you expect to see?

I expect go version to return:
go version go1.23.6 linux/amd64

Activity

added
BugReportIssues describing a possible bug in the Go implementation.
on Feb 21, 2025
seankhliao

seankhliao commented on Feb 21, 2025

@seankhliao
Member

see your GOTOOLCHAIN setting

Unlike many projects, the Go project does not use GitHub Issues for general discussion or asking questions. GitHub Issues are used for tracking bugs and proposals only.

For questions please refer to https://github.com/golang/go/wiki/Questions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugReportIssues describing a possible bug in the Go implementation.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @seankhliao@rayjlinden@gabyhelp

        Issue actions

          go version seems broken somehow... · Issue #71869 · golang/go