Skip to content

gopls: automated issue report (crash) #3514

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

Closed
Fer-Matheus opened this issue Aug 30, 2024 · 1 comment
Closed

gopls: automated issue report (crash) #3514

Fer-Matheus opened this issue Aug 30, 2024 · 1 comment
Labels
automatedReport Automatically created issues
Milestone

Comments

@Fer-Matheus
Copy link

gopls version: v0.16.1/go1.22.4
gopls flags:
update flags: proxy
extension version: 0.42.0
environment: Visual Studio Code win32
initialization error: undefined
issue timestamp: Fri, 30 Aug 2024 03:45:27 GMT
restart history:
Thu, 29 Aug 2024 17:20:36 GMT: activation (enabled: true)
Fri, 30 Aug 2024 02:23:35 GMT: installation (enabled: true)

ATTENTION: PLEASE PROVIDE THE DETAILS REQUESTED BELOW.

Describe what you observed.

panic: file not found for pos = 1 (-)

goroutine 16560 [running]:
go/types.(*Checker).handleBailout(0xc0051ba600, 0xc0056ed898)
	C:/Program   check.go:367  0x88
panic({0xedb900%3F, 0xc005651110%3F})
	C:/Program   panic.go:770  0x132
go/types.(*Checker).fileFor(0xc0051ba600, 0x1)
	C:/Program   version.go:131  0x185
go/types.(*Checker).allowVersion(0xc0051ba600, 0xf59060%3F, {0x1358840%3F, 0xc0021be9a8%3F}, {0x105b68e, 0x6})
	C:/Program   version.go:97  0x5b
go/types.(*Checker).genericExprList(0xc0051ba600, {0xc005650b30, 0x1, 0xc0021be978%3F})
	C:/Program   call.go:383  0xce7
go/types.(*Checker).callExpr(0xc0051ba600, 0xc0051fddc0, 0xc001f91d40)
	C:/Program   call.go:303  0x670
go/types.(*Checker).exprInternal(0xc0051ba600, 0x0, 0xc0051fddc0, {0x135dc30, 0xc001f91d40}, {0x0, 0x0})
	C:/Program   expr.go:1374  0xf8
go/types.(*Checker).rawExpr(0xc0051ba600, 0x0, 0xc0051fddc0, {0x135dc30%3F, 0xc001f91d40%3F}, {0x0%3F, 0x0%3F}, 0x0)
	C:/Program   expr.go:979  0x19e
go/types.(*Checker).expr(0xc0051ba600, 0xc0051fddc0%3F, 0xc0051fddc0, {0x135dc30%3F, 0xc001f91d40%3F})
	C:/Program   expr.go:1513  0x30
go/types.(*Checker).exprInternal(0xc0051ba600, 0x0, 0xc0051fddc0, {0x135dab0, 0xc001f91e80}, {0x0, 0x0})
	C:/Program   expr.go:1162  0x2469
go/types.(*Checker).rawExpr(0xc0051ba600, 0x0, 0xc0051fddc0, {0x135dab0%3F, 0xc001f91e80%3F}, {0x0%3F, 0x0%3F}, 0x0)
	C:/Program   expr.go:979  0x19e
go/types.(*Checker).expr(0xc0051ba600, 0x0%3F, 0xc0051fddc0, {0x135dab0%3F, 0xc001f91e80%3F})
	C:/Program   expr.go:1513  0x30
go/types.(*Checker).initVars(0xc0051ba600, {0xc001a235d0, 0x1, 0x0%3F}, {0xc005650b60, 0xc002e8d348%3F, 0xc005293058%3F}, {0x0, 0x0})
	C:/Program   assignments.go:381  0x60b
go/types.(*Checker).shortVarDecl(0xc0051ba600, {0x1358440, 0xc0002a5590}, {0xc005650af0, 0x1, 0x1%3F}, {0xc005650b60, 0x1, 0x1})
	C:/Program   assignments.go:556  0x8f0
go/types.(*Checker).stmt(0xc0051ba600, 0x0, {0x135dcc0, 0xc001f91ec0})
	C:/Program   stmt.go:473  0x15ff
go/types.(*Checker).stmtList(0xc0051ba600, 0x0, {0xc00563ea00%3F, 0x0%3F, 0x0%3F})
	C:/Program   stmt.go:121  0x85
go/types.(*Checker).funcBody(0xc0051ba600, 0x135a2b8%3F, {0xc00565c470%3F, 0xc005650c20%3F}, 0xc0051fc400, 0xc00563d3e0, {0x0%3F, 0x0%3F})
	C:/Program   stmt.go:41  0x331
go/types.(*Checker).funcDecl.func1()
	C:/Program   decl.go:852  0x3a
go/types.(*Checker).processDelayed(0xc0051ba600, 0x0)
	C:/Program   check.go:467  0x162
go/types.(*Checker).checkFiles(0xc0051ba600, {0xc001a23490, 0x1, 0x1})
	C:/Program   check.go:411  0x1cc
go/types.(*Checker).Files(...)
	C:/Program   check.go:372
golang.org/x/tools/gopls/internal/cache.(*typeCheckBatch).checkPackage(0xc002490a20, {0x135f148, 0xc000331020}, 0xc002794ea0)
	  check.go:1543  0xa25
golang.org/x/tools/gopls/internal/cache.(*typeCheckBatch).handleSyntaxPackage(0xc002490a20, {0x135f148, 0xc000331020}, 0x8, {0xc0006b2b70, 0x14})
	  check.go:568  0x5e5
golang.org/x/tools/gopls/internal/cache.(*Snapshot).forEachPackageInternal.func2()
	  check.go:418  0x2b
golang.org/x/sync/errgroup.(*Group).Go.func1()
	  errgroup.go:78  0x56
created by golang.org/x/sync/errgroup.(*Group).Go in goroutine 16265
	  errgroup.go:75  0x96
gopls stats -anon { "DirStats": { "Files": 55, "TestdataFiles": 0, "GoFiles": 36, "ModFiles": 4, "Dirs": 17 }, "GOARCH": "amd64", "GOOS": "windows", "GOPACKAGESDRIVER": "", "GOPLSCACHE": "", "GoVersion": "go1.22.4", "GoplsVersion": "v0.16.1", "InitialWorkspaceLoadDuration": "4.3614097s", "MemStats": { "HeapAlloc": 24581144, "HeapInUse": 40255488, "TotalAlloc": 372056416 }, "WorkspaceStats": { "Files": { "Total": 1441, "Largest": 395026, "Errs": 0 }, "Views": [ { "GoCommandVersion": "go1.22.4", "AllPackages": { "Packages": 252, "LargestPackage": 148, "CompiledGoFiles": 1431, "Modules": 30 }, "WorkspacePackages": { "Packages": 12, "LargestPackage": 9, "CompiledGoFiles": 36, "Modules": 4 }, "Diagnostics": 4 } ] } }

OPTIONAL: If you would like to share more information, you can attach your complete gopls logs.

NOTE: THESE MAY CONTAIN SENSITIVE INFORMATION ABOUT YOUR CODEBASE.
DO NOT SHARE LOGS IF YOU ARE WORKING IN A PRIVATE REPOSITORY.

<OPTIONAL: ATTACH LOGS HERE>

@gopherbot gopherbot added this to the Untriaged milestone Aug 30, 2024
@hyangah hyangah added the automatedReport Automatically created issues label Sep 5, 2024
@hyangah
Copy link
Contributor

hyangah commented Sep 5, 2024

Thanks for the report @Fer-Matheus !

This is a tricky bug and is tracked in golang/go#66790

@hyangah hyangah closed this as completed Sep 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automatedReport Automatically created issues
Projects
None yet
Development

No branches or pull requests

3 participants