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: moving a file from package A into package B confuses gopls #38977

Open
firelizzard18 opened this issue May 9, 2020 · 4 comments
Open
Labels
Milestone

Comments

@firelizzard18
Copy link

@firelizzard18 firelizzard18 commented May 9, 2020

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

$ go version
go version go1.14.1 windows/amd64

Does this issue reproduce with the latest release?

Yes, and I am using a recent build of gopls from master.

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

go env Output
$ go env
set GO111MODULE=
set GOARCH=amd64
set GOBIN=
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=amd64
set GOHOSTOS=windows
set GOINSECURE=
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=c:\go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=c:\go\pkg\tool\windows_amd64
set GCCGO=gccgo
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=C:\Source\tests\gopls-issue\go.mod
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Tools\Cygwin\tmp\go-build213407714=/tmp/go-build -gno-record-gcc-switches

What did you do?

I am using Visual Studio Code with the vscode-go extension and gopls enabled.

https://gitlab.com/ethan.reesor/contrib/gopls-issue-38977

  • go.mod
  • a
    • a.go - package a
  • b
    • b.go - package b, references a
  • c
    • c.go - package c

Move c.go into b.

What did you expect to see?

All errors resolve once I update c.go to have package b.

What did you see instead?

gopls breaks and stays broken, even after all files in b have package b.

gopls log
[Info  - 3:14:36 PM] 2020/05/09 15:14:36 
	message="Build info\n----------\nversion master, built in $GOPATH mode\n\nGo info\n-------\ngo version go1.14.1 windows/amd64\n\n"
[Info  - 3:14:36 PM] 2020/05/09 15:14:36 
	message="go/packages.Load"
	snapshot=0
	directory=C:\Source\tests\gopls-issue
	query=[./ builtin]
	packages=2
[Info  - 3:14:37 PM] 2020/05/09 15:14:37 
	message="go env for C:\\Source\\tests\\gopls-issue\n(valid build configuration = false)\n(build flags: [])\nset GO111MODULE=\nset GOARCH=amd64\nset GOBIN=\nset GOCACHE=C:\\Users\\ME\\AppData\\Local\\go-build\nset GOENV=C:\\Users\\ME\\AppData\\Roaming\\go\\env\nset GOEXE=.exe\nset GOFLAGS=\nset GOHOSTARCH=amd64\nset GOHOSTOS=windows\nset GOINSECURE=\nset GONOPROXY=\nset GONOSUMDB=\nset GOOS=windows\nset GOPATH=C:\\Users\\ME\\.go\nset GOPRIVATE=\nset GOPROXY=https://proxy.golang.org,direct\nset GOROOT=c:\\go\nset GOSUMDB=sum.golang.org\nset GOTMPDIR=\nset GOTOOLDIR=c:\\go\\pkg\\tool\\windows_amd64\nset GCCGO=gccgo\nset AR=ar\nset CC=gcc\nset CXX=g++\nset CGO_ENABLED=1\nset GOMOD=\nset CGO_CFLAGS=-g -O2\nset CGO_CPPFLAGS=\nset CGO_CXXFLAGS=-g -O2\nset CGO_FFLAGS=-g -O2\nset CGO_LDFLAGS=-g -O2\nset PKG_CONFIG=pkg-config\nset GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\\Users\\FIRELI~1\\AppData\\Local\\Temp\\go-build525093418=/tmp/go-build -gno-record-gcc-switches\n"
[Info  - 3:14:37 PM] 2020/05/09 15:14:37 
	message="go/packages.Load"
	snapshot=0
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:40 PM] 2020/05/09 15:14:40 
	message="go/packages.Load"
	snapshot=1
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:40 PM] 2020/05/09 15:14:40 
	message="go/packages.Load"
	snapshot=1
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go]
	packages=0
[Error - 3:14:40 PM] 2020/05/09 15:14:40 
	message="failed to compute document links"
	error=no PackageHandles
	URI=file:///C:/Source/tests/gopls-issue/a/a.go
[Info  - 3:14:41 PM] 2020/05/09 15:14:41 
	message="go/packages.Load"
	snapshot=1
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go]
	packages=0
[Info  - 3:14:41 PM] 2020/05/09 15:14:41 
	message="go/packages.Load"
	snapshot=1
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go]
	packages=0
[Error - 3:14:41 PM] 2020/05/09 15:14:41 
	message="DocumentSymbols failed"
	error=getting file for DocumentSymbols: no PackageHandles
	URI=file:///C:/Source/tests/gopls-issue/a/a.go
[Error - 3:14:41 PM] Request textDocument/codeLens failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Error - 3:14:41 PM] Request textDocument/codeLens failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Error - 3:14:41 PM] Request textDocument/foldingRange failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Error - 3:14:41 PM] Request textDocument/codeLens failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Info  - 3:14:41 PM] 2020/05/09 15:14:41 
	message="go/packages.Load"
	snapshot=2
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:41 PM] 2020/05/09 15:14:41 
	message="go/packages.Load"
	snapshot=2
	package_path="command-line-arguments"
	files=[C:\Source\tests\gopls-issue\a\a.go]
[Info  - 3:14:41 PM] 2020/05/09 15:14:41 
	message="go/packages.Load"
	snapshot=2
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go]
	packages=1
[Error - 3:14:41 PM] 2020/05/09 15:14:41 
	message="no completions found"
	error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected 'package', found p (and 2 more errors))], list errors: []
	position={0 1}
[Error - 3:14:41 PM] 2020/05/09 15:14:41 
	message="no completions found"
	error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected 'package', found pack (and 2 more errors))], list errors: []
	position={0 4}
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=5
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="warning: diagnose package"
	error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected 'package', found pack (and 2 more errors))], list errors: []
	snapshot=5
	package="command-line-arguments"
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="no completions found"
	error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected 'package', found packa (and 2 more errors))], list errors: []
	position={0 5}
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=6
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="warning: diagnose package"
	error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected 'package', found packa (and 2 more errors))], list errors: []
	snapshot=6
	package="command-line-arguments"
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="no completions found"
	error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:1: expected 'package', found packag (and 2 more errors))], list errors: []
	position={0 6}
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="no completions found"
	error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:8: expected ';', found 'EOF' (and 1 more errors))], list errors: []
	position={0 7}
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=9
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="warning: diagnose package"
	error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\a\a.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/a/a.go (C:\Source\tests\gopls-issue\a\a.go:1:9: expected ';', found 'EOF' (and 1 more errors))], list errors: []
	snapshot=9
	package="command-line-arguments"
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=10
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=10
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go]
	packages=1
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=10
	package_path="command-line-arguments"
	files=[C:\Source\tests\gopls-issue\a\a.go]
[Error - 3:14:42 PM] 2020/05/09 15:14:42 
	message="no completions found"
	error=this is a definition
	position={0 9}
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=10
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go]
	packages=1
[Info  - 3:14:42 PM] 2020/05/09 15:14:42 
	message="go/packages.Load"
	snapshot=10
	package_path="command-line-arguments"
	files=[C:\Source\tests\gopls-issue\a\a.go]
[Info  - 3:14:43 PM] 2020/05/09 15:14:43 
	message="go/packages.Load"
	snapshot=11
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:43 PM] 2020/05/09 15:14:43 
	message="go/packages.Load"
	snapshot=12
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:43 PM] 2020/05/09 15:14:43 
	message="go/packages.Load"
	snapshot=17
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:14:43 PM] 2020/05/09 15:14:43 
	message="DocumentSymbols failed"
	error=invalid pos
	URI=file:///C:/Source/tests/gopls-issue/a/a.go
[Error - 3:14:46 PM] 2020/05/09 15:14:46 
	message="no completions found"
	error=this is a definition of func F(invalid type)
	position={2 6}
[Info  - 3:14:46 PM] 2020/05/09 15:14:46 
	message="go/packages.Load"
	snapshot=18
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:46 PM] 2020/05/09 15:14:46 
	message="go/packages.Load"
	snapshot=19
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:47 PM] 2020/05/09 15:14:47 
	message="go/packages.Load"
	snapshot=21
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:14:47 PM] 2020/05/09 15:14:47 
	message="no signature help"
	error=cannot find an enclosing function
	position={2 11}
[Info  - 3:14:47 PM] 2020/05/09 15:14:47 
	message="go/packages.Load"
	snapshot=23
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:47 PM] 2020/05/09 15:14:47 
	message="go/packages.Load"
	snapshot=24
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:47 PM] 2020/05/09 15:14:47 
	message="go/packages.Load"
	snapshot=25
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:48 PM] 2020/05/09 15:14:48 
	message="go/packages.Load"
	snapshot=26
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:48 PM] 2020/05/09 15:14:48 
	message="go/packages.Load"
	snapshot=27
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:49 PM] 2020/05/09 15:14:49 
	message="go/packages.Load"
	snapshot=32
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:49 PM] 2020/05/09 15:14:49 
	message="go/packages.Load"
	snapshot=33
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:49 PM] 2020/05/09 15:14:49 
	message="go/packages.Load"
	snapshot=34
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:50 PM] 2020/05/09 15:14:50 
	message="go/packages.Load"
	snapshot=36
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:50 PM] 2020/05/09 15:14:50 
	message="go/packages.Load"
	snapshot=37
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:51 PM] 2020/05/09 15:14:51 
	message="go/packages.Load"
	snapshot=41
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:51 PM] 2020/05/09 15:14:51 
	message="go/packages.Load"
	snapshot=42
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:51 PM] 2020/05/09 15:14:51 
	message="go/packages.Load"
	snapshot=48
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:52 PM] 2020/05/09 15:14:52 
	message="go/packages.Load"
	snapshot=50
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:57 PM] 2020/05/09 15:14:57 
	message="go/packages.Load"
	snapshot=51
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:57 PM] 2020/05/09 15:14:57 
	message="go/packages.Load"
	snapshot=51
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\b.go]
	packages=0
[Error - 3:14:57 PM] 2020/05/09 15:14:57 
	message="failed to compute document links"
	error=no PackageHandles
	URI=file:///C:/Source/tests/gopls-issue/b/b.go
[Info  - 3:14:57 PM] 2020/05/09 15:14:57 
	message="go/packages.Load"
	snapshot=51
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\b.go]
	packages=0
[Info  - 3:14:57 PM] 2020/05/09 15:14:57 
	message="go/packages.Load"
	snapshot=51
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\b.go]
	packages=0
[Error - 3:14:57 PM] Request textDocument/foldingRange failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/b.go (C:\Source\tests\gopls-issue\b\b.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Error - 3:14:57 PM] 2020/05/09 15:14:57 
	message="DocumentSymbols failed"
	error=getting file for DocumentSymbols: no PackageHandles
	URI=file:///C:/Source/tests/gopls-issue/b/b.go
[Error - 3:14:57 PM] Request textDocument/codeLens failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/b.go (C:\Source\tests\gopls-issue\b\b.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Error - 3:14:57 PM] Request textDocument/codeLens failed.
  Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/b.go (C:\Source\tests\gopls-issue\b\b.go:1:1: expected ';', found 'EOF' (and 2 more errors))
  Code: 0 
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=53
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=53
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\b.go]
	packages=1
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=53
	package_path="command-line-arguments"
	files=[C:\Source\tests\gopls-issue\b\b.go]
[Error - 3:14:58 PM] 2020/05/09 15:14:58 
	message="no completions found"
	error=getting file for Completion: no ParseGoHandle for file:///C:/Source/tests/gopls-issue/b/b.go
	position={0 2}
[Error - 3:14:58 PM] 2020/05/09 15:14:58 
	message="no completions found"
	error=getting file for Completion: no ParseGoHandle for file:///C:/Source/tests/gopls-issue/b/b.go
	position={0 5}
[Error - 3:14:58 PM] 2020/05/09 15:14:58 
	message="no completions found"
	error=getting file for Completion: no ParseGoHandle for file:///C:/Source/tests/gopls-issue/b/b.go
	position={0 6}
[Error - 3:14:58 PM] 2020/05/09 15:14:58 
	message="no completions found"
	error=getting file for Completion: no ParseGoHandle for file:///C:/Source/tests/gopls-issue/b/b.go
	position={0 7}
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=59
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=60
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=60
	package_path="command-line-arguments"
	files=[C:\Source\tests\gopls-issue\b\b.go]
[Info  - 3:14:58 PM] 2020/05/09 15:14:58 
	message="go/packages.Load"
	snapshot=60
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\b.go]
	packages=1
[Error - 3:14:58 PM] 2020/05/09 15:14:58 
	message="no completions found"
	error=this is a definition
	position={0 9}
[Info  - 3:14:59 PM] 2020/05/09 15:14:59 
	message="go/packages.Load"
	snapshot=60
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\a\a.go file=C:\Source\tests\gopls-issue\b\b.go]
	packages=1
[Info  - 3:14:59 PM] 2020/05/09 15:14:59 
	message="go/packages.Load"
	snapshot=60
	package_path="command-line-arguments"
	files=[C:\Source\tests\gopls-issue\a\a.go]
[Info  - 3:15:00 PM] 2020/05/09 15:15:00 
	message="go/packages.Load"
	snapshot=62
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:00 PM] 2020/05/09 15:15:00 
	message="go/packages.Load"
	snapshot=64
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:00 PM] 2020/05/09 15:15:00 
	message="go/packages.Load"
	snapshot=67
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:15:00 PM] 2020/05/09 15:15:00 
	message="DocumentSymbols failed"
	error=invalid pos
	URI=file:///C:/Source/tests/gopls-issue/b/b.go
[Error - 3:15:02 PM] 2020/05/09 15:15:02 
	message="no completions found"
	error=this is a definition of func F(invalid type)
	position={2 6}
[Info  - 3:15:02 PM] 2020/05/09 15:15:02 
	message="go/packages.Load"
	snapshot=68
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:02 PM] 2020/05/09 15:15:02 
	message="go/packages.Load"
	snapshot=69
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:02 PM] 2020/05/09 15:15:02 
	message="go/packages.Load"
	snapshot=71
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:15:03 PM] 2020/05/09 15:15:03 
	message="no signature help"
	error=cannot find an enclosing function
	position={2 11}
[Info  - 3:15:03 PM] 2020/05/09 15:15:03 
	message="go/packages.Load"
	snapshot=74
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:03 PM] 2020/05/09 15:15:03 
	message="go/packages.Load"
	snapshot=75
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:03 PM] 2020/05/09 15:15:03 
	message="go/packages.Load"
	snapshot=76
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:03 PM] 2020/05/09 15:15:03 
	message="go/packages.Load"
	snapshot=77
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:04 PM] 2020/05/09 15:15:04 
	message="go/packages.Load"
	snapshot=78
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:15:04 PM] Request textDocument/codeAction failed.
  Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:5:1: expected selector or type assertion, found '}' (and 2 more errors)
  Code: 0 
[Info  - 3:15:04 PM] 2020/05/09 15:15:04 
	message="go/packages.Load"
	snapshot=79
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:04 PM] 2020/05/09 15:15:04 
	message="go/packages.Load"
	snapshot=80
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Error - 3:15:05 PM] 2020/05/09 15:15:05 
	message="no signature help"
	error=cannot find an enclosing function
	position={3 9}
[Info  - 3:15:05 PM] 2020/05/09 15:15:05 
	message="go/packages.Load"
	snapshot=84
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:06 PM] 2020/05/09 15:15:06 
	message="go/packages.Load"
	snapshot=86
	directory=C:\Source\tests\gopls-issue
	query=[./]
	packages=1
[Info  - 3:15:10 PM] 2020/05/09 15:15:10 
	message="go/packages.Load"
	snapshot=87
	directory=C:\Source\tests\gopls-issue
	query=[./... builtin]
	packages=0
[Error - 3:15:10 PM] 2020/05/09 15:15:10 
	message="initial workspace load failed"
	error=go [-e -json -compiled=true -test=true -export=false -deps=true -find=false -modfile=C:\Users\FIRELI~1\AppData\Local\Temp\go.gopls-issue.065928451.mod -- ./... builtin]: exit status 1: go: cannot determine module path for source directory C:\Source\tests\gopls-issue (outside GOPATH, module path must be specified)

Example usage:
'go mod init example.com/m' to initialize a v0 or v1 module
'go mod init example.com/m/v2' to initialize a v2 module

Run 'go help mod init' for more information.

[Error - 3:15:10 PM] 2020/05/09 15:15:10
message="warning: diagnose go.mod"
error=err: exit status 1: stderr: go: cannot determine module path for source directory C:\Source\tests\gopls-issue (outside GOPATH, module path must be specified)

Example usage:
'go mod init example.com/m' to initialize a v0 or v1 module
'go mod init example.com/m/v2' to initialize a v2 module

Run 'go help mod init' for more information.

directory=C:\Source\tests\gopls-issue

[Error - 3:15:11 PM] 2020/05/09 15:15:11
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: unknown directive: m
directory=C:\Source\tests\gopls-issue
[Error - 3:15:11 PM] 2020/05/09 15:15:11
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: unknown directive: mo
directory=C:\Source\tests\gopls-issue
[Error - 3:15:11 PM] 2020/05/09 15:15:11
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: unknown directive: mod
directory=C:\Source\tests\gopls-issue
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: unknown directive: modu
directory=C:\Source\tests\gopls-issue
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: unknown directive: modul
directory=C:\Source\tests\gopls-issue
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: usage: module module/path
directory=C:\Source\tests\gopls-issue
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="warning: diagnose go.mod"
error=C:\Source\tests\gopls-issue\go.mod:1: usage: module module/path
directory=C:\Source\tests\gopls-issue
[Error - 3:15:12 PM] Request textDocument/codeLens failed.
Message: C:\Source\tests\gopls-issue\go.mod:1: usage: module module/path
Code: 0
[Error - 3:15:12 PM] Request textDocument/codeLens failed.
Message: C:\Source\tests\gopls-issue\go.mod:1: usage: module module/path
Code: 0
[Info - 3:15:12 PM] 2020/05/09 15:15:12
message="background imports cache refresh starting"
[Info - 3:15:12 PM] 2020/05/09 15:15:12
message="background refresh finished after 22.9999ms"
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="warning: diagnose go.mod"
error=no parsed file for file:///C:/Source/tests/gopls-issue/go.mod
directory=C:\Source\tests\gopls-issue
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="Load concurrency error, will retry serially"
error=exit status 1
[Error - 3:15:12 PM] 2020/05/09 15:15:12
message="warning: diagnose go.mod"
error=no parsed file for file:///C:/Source/tests/gopls-issue/go.mod
directory=C:\Source\tests\gopls-issue
[Error - 3:15:13 PM] 2020/05/09 15:15:13
message="warning: diagnose go.mod"
error=no parsed file for file:///C:/Source/tests/gopls-issue/go.mod
directory=C:\Source\tests\gopls-issue
[Error - 3:15:14 PM] 2020/05/09 15:15:14
message="warning: diagnose go.mod"
error=no parsed file for file:///C:/Source/tests/gopls-issue/go.mod
directory=C:\Source\tests\gopls-issue
[Info - 3:15:20 PM] 2020/05/09 15:15:20
message="go/packages.Load"
snapshot=132
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\b.go]
packages=1
[Info - 3:15:20 PM] 2020/05/09 15:15:20
message="go/packages.Load"
snapshot=132
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go]
[Info - 3:15:20 PM] 2020/05/09 15:15:20
message="go/packages.Load"
snapshot=132
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go]
[Info - 3:15:20 PM] 2020/05/09 15:15:20
message="go/packages.Load"
snapshot=132
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\b.go]
packages=1
[Error - 3:15:25 PM] Request textDocument/codeAction failed.
Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:5:1: expected selector or type assertion, found '}' (and 2 more errors)
Code: 0
[Info - 3:15:26 PM] 2020/05/09 15:15:26
message="go/packages.Load"
snapshot=140
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\b.go]
packages=1
[Info - 3:15:26 PM] 2020/05/09 15:15:26
message="go/packages.Load"
snapshot=140
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go]
[Error - 3:15:26 PM] 2020/05/09 15:15:26
message="no signature help"
error=cannot find an enclosing function
position={5 6}
[Error - 3:15:28 PM] 2020/05/09 15:15:28
message="no signature help"
error=cannot find an enclosing function
position={5 9}
[Info - 3:15:35 PM] 2020/05/09 15:15:35
message="go/packages.Load"
snapshot=146
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=0
[Info - 3:15:36 PM] 2020/05/09 15:15:36
message="go/packages.Load"
snapshot=146
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=0
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="failed to compute document links"
error=no PackageHandles
URI=file:///C:/Source/tests/gopls-issue/c/c.go
[Info - 3:15:36 PM] 2020/05/09 15:15:36
message="go/packages.Load"
snapshot=146
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=0
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="DocumentSymbols failed"
error=getting file for DocumentSymbols: no PackageHandles
URI=file:///C:/Source/tests/gopls-issue/c/c.go
[Error - 3:15:36 PM] Request textDocument/foldingRange failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected ';', found 'EOF' (and 2 more errors))
Code: 0
[Error - 3:15:36 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected ';', found 'EOF' (and 2 more errors))
Code: 0
[Error - 3:15:36 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected ';', found 'EOF' (and 2 more errors))
Code: 0
[Info - 3:15:36 PM] 2020/05/09 15:15:36
message="go/packages.Load"
snapshot=146
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=0
[Info - 3:15:36 PM] 2020/05/09 15:15:36
message="go/packages.Load"
snapshot=148
package_path="command-line-arguments"
files=[C:\Source\tests\gopls-issue\c\c.go]
[Info - 3:15:36 PM] 2020/05/09 15:15:36
message="go/packages.Load"
snapshot=148
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=1
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="no completions found"
error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found pa (and 2 more errors))], list errors: []
position={0 2}
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="warning: diagnose package"
error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found pac (and 2 more errors))], list errors: []
snapshot=149
package="command-line-arguments"
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="warning: diagnose package"
error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found pack (and 2 more errors))], list errors: []
snapshot=150
package="command-line-arguments"
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="no completions found"
error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found pack (and 2 more errors))], list errors: []
position={0 4}
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="warning: diagnose package"
error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found packa (and 2 more errors))], list errors: []
snapshot=151
package="command-line-arguments"
[Error - 3:15:36 PM] 2020/05/09 15:15:36
message="no completions found"
error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found packa (and 2 more errors))], list errors: []
position={0 5}
[Error - 3:15:37 PM] 2020/05/09 15:15:37
message="warning: diagnose package"
error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found packag (and 2 more errors))], list errors: []
snapshot=152
package="command-line-arguments"
[Error - 3:15:37 PM] 2020/05/09 15:15:37
message="no completions found"
error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:1: expected 'package', found packag (and 2 more errors))], list errors: []
position={0 6}
[Error - 3:15:37 PM] 2020/05/09 15:15:37
message="warning: diagnose package"
error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:8: expected ';', found 'EOF' (and 1 more errors))], list errors: []
snapshot=153
package="command-line-arguments"
[Error - 3:15:37 PM] 2020/05/09 15:15:37
message="no completions found"
error=getting file for Completion: no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:8: expected ';', found 'EOF' (and 1 more errors))], list errors: []
position={0 7}
[Error - 3:15:37 PM] 2020/05/09 15:15:37
message="warning: diagnose package"
error=no parsed files for package command-line-arguments, expected: [C:\Source\tests\gopls-issue\c\c.go], errors: [successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/c/c.go (C:\Source\tests\gopls-issue\c\c.go:1:9: expected ';', found 'EOF' (and 1 more errors))], list errors: []
snapshot=154
package="command-line-arguments"
[Info - 3:15:37 PM] 2020/05/09 15:15:37
message="go/packages.Load"
snapshot=155
package_path="command-line-arguments"
files=[C:\Source\tests\gopls-issue\c\c.go]
[Info - 3:15:37 PM] 2020/05/09 15:15:37
message="go/packages.Load"
snapshot=155
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=1
[Info - 3:15:37 PM] 2020/05/09 15:15:37
message="go/packages.Load"
snapshot=155
package_path="command-line-arguments"
files=[C:\Source\tests\gopls-issue\c\c.go]
[Info - 3:15:37 PM] 2020/05/09 15:15:37
message="go/packages.Load"
snapshot=155
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=1
[Error - 3:15:37 PM] 2020/05/09 15:15:37
message="no completions found"
error=this is a definition
position={0 9}
[Error - 3:15:39 PM] 2020/05/09 15:15:39
message="DocumentSymbols failed"
error=invalid pos
URI=file:///C:/Source/tests/gopls-issue/c/c.go
[Error - 3:15:39 PM] 2020/05/09 15:15:39
message="no completions found"
error=this is a definition of func F(invalid type)
position={2 6}
[Error - 3:15:40 PM] 2020/05/09 15:15:40
message="no signature help"
error=cannot find an enclosing function
position={2 12}
[Error - 3:15:42 PM] 2020/05/09 15:15:42
message="no signature help"
error=no builtin package for view gopls-issue
position={3 9}
[Info - 3:15:54 PM] 2020/05/09 15:15:54
message="background imports cache refresh starting"
[Info - 3:15:54 PM] 2020/05/09 15:15:54
message="background refresh finished after 136.0003ms"
[Info - 3:15:54 PM] 2020/05/09 15:15:54
message="go/packages.Load"
snapshot=192
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:15:54 PM] 2020/05/09 15:15:54
message="go/packages.Load"
snapshot=192
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:15:58 PM] 2020/05/09 15:15:58
message="go/packages.Load"
snapshot=194
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:15:58 PM] 2020/05/09 15:15:58
message="go/packages.Load"
snapshot=194
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Error - 3:15:58 PM] 2020/05/09 15:15:58
message="no completions found"
error=this is a definition
position={0 9}
[Info - 3:15:58 PM] 2020/05/09 15:15:58
message="go/packages.Load"
snapshot=194
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:15:58 PM] 2020/05/09 15:15:58
message="go/packages.Load"
snapshot=194
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:15:59 PM] 2020/05/09 15:15:59
message="go/packages.Load"
snapshot=195
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:15:59 PM] 2020/05/09 15:15:59
message="go/packages.Load"
snapshot=195
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:04 PM] 2020/05/09 15:16:04
message="no completions found"
error=this is a definition of func Func2()
position={2 10}
[Info - 3:16:05 PM] 2020/05/09 15:16:05
message="go/packages.Load"
snapshot=196
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:05 PM] 2020/05/09 15:16:05
message="go/packages.Load"
snapshot=197
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:05 PM] 2020/05/09 15:16:05
message="go/packages.Load"
snapshot=197
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:14 PM] 2020/05/09 15:16:14
message="go/packages.Load"
snapshot=198
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=199
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=199
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Error - 3:16:15 PM] Request textDocument/foldingRange failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:16:15 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:16:15 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:16:15 PM] 2020/05/09 15:16:15
message="DocumentSymbols failed"
error=successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
URI=file:///C:/Source/tests/gopls-issue/b/c.go
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=199
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=200
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=200
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=200
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=200
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:15 PM] 2020/05/09 15:16:15
message="go/packages.Load"
snapshot=200
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:16 PM] 2020/05/09 15:16:16
message="warning: diagnose go.mod"
error=no parsed file for file:///C:/Source/tests/gopls-issue/go.mod
directory=C:\Source\tests\gopls-issue
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=201
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=201
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=202
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=202
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=202
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=202
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:16 PM] 2020/05/09 15:16:16
message="go/packages.Load"
snapshot=202
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:17 PM] 2020/05/09 15:16:17
message="go/packages.Load"
snapshot=202
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:17 PM] 2020/05/09 15:16:17
message="go/packages.Load"
snapshot=203
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:17 PM] 2020/05/09 15:16:17
message="go/packages.Load"
snapshot=203
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Error - 3:16:17 PM] Request textDocument/foldingRange failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:16:17 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:16:17 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:16:17 PM] 2020/05/09 15:16:17
message="DocumentSymbols failed"
error=successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
URI=file:///C:/Source/tests/gopls-issue/b/c.go
[Info - 3:16:17 PM] 2020/05/09 15:16:17
message="go/packages.Load"
snapshot=204
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:16:17 PM] 2020/05/09 15:16:17
message="go/packages.Load"
snapshot=204
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:18 PM] 2020/05/09 15:16:18
message="go/packages.Load"
snapshot=204
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:18 PM] 2020/05/09 15:16:18
message="go/packages.Load"
snapshot=205
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:19 PM] 2020/05/09 15:16:19
message="go/packages.Load"
snapshot=205
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:22 PM] 2020/05/09 15:16:22
message="go/packages.Load"
snapshot=207
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[C:\Source\tests\gopls-issue\c\c.go]
[Info - 3:16:22 PM] 2020/05/09 15:16:22
message="go/packages.Load"
snapshot=207
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=1
[Info - 3:16:22 PM] 2020/05/09 15:16:22
message="go/packages.Load"
snapshot=207
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b]
packages=1
[Info - 3:16:22 PM] 2020/05/09 15:16:22
message="go/packages.Load"
snapshot=207
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go]
[Info - 3:16:23 PM] 2020/05/09 15:16:23
message="go/packages.Load"
snapshot=208
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:23 PM] 2020/05/09 15:16:23
message="go/packages.Load"
snapshot=208
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:25 PM] 2020/05/09 15:16:25
message="background imports cache refresh starting"
[Info - 3:16:25 PM] 2020/05/09 15:16:25
message="background refresh finished after 89.9802ms"
[Info - 3:16:27 PM] 2020/05/09 15:16:27
message="go/packages.Load"
snapshot=208
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:28 PM] 2020/05/09 15:16:28
message="go/packages.Load"
snapshot=210
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:29 PM] 2020/05/09 15:16:29
message="no completions found"
error=this is a definition of func B()
position={4 6}
[Info - 3:16:29 PM] 2020/05/09 15:16:29
message="go/packages.Load"
snapshot=211
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:30 PM] 2020/05/09 15:16:30
message="go/packages.Load"
snapshot=212
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:30 PM] 2020/05/09 15:16:30
message="go/packages.Load"
snapshot=212
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:31 PM] 2020/05/09 15:16:31
message="go/packages.Load"
snapshot=213
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:31 PM] 2020/05/09 15:16:31
message="go/packages.Load"
snapshot=213
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:32 PM] 2020/05/09 15:16:32
message="no completions found"
error=this is a definition of func C()
position={2 6}
[Info - 3:16:33 PM] 2020/05/09 15:16:33
message="go/packages.Load"
snapshot=214
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:33 PM] 2020/05/09 15:16:33
message="go/packages.Load"
snapshot=215
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:33 PM] 2020/05/09 15:16:33
message="go/packages.Load"
snapshot=215
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:16:36 PM] 2020/05/09 15:16:36
message="go/packages.Load"
snapshot=217
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:16:36 PM] 2020/05/09 15:16:36
message="go/packages.Load"
snapshot=217
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:16:40 PM] 2020/05/09 15:16:40
message="go/packages.Load"
snapshot=218
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/c]
packages=1
[Info - 3:16:40 PM] 2020/05/09 15:16:40
message="go/packages.Load"
snapshot=218
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[]
[Info - 3:16:40 PM] 2020/05/09 15:16:40
message="go/packages.Load"
snapshot=218
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:40 PM] 2020/05/09 15:16:40
message="warning: diagnose go.mod"
error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
directory=C:\Source\tests\gopls-issue
[Info - 3:16:42 PM] 2020/05/09 15:16:42
message="go/packages.Load"
snapshot=218
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/c]
packages=1
[Info - 3:16:42 PM] 2020/05/09 15:16:42
message="go/packages.Load"
snapshot=218
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[]
[Info - 3:16:42 PM] 2020/05/09 15:16:42
message="go/packages.Load"
snapshot=218
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:42 PM] 2020/05/09 15:16:42
message="failed to load workspace packages, skipping diagnostics"
error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
snapshot=218
directory=file:///C:/Source/tests/gopls-issue
[Error - 3:16:46 PM] Request textDocument/codeAction failed.
Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:8:1: expected selector or type assertion, found '}' (and 2 more errors)
Code: 0
[Error - 3:16:47 PM] 2020/05/09 15:16:47
message="no signature help"
error=cannot find an enclosing function
position={6 7}
[Error - 3:16:47 PM] Request textDocument/codeAction failed.
Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:7:5: expected statement, found ')' (and 2 more errors)
Code: 0
[Error - 3:16:48 PM] 2020/05/09 15:16:48
message="no signature help"
error=cannot find an enclosing function
position={6 6}
[Info - 3:16:52 PM] 2020/05/09 15:16:52
message="go/packages.Load"
snapshot=233
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/c]
packages=1
[Info - 3:16:52 PM] 2020/05/09 15:16:52
message="go/packages.Load"
snapshot=233
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[]
[Info - 3:16:52 PM] 2020/05/09 15:16:52
message="go/packages.Load"
snapshot=233
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:52 PM] 2020/05/09 15:16:52
message="warning: diagnose go.mod"
error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
directory=C:\Source\tests\gopls-issue
[Info - 3:16:53 PM] 2020/05/09 15:16:53
message="go/packages.Load"
snapshot=233
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/c]
packages=1
[Info - 3:16:53 PM] 2020/05/09 15:16:53
message="go/packages.Load"
snapshot=233
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[]
[Info - 3:16:53 PM] 2020/05/09 15:16:53
message="go/packages.Load"
snapshot=233
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:53 PM] 2020/05/09 15:16:53
message="failed to load workspace packages, skipping diagnostics"
error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
snapshot=233
directory=file:///C:/Source/tests/gopls-issue
[Info - 3:16:56 PM] 2020/05/09 15:16:56
message="background imports cache refresh starting"
[Info - 3:16:56 PM] 2020/05/09 15:16:56
message="background refresh finished after 96.9795ms"
[Info - 3:16:57 PM] 2020/05/09 15:16:57
message="go/packages.Load"
snapshot=235
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:16:57 PM] 2020/05/09 15:16:57
message="go/packages.Load"
snapshot=235
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Error - 3:16:57 PM] 2020/05/09 15:16:57
message="no completions found"
error=this is a definition
position={0 9}
[Info - 3:16:59 PM] 2020/05/09 15:16:59
message="go/packages.Load"
snapshot=236
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/c]
packages=1
[Info - 3:16:59 PM] 2020/05/09 15:16:59
message="go/packages.Load"
snapshot=236
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[]
[Info - 3:16:59 PM] 2020/05/09 15:16:59
message="go/packages.Load"
snapshot=236
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Error - 3:16:59 PM] 2020/05/09 15:16:59
message="warning: diagnose go.mod"
error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
directory=C:\Source\tests\gopls-issue
[Error - 3:17:00 PM] Request textDocument/codeAction failed.
Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:8:1: expected selector or type assertion, found '}' (and 2 more errors)
Code: 0
[Error - 3:17:02 PM] Request textDocument/definition failed.
Message: no imported package for gitlab.com/ethan/contrib/gopls-issue/a
Code: 0
[Error - 3:17:02 PM] Request textDocument/codeAction failed.
Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:7:5: expected statement, found ')' (and 2 more errors)
Code: 0
[Error - 3:17:03 PM] Request textDocument/codeAction failed.
Message: computing fix edits: C:\Source\tests\gopls-issue\b\b.go:7:5: expected statement, found ')' (and 2 more errors)
Code: 0
[Error - 3:17:08 PM] Request textDocument/foldingRange failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:17:08 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Info - 3:17:08 PM] 2020/05/09 15:17:08
message="go/packages.Load"
snapshot=250
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:17:08 PM] 2020/05/09 15:17:08
message="go/packages.Load"
snapshot=250
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Error - 3:17:08 PM] Request textDocument/codeLens failed.
Message: successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
Code: 0
[Error - 3:17:08 PM] 2020/05/09 15:17:08
message="DocumentSymbols failed"
error=successfully parsed but no token.File for file:///C:/Source/tests/gopls-issue/b/c.go (C:\Source\tests\gopls-issue\b\c.go:3:1: expected 'IDENT', found 'func' (and 1 more errors))
URI=file:///C:/Source/tests/gopls-issue/b/c.go
[Info - 3:17:08 PM] 2020/05/09 15:17:08
message="go/packages.Load"
snapshot=251
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\b\c.go]
packages=1
[Info - 3:17:08 PM] 2020/05/09 15:17:08
message="go/packages.Load"
snapshot=251
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info - 3:17:10 PM] 2020/05/09 15:17:10
message="go/packages.Load"
snapshot=252
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/c]
packages=1
[Info - 3:17:10 PM] 2020/05/09 15:17:10
message="go/packages.Load"
snapshot=252
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[]
[Info - 3:17:11 PM] 2020/05/09 15:17:11
message="go/packages.Load"
snapshot=254
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\c\c.go]
packages=1
[Info - 3:17:11 PM] 2020/05/09 15:17:11
message="go/packages.Load"
snapshot=254
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[C:\Source\tests\gopls-issue\c\c.go]
[Info - 3:17:11 PM] 2020/05/09 15:17:11
message="go/packages.Load"
snapshot=254
directory=C:\Source\tests\gopls-issue
query=[gitlab.com/ethan/contrib/gopls-issue/b gitlab.com/ethan/contrib/gopls-issue/c]
packages=2
[Info - 3:17:11 PM] 2020/05/09 15:17:11
message="go/packages.Load"
snapshot=254
package_path="gitlab.com/ethan/contrib/gopls-issue/b"
files=[C:\Source\tests\gopls-issue\b\b.go]
[Info - 3:17:11 PM] 2020/05/09 15:17:11
message="go/packages.Load"
snapshot=254
package_path="gitlab.com/ethan/contrib/gopls-issue/c"
files=[C:\Source\tests\gopls-issue\c\c.go]
[Info - 3:17:11 PM] 2020/05/09 15:17:11
message="go/packages.Load"
snapshot=255
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:17:12 PM] 2020/05/09 15:17:12
message="go/packages.Load"
snapshot=255
directory=C:\Source\tests\gopls-issue
query=[file=C:\Source\tests\gopls-issue\found packages b (b.go) and c (c.go) in C:\Source\tests\gopls-issue\b]
packages=0
[Info - 3:17:27 PM] 2020/05/09 15:17:27
message="background imports cache refresh starting"
[Info - 3:17:27 PM] 2020/05/09 15:17:27
message="background refresh finished after 92.4806ms"

@gopherbot gopherbot added this to the Unreleased milestone May 9, 2020
@gopherbot gopherbot added the Tools label May 9, 2020
@gopherbot
Copy link

@gopherbot gopherbot commented May 9, 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.

@gopherbot gopherbot added the gopls label May 9, 2020
@stamblerre stamblerre modified the milestones: Unreleased, gopls/v0.5.0 May 9, 2020
@firelizzard18
Copy link
Author

@firelizzard18 firelizzard18 commented May 9, 2020

When playing around with my repro project, gopls actually crashed:

gopls log
[Info  - 3:30:33 PM] 2020/05/09 15:30:33 
	message="Build info\n----------\nversion master, built in $GOPATH mode\n\nGo info\n-------\ngo version go1.14.1 windows/amd64\n\n"
[Info  - 3:30:34 PM] 2020/05/09 15:30:34 
	message="go/packages.Load"
	snapshot=0
	directory=C:\Source\tests\gopls-issue
	query=[./... builtin]
	packages=4
[Info  - 3:30:34 PM] 2020/05/09 15:30:34 
	message="go env for C:\\Source\\tests\\gopls-issue\n(valid build configuration = true)\n(build flags: [-modfile=C:\\Users\\ME\\AppData\\Local\\Temp\\go.gopls-issue.270555471.mod])\nset GO111MODULE=\nset GOARCH=amd64\nset GOBIN=\nset GOCACHE=C:\\Users\\ME\\AppData\\Local\\go-build\nset GOENV=C:\\Users\\ME\\AppData\\Roaming\\go\\env\nset GOEXE=.exe\nset GOFLAGS=\nset GOHOSTARCH=amd64\nset GOHOSTOS=windows\nset GOINSECURE=\nset GONOPROXY=\nset GONOSUMDB=\nset GOOS=windows\nset GOPATH=C:\\Users\\ME\\.go\nset GOPRIVATE=\nset GOPROXY=https://proxy.golang.org,direct\nset GOROOT=c:\\go\nset GOSUMDB=sum.golang.org\nset GOTMPDIR=\nset GOTOOLDIR=c:\\go\\pkg\\tool\\windows_amd64\nset GCCGO=gccgo\nset AR=ar\nset CC=gcc\nset CXX=g++\nset CGO_ENABLED=1\nset GOMOD=C:\\Source\\tests\\gopls-issue\\go.mod\nset CGO_CFLAGS=-g -O2\nset CGO_CPPFLAGS=\nset CGO_CXXFLAGS=-g -O2\nset CGO_FFLAGS=-g -O2\nset CGO_LDFLAGS=-g -O2\nset PKG_CONFIG=pkg-config\nset GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\\Users\\FIRELI~1\\AppData\\Local\\Temp\\go-build505991338=/tmp/go-build -gno-record-gcc-switches\n"
[Info  - 3:30:49 PM] 2020/05/09 15:30:49 
	message="go/packages.Load"
	snapshot=4
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\c.go]
	packages=1
[Info  - 3:30:49 PM] 2020/05/09 15:30:49 
	message="go/packages.Load"
	snapshot=4
	package_path="gitlab.com/ethan/contrib/gopls-issue/b"
	files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Info  - 3:30:51 PM] 2020/05/09 15:30:51 
	message="go/packages.Load"
	snapshot=5
	directory=C:\Source\tests\gopls-issue
	query=[gitlab.com/ethan/contrib/gopls-issue/c]
	packages=1
[Info  - 3:30:51 PM] 2020/05/09 15:30:51 
	message="go/packages.Load"
	snapshot=5
	package_path="gitlab.com/ethan/contrib/gopls-issue/c"
	files=[]
[Error - 3:30:51 PM] 2020/05/09 15:30:51 
	message="warning: diagnose go.mod"
	error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
	directory=C:\Source\tests\gopls-issue
[Info  - 3:30:52 PM] 2020/05/09 15:30:52 
	message="go/packages.Load"
	snapshot=5
	directory=C:\Source\tests\gopls-issue
	query=[gitlab.com/ethan/contrib/gopls-issue/c]
	packages=1
[Error - 3:30:52 PM] 2020/05/09 15:30:52 
	message="failed to load workspace packages, skipping diagnostics"
	error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
	snapshot=5
	directory=file:///C:/Source/tests/gopls-issue
[Info  - 3:30:52 PM] 2020/05/09 15:30:52 
	message="go/packages.Load"
	snapshot=5
	package_path="gitlab.com/ethan/contrib/gopls-issue/c"
	files=[]
[Error - 3:30:58 PM] Request textDocument/definition failed.
  Message: no object for ident println
  Code: 0 
[Error - 3:31:02 PM] Request textDocument/definition failed.
  Message: no object for ident A
  Code: 0 
[Error - 3:31:02 PM] Request textDocument/definition failed.
  Message: no object for ident A
  Code: 0 
[Error - 3:31:05 PM] Request textDocument/definition failed.
  Message: no object for ident A
  Code: 0 
[Info  - 3:31:09 PM] 2020/05/09 15:31:09 
	message="go/packages.Load"
	snapshot=7
	directory=C:\Source\tests\gopls-issue
	query=[file=C:\Source\tests\gopls-issue\b\c.go]
	packages=1
[Info  - 3:31:09 PM] 2020/05/09 15:31:09 
	message="go/packages.Load"
	snapshot=7
	package_path="gitlab.com/ethan/contrib/gopls-issue/b"
	files=[C:\Source\tests\gopls-issue\b\b.go C:\Source\tests\gopls-issue\b\c.go]
[Error - 3:31:09 PM] 2020/05/09 15:31:09 
	message="no completions found"
	error=this is a definition
	position={0 9}
[Info  - 3:31:12 PM] 2020/05/09 15:31:12 
	message="go/packages.Load"
	snapshot=8
	directory=C:\Source\tests\gopls-issue
	query=[gitlab.com/ethan/contrib/gopls-issue/c]
	packages=1
[Error - 3:31:12 PM] 2020/05/09 15:31:12 
	message="warning: diagnose go.mod"
	error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
	directory=C:\Source\tests\gopls-issue
[Info  - 3:31:12 PM] 2020/05/09 15:31:12 
	message="go/packages.Load"
	snapshot=8
	package_path="gitlab.com/ethan/contrib/gopls-issue/c"
	files=[]
[Info  - 3:31:13 PM] 2020/05/09 15:31:13 
	message="go/packages.Load"
	snapshot=8
	directory=C:\Source\tests\gopls-issue
	query=[gitlab.com/ethan/contrib/gopls-issue/c]
	packages=1
[Info  - 3:31:13 PM] 2020/05/09 15:31:13 
	message="go/packages.Load"
	snapshot=8
	package_path="gitlab.com/ethan/contrib/gopls-issue/c"
	files=[]
[Error - 3:31:13 PM] 2020/05/09 15:31:13 
	message="failed to load workspace packages, skipping diagnostics"
	error=gitlab.com/ethan/contrib/gopls-issue/c has no metadata
	snapshot=8
	directory=file:///C:/Source/tests/gopls-issue
[Error - 3:31:13 PM] Request textDocument/definition failed.
  Message: no object for ident A
  Code: 0 
[Error - 3:31:13 PM] Request textDocument/definition failed.
  Message: no object for ident A
  Code: 0 
[Error - 3:31:14 PM] Request textDocument/definition failed.
  Message: no object for ident A
  Code: 0 
[Info  - 3:31:16 PM] 2020/05/09 15:31:16 
	message="background imports cache refresh starting"
[Info  - 3:31:17 PM] 2020/05/09 15:31:17 
	message="background refresh finished after 656.4837ms"
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x10 pc=0x7b0d8d]

goroutine 587 [running]:
golang.org/x/tools/internal/lsp/source.findIdentifier(0xe383e0, 0xc0003e6ab0, 0xe49160, 0xc000122230, 0xe490c0, 0xc0001e2340, 0xc00036e700, 0x3b4, 0xc00028ea00, 0xc0003a7300, ...)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/source/identifier.go:106 +0x14cd
golang.org/x/tools/internal/lsp/source.Identifier(0xe383e0, 0xc0003e6ab0, 0xe49160, 0xc000122230, 0xe36f60, 0xc000812900, 0x0, 0x4020000000000000, 0x0, 0x0, ...)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/source/identifier.go:71 +0x3d1
golang.org/x/tools/internal/lsp/source.Hover(0xe38320, 0xc001274c80, 0xe49160, 0xc000122230, 0xe36f60, 0xc000812900, 0x0, 0x4020000000000000, 0x0, 0x0, ...)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/source/hover.go:49 +0xa9
golang.org/x/tools/internal/lsp.(*Server).hover(0xc00009b680, 0xe38320, 0xc001274c80, 0xc0003e6a50, 0x0, 0x0, 0xc00011ea50)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/hover.go:24 +0x222
golang.org/x/tools/internal/lsp.(*Server).Hover(0xc00009b680, 0xe38320, 0xc001274c80, 0xc0003e6a50, 0xc0003e6a50, 0x0, 0x0)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/server_gen.go:96 +0x50
golang.org/x/tools/internal/lsp/protocol.ServerHandler.func1(0xe38320, 0xc001274c80, 0xc0003e6a20, 0xe38560, 0xc001274bc0, 0x0, 0x0)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/protocol/tsserver.go:253 +0x140e
golang.org/x/tools/internal/lsp/lsprpc.handshaker.func1(0xe38320, 0xc001274c80, 0xc0003e6a20, 0xe38560, 0xc001274bc0, 0x0, 0x0)
C:/Users/ME/.go/src/golang.org/x/tools/internal/lsp/lsprpc/lsprpc.go:531 +0x558
golang.org/x/tools/internal/jsonrpc2.MustReplyHandler.func1(0xe38320, 0xc001274c80, 0xc000353980, 0xe38560, 0xc001274bc0, 0x1, 0x0)
C:/Users/ME/.go/src/golang.org/x/tools/internal/jsonrpc2/handler.go:35 +0xda
golang.org/x/tools/internal/jsonrpc2.AsyncHandler.func1.2(0xc000c0ed20, 0xc0003cef60, 0xc000392f70, 0xe38320, 0xc001274c80, 0xc000353980, 0xe38560, 0xc001274bc0)
C:/Users/ME/.go/src/golang.org/x/tools/internal/jsonrpc2/handler.go:103 +0x8d
created by golang.org/x/tools/internal/jsonrpc2.AsyncHandler.func1
C:/Users/ME/.go/src/golang.org/x/tools/internal/jsonrpc2/handler.go:100 +0x178
[Info - 3:31:25 PM] Connection to server got closed. Server will restart.
[Error - 3:31:25 PM] Request textDocument/hover failed.
Error: Connection got disposed.
at Object.dispose (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\main.js:904:25)
at Object.dispose (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-languageclient\lib\client.js:74:35)
at LanguageClient.handleConnectionClosed (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-languageclient\lib\client.js:2309:42)
at LanguageClient.handleConnectionClosed (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-languageclient\lib\main.js:155:15)
at closeHandler (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-languageclient\lib\client.js:2296:18)
at CallbackList.invoke (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\events.js:62:39)
at Emitter.fire (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\events.js:121:36)
at closeHandler (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\main.js:240:26)
at CallbackList.invoke (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\events.js:62:39)
at Emitter.fire (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\events.js:121:36)
at StreamMessageReader.fireClose (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\messageReader.js:111:27)
at Socket. (c:\Users\ME.vscode\extensions\ms-vscode.go-0.14.1\node_modules\vscode-jsonrpc\lib\messageReader.js:151:46)
at Socket.emit (events.js:208:15)
at Pipe. (net.js:588:12)
[Info - 3:31:25 PM] 2020/05/09 15:31:25
message="Build info\n----------\nversion master, built in $GOPATH mode\n\nGo info\n-------\ngo version go1.14.1 windows/amd64\n\n"
[Info - 3:31:26 PM] 2020/05/09 15:31:26
message="go/packages.Load"
snapshot=0
directory=C:\Source\tests\gopls-issue
query=[./... builtin]
packages=3
[Info - 3:31:26 PM] 2020/05/09 15:31:26
message="go env for C:\Source\tests\gopls-issue\n(valid build configuration = true)\n(build flags: [-modfile=C:\Users\FIRELI1\AppData\Local\Temp\go.gopls-issue.264393403.mod])\nset GO111MODULE=\nset GOARCH=amd64\nset GOBIN=\nset GOCACHE=C:\Users\ME\AppData\Local\go-build\nset GOENV=C:\Users\ME\AppData\Roaming\go\env\nset GOEXE=.exe\nset GOFLAGS=\nset GOHOSTARCH=amd64\nset GOHOSTOS=windows\nset GOINSECURE=\nset GONOPROXY=\nset GONOSUMDB=\nset GOOS=windows\nset GOPATH=C:\Users\ME\.go\nset GOPRIVATE=\nset GOPROXY=https://proxy.golang.org,direct\nset GOROOT=c:\go\nset GOSUMDB=sum.golang.org\nset GOTMPDIR=\nset GOTOOLDIR=c:\go\pkg\tool\windows_amd64\nset GCCGO=gccgo\nset AR=ar\nset CC=gcc\nset CXX=g++\nset CGO_ENABLED=1\nset GOMOD=C:\Source\tests\gopls-issue\go.mod\nset CGO_CFLAGS=-g -O2\nset CGO_CPPFLAGS=\nset CGO_CXXFLAGS=-g -O2\nset CGO_FFLAGS=-g -O2\nset CGO_LDFLAGS=-g -O2\nset PKG_CONFIG=pkg-config\nset GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\FIRELI1\AppData\Local\Temp\go-build538698030=/tmp/go-build -gno-record-gcc-switches\n"

@firelizzard18
Copy link
Author

@firelizzard18 firelizzard18 commented May 9, 2020

In general, gopls seems to be very bad at recovering from files with invalid or missing package declarations. This is the first time I've been able to characterize it beyond, "it breaks".

@gopherbot
Copy link

@gopherbot gopherbot commented May 10, 2020

Change https://golang.org/cl/233177 mentions this issue: internal/lsp/source: handle nil pointer in package name hover

gopherbot pushed a commit to golang/tools that referenced this issue May 11, 2020
Updates golang/go#38977.

Change-Id: I8cbf0b058d77e749285cfe41b4b49de3764be861
Reviewed-on: https://go-review.googlesource.com/c/tools/+/233177
Run-TryBot: Rebecca Stambler <rstambler@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Heschi Kreinick <heschi@google.com>
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.