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

gopls: automated issue report (crash) #3555

Closed
ljf7 opened this issue Sep 29, 2024 · 1 comment
Closed

gopls: automated issue report (crash) #3555

ljf7 opened this issue Sep 29, 2024 · 1 comment
Labels
automatedReport Automatically created issues Duplicate Make it obvious when issues are closed as duplicate
Milestone

Comments

@ljf7
Copy link

ljf7 commented Sep 29, 2024

gopls version: v0.16.2/go1.22.5
gopls flags:
update flags: proxy
extension version: 0.42.1
environment: Visual Studio Code win32
initialization error: undefined
issue timestamp: Sun, 29 Sep 2024 15:27:52 GMT
restart history:
Wed, 25 Sep 2024 03:15:26 GMT: activation (enabled: true)

ATTENTION: PLEASE PROVIDE THE DETAILS REQUESTED BELOW.

Describe what you observed.

panic:   stmt.go:932: assertion failed

goroutine 9180 [running]:
go/types.(*Checker).handleBailout(0xc0000bb000, 0xc0053e3898)
	  check.go:367  0x88
panic({0x17cd9e0%3F, 0xc003e2e870%3F})
	  panic.go:770  0x132
go/types.assert(0x0%3F)
	  errors.go:28  0x54
go/types.(*Checker).rangeStmt(0xc0000bb000, 0x3, 0xc004ebec60)
	  stmt.go:932  0xe70
go/types.(*Checker).stmt(0xc0000bb000, 0x0, {0x1c50640, 0xc004ebec60})
	  stmt.go:827  0xab9
go/types.(*Checker).stmtList(0xc0000bb000, 0x0, {0xc004b516f0%3F, 0xd3421b%3F, 0xd3ab9d%3F})
	  stmt.go:121  0x85
go/types.(*Checker).funcBody(0xc0000bb000, 0x1c4dc50%3F, {0x197ef63%3F, 0xc001eef300%3F}, 0xc001eef2c0, 0xc0064967b0, {0x0%3F, 0x0%3F})
	  stmt.go:41  0x331
go/types.(*Checker).exprInternal.func1()
	  expr.go:1089  0x3b
go/types.(*Checker).processDelayed(0xc0000bb000, 0x7)
	  check.go:467  0x162
go/types.(*Checker).stmt(0xc0000bb000, 0x0, {0x1c50910, 0xc005a636c0})
	  stmt.go:832  0x264a
go/types.(*Checker).stmtList(0xc0000bb000, 0x0, {0xc005a636e0%3F, 0x0%3F, 0x0%3F})
	  stmt.go:121  0x85
go/types.(*Checker).funcBody(0xc0000bb000, 0x1c4dc50%3F, {0xc0013d0a30%3F, 0xc0035118c0%3F}, 0xc003511840, 0xc0064967e0, {0x0%3F, 0x0%3F})
	  stmt.go:41  0x331
go/types.(*Checker).funcDecl.func1()
	  decl.go:852  0x3a
go/types.(*Checker).processDelayed(0xc0000bb000, 0x0)
	  check.go:467  0x162
go/types.(*Checker).checkFiles(0xc0000bb000, {0xc003e2e6f0, 0x2, 0x2})
	  check.go:411  0x1cc
go/types.(*Checker).Files(...)
	  check.go:372
golang.org/x/tools/gopls/internal/cache.(*typeCheckBatch).checkPackage(0xc0046f1440, {0x1c518e8, 0xc0060bdda0}, 0xc0019ae480)
	  check.go:1543  0xa25
golang.org/x/tools/gopls/internal/cache.(*typeCheckBatch).handleSyntaxPackage(0xc0046f1440, {0x1c518e8, 0xc0060bdda0}, 0x0, {0xc0013d0360, 0xd})
	  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 159
	  errgroup.go:75  0x96
gopls stats -anon { "DirStats": { "Files": 2704, "TestdataFiles": 0, "GoFiles": 1410, "ModFiles": 6, "Dirs": 746 }, "GOARCH": "amd64", "GOOS": "windows", "GOPACKAGESDRIVER": "", "GOPLSCACHE": "", "GoVersion": "go1.22.5", "GoplsVersion": "v0.16.2", "InitialWorkspaceLoadDuration": "316.0519ms", "MemStats": { "HeapAlloc": 1802360, "HeapInUse": 3842048, "TotalAlloc": 80681488 }, "WorkspaceStats": { "Files": { "Total": 0, "Largest": 0, "Errs": 0 }, "Views": [ { "GoCommandVersion": "go1.22.5", "AllPackages": { "Packages": 0, "LargestPackage": 0, "CompiledGoFiles": 0, "Modules": 0 }, "WorkspacePackages": { "Packages": 0, "LargestPackage": 0, "CompiledGoFiles": 0, "Modules": 0 }, "Diagnostics": 0 } ] } }

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 Sep 29, 2024
@hyangah
Copy link
Contributor

hyangah commented Oct 2, 2024

Thanks for the report @ljf7
This is a duplicate of golang/go#68334, which is fixed in go1.22.6+/go1.23.
Please upgrade your go to the latest version (go.dev/dl) and reinstall gopls. Thanks!

@hyangah hyangah closed this as not planned Won't fix, can't repro, duplicate, stale Oct 2, 2024
@hyangah hyangah added automatedReport Automatically created issues Duplicate Make it obvious when issues are closed as duplicate labels Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automatedReport Automatically created issues Duplicate Make it obvious when issues are closed as duplicate
Projects
None yet
Development

No branches or pull requests

3 participants