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: panic with latest master #36024

Closed
primalmotion opened this issue Dec 6, 2019 · 2 comments
Closed

x/tools/gopls: panic with latest master #36024

primalmotion opened this issue Dec 6, 2019 · 2 comments
Labels
FrozenDueToAge gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Milestone

Comments

@primalmotion
Copy link

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

$ go version
go version go1.13.4 darwin/amd64

Does this issue reproduce with the latest release?

it happens with latest master. it works on 660eba4

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

go env Output
$ go env
go env
GO111MODULE="auto"
GOARCH="amd64"
GOBIN="/Users/tonio/Documents/Aporeto/workspace/code/go/bin"
GOCACHE="/Users/tonio/Library/Caches/go-build"
GOENV="/Users/tonio/Library/Application Support/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GONOPROXY="go.aporeto.io,github.com/aporeto-inc"
GONOSUMDB="go.aporeto.io,github.com/aporeto-inc"
GOOS="darwin"
GOPATH="/Users/tonio/Documents/Aporeto/workspace/code/go"
GOPRIVATE="go.aporeto.io,github.com/aporeto-inc"
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/Cellar/go/1.13.4/libexec"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/Cellar/go/1.13.4/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
AR="ar"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD="/Users/tonio/Documents/Aporeto/workspace/code/go/src/golang.org/x/tools/go.mod"
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 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/hc/3p6xvgw97kl124_y5p18kk6m0000gn/T/go-build289374822=/tmp/go-build -gno-record-gcc-switches -fno-common"

What did you do?

nothing. just loading VSCode

What did you expect to see?

it should work

What did you see instead?

It panics

failed to load snapshot: no packages found for query ./...
	directory = file:///Users/tonio/Documents/Aporeto/workspace/code/javascript/junon
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x15939b5]

goroutine 77997 [running]:
golang.org/x/tools/internal/lsp/cache.(*snapshot).View(0x0, 0xc0591700b0, 0x1848240)
	/Users/tonio/Documents/Aporeto/workspace/code/go/src/golang.org/x/tools/internal/lsp/cache/snapshot.go:61 +0x5
golang.org/x/tools/internal/lsp.(*Server).diagnoseSnapshot(0xc000234120, 0x1851c20, 0x0)
	/Users/tonio/Documents/Aporeto/workspace/code/go/src/golang.org/x/tools/internal/lsp/diagnostics.go:20 +0x69
created by golang.org/x/tools/internal/lsp.(*Server).addFolders
	/Users/tonio/Documents/Aporeto/workspace/code/go/src/golang.org/x/tools/internal/lsp/general.go:173 +0x600
@gopherbot gopherbot added this to the Unreleased milestone Dec 6, 2019
@gopherbot gopherbot added the Tools This label describes issues relating to any tools in the x/tools repository. label Dec 6, 2019
@gopherbot
Copy link

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.

@gopherbot gopherbot added the gopls Issues related to the Go language server, gopls. label Dec 6, 2019
@heschi
Copy link
Contributor

heschi commented Dec 6, 2019

Closing as duplicate of #36020. Thanks for the report!

@heschi heschi closed this as completed Dec 6, 2019
@golang golang locked and limited conversation to collaborators Dec 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Projects
None yet
Development

No branches or pull requests

3 participants