x/tools/gopls: missing completion of current module packages #67528
Labels
gopls/completion
Issues related to auto-completion in gopls.
gopls
Issues related to the Go language server, gopls.
Tools
This label describes issues relating to any tools in the x/tools repository.
Milestone
When I try to add an import for a package within the current module, I got the following error
Despite example.com/bank is the module name as define in the go.mod file
nb: this comes from: https://github.com/mschwarzmueller/go-complete-guide-resources/tree/main/code/03-working-with-packages/04-third-party-packages
On the video from Udemy, we can see the expected completion list:

What version of Go, VS Code & VS Code Go extension are you using?
Version Information
go version
to get version of Go from the VS Code integrated terminal.gopls -v version
to get version of Gopls from the VS Code integrated terminal.code -v
orcode-insiders -v
to get version of VS Code or VS Code Insiders.Go: Locate Configured Go Tools
command.Tools Configuration
Environment
GOBIN: undefined
toolsGopath:
gopath: /home/fs/go
GOROOT: /usr/lib/go
PATH: /usr/local/bin:/usr/bin:/usr/local/sbin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
Tools
Go env
Workspace Folder (udemy-aws-saa): /home/fs/LEARN/udemy-aws-saa
Workspace Folder (udemy-go-complete-guide): /home/fs/LEARN/udemy-go-complete-guide
Workspace Folder (go-complete-guide-resources): /home/fs/tmp/go-complete-guide-resources
Share the Go related settings you have added/edited
Nothing special
Steps to reproduce the behavior:
Clone the repo and play with the file https://github.com/mschwarzmueller/go-complete-guide-resources/blob/main/code/03-working-with-packages/04-third-party-packages/bank.go#L6
The text was updated successfully, but these errors were encountered: