golang / vscode-go

Go extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=golang.Go
Other
3.84k stars 735 forks source link

gopls: automated issue report (crash) #3069

Closed aliuygur closed 9 months ago

aliuygur commented 9 months ago

gopls version: v0.14.2 (go1.21.0) gopls flags: update flags: proxy extension version: 0.40.0 go version: 1.21.0 environment: Visual Studio Code darwin initialization error: undefined issue timestamp: Tue, 28 Nov 2023 14:52:10 GMT restart history: Tue, 28 Nov 2023 14:51:45 GMT: activation (enabled: true)

ATTENTION: PLEASE PROVIDE THE DETAILS REQUESTED BELOW.

Describe what you observed.

panic: instantiated ident not found

goroutine 5346 [running]:
go/types.(*Checker).handleBailout(0x140002e1680, 0x14007e8f558)
      check.go:336  0x9c
panic({0x1058f8ae0%3F, 0x105a6fe10%3F})
      panic.go:914  0x218
go/types.instantiatedIdent(...)
      check.go:594
go/types.(*Checker).recordInstance(0x0%3F, {0x105a784a0%3F, 0x14002de7540%3F}, {0x14004f66680%3F, 0x14004f66680%3F, 0x1%3F}, {0x105a751a8%3F, 0x14007f5bec0%3F})
      check.go:570  0x1e4
go/types.(*Checker).instantiateSignature(0x140002e1680, 0x17d, {0x105a784a0, 0x14002de7540}, 0x14007d4bbc0, {0x14004f66680, 0x1, 0x1}, {0x0, 0x0, ...})
      call.go:153  0x244
go/types.(*Checker).arguments(0x140002e1680, 0x14002de7580, 0x14007f5bb00, {0x0, 0x0, 0x0}, {0x0, 0x0, 0x0}, {0x14004f662d0%3F, ...}, ...)
      call.go:638  0x1070
go/types.(*Checker).callExpr(0x140002e1680, 0x14007f5bac0, 0x14002de7580)
      call.go:302  0x6a4
go/types.(*Checker).exprInternal(0x140002e1680, {0x0, 0x0}, 0x14007f5bac0, {0x105a784a0, 0x14002de7580%3F}, {0x0%3F, 0x0%3F})
      expr.go:1359  0x12dc
go/types.(*Checker).rawExpr(0x140002e1680, {0x0, 0x0}, 0x14007f5bac0, {0x105a784a0%3F, 0x14002de7580%3F}, {0x0%3F, 0x0%3F}, 0x0)
      expr.go:965  0x134
go/types.(*Checker).stmt(0x140002e1680, 0x0, {0x105a78740%3F, 0x14002ec8b30%3F})
      stmt.go:397  0x144
go/types.(*Checker).stmtList(0x14007d45860%3F, 0x0, {0x14000c8ffc0%3F, 0x0%3F, 0x14007d197b0%3F})
      stmt.go:124  0x88
go/types.(*Checker).funcBody(0x140002e1680, 0x140079e1320, {0x140008e2de0%3F, 0x1400007cc80%3F}, 0x14007d4a940, 0x14003468de0, {0x0, 0x0})
      stmt.go:44  0x244
go/types.(*Checker).funcDecl.func1()
      decl.go:826  0x44
go/types.(*Checker).processDelayed(0x140002e1680, 0x0)
      check.go:439  0x12c
go/types.(*Checker).checkFiles(0x140002e1680, {0x140079b7200, 0x12, 0x20})
      check.go:383  0x1fc
go/types.(*Checker).Files(...)
      check.go:341
golang.org/x/tools/gopls/internal/lsp/cache.doTypeCheck({0x105a79f28, 0x140058dde60}, 0x14007897e60, {{0x14000d866c0, 0x3a}, {0x14000d866c0, 0x3a}, {0x14000c822e0, 0x8}, {0x140037e7c20, ...}, ...})
      check.go:1562  0x6d8
golang.org/x/tools/gopls/internal/lsp/cache.typeCheckImpl({0x105a79f28, 0x140058ddce0}, 0x104d7e730%3F, {{0x14000d866c0, 0x3a}, {0x14000d866c0, 0x3a}, {0x14000c822e0, 0x8}, {0x140037e7c20, ...}, ...})
      check.go:1420  0x174
golang.org/x/tools/gopls/internal/lsp/cache.(*typeCheckBatch).checkPackage(0x140000d3ec8%3F, {0x105a79f28, 0x1400356c030}, 0x14003d1a240)
      check.go:674  0x184
golang.org/x/tools/gopls/internal/lsp/cache.(*typeCheckBatch).handleSyntaxPackage(0x14007897e60, {0x105a79f28, 0x1400356c030}, 0x1054ca510%3F, {0x14000d866c0, 0x3a})
      check.go:532  0x3e0
golang.org/x/tools/gopls/internal/lsp/cache.(*snapshot).forEachPackageInternal.func2()
      check.go:394  0x34
golang.org/x/sync/errgroup.(*Group).Go.func1()
      errgroup.go:75  0x58
created by golang.org/x/sync/errgroup.(*Group).Go in goroutine 130
      errgroup.go:72  0x98
[Error - 5:51:54 PM] 
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.
hyangah commented 9 months ago

Thanks @alioygur Looks like a duplicate of https://github.com/golang/go/issues/63933

adonovan commented 9 months ago

Indeed. Closing as dup of #63933.