Skip to content

x/tools/internal/lsp/regtest: various flakes due to go.mod contention #37318

Closed
@bcmills

Description

@bcmills

https://build.golang.org/log/fe27a791913be11bc439f9612e1ba92f52673e54

2020/02/20 00:34:56 initial workspace load failed: go [list -f {{context.GOARCH}} {{context.Compiler}} -modfile=/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/tmp/go.042197626.mod -- unsafe]: exit status 1: go: open /var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/tmp/go.042197626.mod: no such file or directory

2020/02/20 00:35:01 diagnose: could not generate diagnostics for go.mod file: err: chdir /var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/tmp/goplstest-ws-lsprpc-132098964: no such file or directory: stderr: 
2020/02/20 00:35:04 diagnose: could not generate diagnostics for go.mod file: err: exit status 1: stderr: go: cannot find main module, but -modfile was set.
	-modfile cannot be used to set the module root directory.

2020/02/20 00:35:07 diagnose: could not generate diagnostics for go.mod file: err: exit status 1: stderr: go: open /var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/tmp/go.115179283.mod: no such file or directory

2020/02/20 00:35:08 serving stream: failed reading header line "EOF"
2020/02/20 00:35:37 : context deadline exceeded
--- FAIL: TestGoToStdlibDefinition (37.17s)
    --- FAIL: TestGoToStdlibDefinition/forwarded (30.41s)
        definition_test.go:69: Definition: context deadline exceeded
panic: Shutdown: context deadline exceeded [recovered]
	panic: Shutdown: context deadline exceeded

goroutine 11620 [running]:
testing.tRunner.func1.1(0x1698620, 0xc00c71a0b0)
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/testing/testing.go:941 +0x3d0
testing.tRunner.func1(0xc00a536360)
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/testing/testing.go:944 +0x3f9
panic(0x1698620, 0xc00c71a0b0)
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/runtime/panic.go:967 +0x15d
golang.org/x/tools/internal/lsp/regtest.(*Runner).RunInMode.func1.1(0xc00a1fb140, 0x189f140, 0xc00a1fad80)
	/private/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/gopath/src/golang.org/x/tools/internal/lsp/regtest/env.go:178 +0x70
runtime.Goexit()
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/runtime/panic.go:615 +0x192
testing.(*common).FailNow(0xc00a536360)
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/testing/testing.go:657 +0x39
testing.(*common).Fatal(0xc00a536360, 0xc000a3bd98, 0x1, 0x1)
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/testing/testing.go:718 +0x78
golang.org/x/tools/internal/lsp/regtest.(*Env).GoToDefinition(0xc00a1fb140, 0x17774e5, 0x7, 0x8, 0x13, 0x100ea48, 0x10, 0x16c56a0, 0x173f301)
	/private/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/gopath/src/golang.org/x/tools/internal/lsp/regtest/env.go:310 +0x130
golang.org/x/tools/internal/lsp/regtest.TestGoToStdlibDefinition.func1(0x189f140, 0xc00a1fad80, 0xc00a536360, 0xc00a1fb140)
	/private/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/gopath/src/golang.org/x/tools/internal/lsp/regtest/definition_test.go:69 +0x8d
golang.org/x/tools/internal/lsp/regtest.(*Runner).RunInMode.func1(0xc00a536360)
	/private/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/gopath/src/golang.org/x/tools/internal/lsp/regtest/env.go:181 +0x2af
testing.tRunner(0xc00a536360, 0xc00a508500)
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/testing/testing.go:992 +0xdc
created by testing.(*T).Run
	/var/folders/kh/5zzynz152r94t18yzstnrwx80000gn/T/workdir-host-darwin-10_15/go/src/testing/testing.go:1043 +0x357
FAIL	golang.org/x/tools/internal/lsp/regtest	44.585s

CC @stamblerre @jayconrod @matloob

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.ToolsThis label describes issues relating to any tools in the x/tools repository.goplsIssues related to the Go language server, gopls.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions