Skip to content
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

x/tools/gopls: cannot find package error while installing #36442

Closed
Fuxxel opened this issue Jan 7, 2020 · 4 comments
Closed

x/tools/gopls: cannot find package error while installing #36442

Fuxxel opened this issue Jan 7, 2020 · 4 comments

Comments

@Fuxxel
Copy link

@Fuxxel Fuxxel commented Jan 7, 2020

What version of Go are you using (go version)?

$ go version
go version go1.13.5 linux/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/root/.cache/go-build"
GOENV="/root/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build663267071=/tmp/go-build -gno-record-gcc-switches"
GOROOT/bin/go version: go version go1.13.5 linux/amd64
GOROOT/bin/go tool compile -V: compile version go1.13.5
uname -sr: Linux 4.9.184-linuxkit
Distributor ID: Debian
Description:    Debian GNU/Linux 10 (buster)
Release:        10
Codename:       buster
/lib/x86_64-linux-gnu/libc.so.6: GNU C Library (Debian GLIBC 2.28-10) stable release version 2.28.

What did you do?

go get golang.org/x/tools/cmd/gopls

What did you expect to see?

Successful installation of gopls

What did you see instead?

package golang.org/x/tools/cmd/gopls: cannot find package "golang.org/x/tools/cmd/gopls" in any of:
        /usr/local/go/src/golang.org/x/tools/cmd/gopls (from $GOROOT)
        /go/src/golang.org/x/tools/cmd/gopls (from $GOPATH)
@gopherbot gopherbot added this to the Unreleased milestone Jan 7, 2020
@gopherbot

This comment has been minimized.

Copy link

@gopherbot gopherbot commented Jan 7, 2020

Thank you for filing a gopls issue! Please take a look at the Troubleshooting guide, and make sure that you have provided all of the relevant information here.

@stamblerre

This comment has been minimized.

Copy link
Contributor

@stamblerre stamblerre commented Jan 7, 2020

To install gopls, please follow the instructions here. Specifically, you should run GO111MODULE=on go get golang.org/x/tools/gopls.

@Fuxxel

This comment has been minimized.

Copy link
Author

@Fuxxel Fuxxel commented Jan 8, 2020

Thank you for the instructions. I can confirm that this works. This also fixes your vscode Go devcontainer issue: https://github.com/microsoft/vscode-dev-containers/issues/175

@stamblerre

This comment has been minimized.

Copy link
Contributor

@stamblerre stamblerre commented Jan 8, 2020

Thanks for following up. Closing this issue.

@stamblerre stamblerre closed this Jan 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.