-
Notifications
You must be signed in to change notification settings - Fork 17.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tool(gopls): fail to install gopls #62004
Comments
looks more likely that you have a corrupt installation of go |
more info: hello-world go clean --modcache
➜ hello-world go clean -cache
➜ hello-world go install -v golang.org/x/tools/gopls@latest
go: downloading golang.org/x/tools/gopls v0.13.1
go: downloading golang.org/x/tools v0.12.0
go: downloading honnef.co/go/tools v0.4.2
go: downloading github.com/sergi/go-diff v1.1.0
go: downloading golang.org/x/tools v0.11.2-0.20230801165449-23c7f589706c
go: downloading mvdan.cc/gofumpt v0.4.0
go: downloading mvdan.cc/xurls/v2 v2.4.0
go: downloading golang.org/x/mod v0.12.0
go: downloading golang.org/x/sync v0.3.0
go: downloading golang.org/x/text v0.11.0
go: downloading golang.org/x/sys v0.10.0
go: downloading golang.org/x/vuln v0.0.0-20230110180137-6ad3e3d07815
go: downloading github.com/google/go-cmp v0.5.9
go: downloading golang.org/x/exp/typeparams v0.0.0-20221212164502-fae10dda9338
go: downloading github.com/BurntSushi/toml v1.2.1
go: downloading golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e
internal/unsafeheader
internal/coverage/rtcov
internal/goarch
internal/goos
internal/itoa
internal/godebugs
internal/race
internal/goexperiment
internal/cpu
runtime/internal/atomic
runtime/internal/syscall
sync/atomic
unicode/utf8
encoding
unicode
math/bits
runtime/internal/math
runtime/internal/sys
unicode/utf16
internal/abi
crypto/internal/alias
# runtime/internal/sys
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:9:7: len8tab redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:76:7: other declaration of len8tab
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:32:6: Len64 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:99:6: other declaration of Len64
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:50:7: m0 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:117:7: other declaration of m0
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:51:7: m1 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:118:7: other declaration of m1
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:52:7: m2 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:119:7: other declaration of m2
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:55:6: OnesCount64 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:122:6: other declaration of OnesCount64
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:86:6: LeadingZeros64 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:153:6: other declaration of LeadingZeros64
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:89:6: LeadingZeros8 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:156:6: other declaration of LeadingZeros8
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:92:6: Len8 redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:159:6: other declaration of Len8
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:101:6: Prefetch redeclared in this block
/usr/local/go/src/runtime/internal/sys/intrinsics.go:200:6: other declaration of Prefetch
/usr/local/go/src/runtime/internal/sys/intrinsics_common.go:101:6: too many errors
crypto/subtle
crypto/internal/boring/sig
internal/goversion
internal/nettrace
log/internal
internal/platform
container/list
vendor/golang.org/x/crypto/cryptobyte/asn1
internal/bytealg
math
vendor/golang.org/x/crypto/internal/alias
golang.org/x/exp/constraints
github.com/google/go-cmp/cmp/internal/flags
golang.org/x/exp/slices |
by cleaning cache mode, i also meet this issue. so i need to reinstall go? |
it look like no corrupt installation of go ➜ ~ sha256sum go1.21.0.linux-amd64.tar.gz > sha256sum.txt
➜ ~ cat sha256sum.txt
d0398903a16ba2232b389fb31032ddf57cac34efda306a0eebac34f0965a0742 go1.21.0.linux-amd64.tar.gz |
it look like another issue by drop to go 1.20.7 ➜ ~ go version
go version go1.20.7 linux/amd64
➜ ~ go clean -cache
➜ ~ go clean -cache
➜ ~ go clean --modcache
➜ ~ go install -v golang.org/x/tools/gopls@latest
go: downloading golang.org/x/tools v0.12.0
go: downloading golang.org/x/tools/gopls v0.13.1
go: downloading honnef.co/go/tools v0.4.2
go: downloading github.com/sergi/go-diff v1.1.0
go: downloading golang.org/x/tools v0.11.2-0.20230801165449-23c7f589706c
go: downloading mvdan.cc/gofumpt v0.4.0
go: downloading mvdan.cc/xurls/v2 v2.4.0
go: downloading golang.org/x/mod v0.12.0
go: downloading golang.org/x/sync v0.3.0
go: downloading golang.org/x/text v0.11.0
go: downloading github.com/google/go-cmp v0.5.9
go: downloading golang.org/x/exp/typeparams v0.0.0-20221212164502-fae10dda9338
go: downloading golang.org/x/sys v0.10.0
go: downloading golang.org/x/vuln v0.0.0-20230110180137-6ad3e3d07815
go: downloading github.com/BurntSushi/toml v1.2.1
go: downloading golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e
internal/goarch
internal/itoa
internal/coverage/rtcov
internal/goexperiment
internal/goos
internal/race
unicode
internal/unsafeheader
runtime/internal/atomic
internal/cpu
sync/atomic
internal/abi
runtime/internal/math
unicode/utf8
runtime/internal/syscall
encoding
runtime/internal/sys
math/bits
unicode/utf16
crypto/internal/alias
crypto/subtle
crypto/internal/boring/sig
# internal/abi
/usr/local/go/src/internal/abi/funcpc.go:22:6: FuncPCABI0 redeclared in this block
/usr/local/go/src/internal/abi/abi.go:117:6: other declaration of FuncPCABI0
/usr/local/go/src/internal/abi/funcpc.go:31:6: FuncPCABIInternal redeclared in this block
/usr/local/go/src/internal/abi/abi.go:126:6: other declaration of FuncPCABIInternal
internal/nettrace
internal/goversion
container/list
vendor/golang.org/x/crypto/internal/alias
vendor/golang.org/x/crypto/cryptobyte/asn1
golang.org/x/exp/constraints
github.com/google/go-cmp/cmp/internal/flags
internal/bytealg
math
golang.org/x/exp/slices |
i fixed it by remove 妈的,好歹分享一下解决思路吧,就说我下的golang的版本问题。。。。 |
I encountered the same problem when compiling error log:
My solution is:
|
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
yes
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
i failed to install gopls:
The text was updated successfully, but these errors were encountered: