Go version

go version go1.25-devel_385000b004 2025-07-16 13:31:59 -0700 linux/amd64

Output of go env in your module/workspace:

AR='ar'
CC='gcc'
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_ENABLED='1'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
CXX='g++'
GCCGO='gccgo'
GO111MODULE=''
GOAMD64='v3'
GOARCH='amd64'
GOAUTH='netrc'
GOBIN=''
GOCACHE='/home/mvdan/.cache/go-build'
GOCACHEPROG=''
GODEBUG=''
GOENV='/home/mvdan/.config/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFIPS140='off'
GOFLAGS=''
GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build3253171257=/tmp/go-build -gno-record-gcc-switches'
GOHOSTARCH='amd64'
GOHOSTOS='linux'
GOINSECURE=''
GOMOD='/dev/null'
GOMODCACHE='/home/mvdan/go/pkg/mod'
GONOPROXY='github.com/cue-unity'
GONOSUMDB='github.com/cue-unity'
GOOS='linux'
GOPATH='/home/mvdan/go'
GOPRIVATE='github.com/cue-unity'
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/home/mvdan/tip'
GOSUMDB='sum.golang.org'
GOTELEMETRY='on'
GOTELEMETRYDIR='/home/mvdan/.config/go/telemetry'
GOTMPDIR=''
GOTOOLCHAIN='local'
GOTOOLDIR='/home/mvdan/tip/pkg/tool/linux_amd64'
GOVCS=''
GOVERSION='go1.25-devel_385000b004 2025-07-16 13:31:59 -0700'
GOWORK=''

What did you do?

As a testscript, i.e. with empty caches including GOCACHE:

go mod init test
go get -tool golang.org/x/tools/cmd/stringer

go tool -n stringer
go tool -n stringer

What did you see happen?

> go tool -n stringer
[stdout]
$WORK/.tmp/go-build232968071/b001/exe/stringer

> go tool -n stringer
[stdout]
/home/mvdan/.cache/go-build/e4/e45e2bde64f66e98b610efb016043fe7917f84e32bcadbe06daeb1ffb9eae8d1-d/stringer

That is, the first run on an empty cache, which builds and caches the binary, gives me a temporary path rather than the final path where the binary is stored in the cache.

What did you expect to see?

The same path inside $GOCACHE twice. Not only so that this path exists once the go tool -n finishes running, but also for consistency. Right now I'm seeing different behavior depending on whether the $GOCACHE was warm or not.

Comment From: mvdan

Thanks @seankhliao. FYI, on GitHub's notification email I just see "closed as duplicate", with no further details. So you may want to include the issue link as a comment as well, when closing these.

I also imagine that the bot might have done this, if given enough time.