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

using auto complete package with gopls enabled doesn't complete everything #2419

Open
primalmotion opened this Issue Apr 5, 2019 · 6 comments

Comments

Projects
None yet
4 participants
@primalmotion
Copy link
Contributor

primalmotion commented Apr 5, 2019

I've noticed that when I want to auto complete a package, some of them are missing. It seems that if 2 packages have the same name (json and github.com/something/json) only one is presented in auto complete. I feel there is a map key overlap here. I have goals enabled, but I'm not sure if this is related

@primalmotion primalmotion changed the title using auto complete package with goals doesn't complete everything using auto complete package with gopls enabled doesn't complete everything Apr 5, 2019

@ramya-rao-a

This comment has been minimized.

Copy link
Member

ramya-rao-a commented Apr 6, 2019

@primalmotion Are you using modules in this case? And are these completions for unimported packages i.e do you have go.autocompleteUnimportedPackages setting enabled?

@primalmotion

This comment has been minimized.

Copy link
Contributor Author

primalmotion commented Apr 6, 2019

I'm not using go modules, and yes

@ramya-rao-a

This comment has been minimized.

Copy link
Member

ramya-rao-a commented Apr 6, 2019

The code to provide completions for unimported packages whether you have enabled the language server or not is essentially the same. Can you check if you see the same behavior with the language server disabled?

@didil

This comment has been minimized.

Copy link

didil commented Apr 7, 2019

when I enable gopls using:

"go.useLanguageServer": true,
"go.alternateTools": {
     "go-langserver": "gopls"
},

completion for unimported packages stops working, all the other settings are set to default
using vscode-go 0.9.3-beta.7
(adding go.autocompleteUnimportedPackages has no effect )

@tj

This comment has been minimized.

Copy link

tj commented Apr 7, 2019

In my case I was also using modules and "go.autocompleteUnimportedPackages": true

@primalmotion

This comment has been minimized.

Copy link
Contributor Author

primalmotion commented Apr 9, 2019

@ramya-rao-a it also happens without language server enabled

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.