-
Notifications
You must be signed in to change notification settings - Fork 758
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
installation: go get from temporary directory for tools installation can result in picking a different go version when using asdf #757
Comments
@bmalehorn thanks for reporting the issue. Can you verify if the go command the extension is the same one you are seeing from your terminal? It looks like you're using Can you share the output of |
Ohh, I think I know what it is. I'm using So in the workspace root, it runs go 1.15.2:
...but in my home directory, it runs go 1.12:
So I think the correct fix here is to run
For completeness here's the output:
|
Yes, we've seen this issue. microsoft/vscode-go#3087 I think with go1.16, we will be in a better state with module aware tool installation. |
Yup, that looks like my issue. Anyway, I can work around this by installing 1.52.2 in my home directory ( Is there any information you need from me? I'm not sure what you mean by |
Change https://golang.org/cl/261697 mentions this issue: |
Sadly, I found Other slightly simpler approaches I can think of are
|
1 would work for my use case:
That's the correct version of go (1.15.2). It sounds like the problem is that two different things care about current directory:
Is it possible to fix 2 by building in another directory? Something like |
Change https://golang.org/cl/263977 mentions this issue: |
Change https://golang.org/cl/264318 mentions this issue: |
This should've been done in cl/263977. Update #757 Change-Id: I51afbc8a2534c1b3f304ba988b6bcec9c944a048 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/264318 Run-TryBot: Hyang-Ah Hana Kim <[email protected]> TryBot-Result: kokoro <[email protected]> Trust: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Suzy Mueller <[email protected]>
What version of Go, VS Code & VS Code Go extension are you using?
go version
to get version of Gogo version go1.15.2 darwin/amd64
code -v
orcode-insiders -v
to get version of VS Code or VS Code Insidersgo env
to get the go development environment detailsShare the Go related settings you have added/edited
Run
Preferences: Open Settings (JSON)
command to open your settings.json file.Share all the settings with the
go.
or["go"]
orgopls
prefixes.Describe the bug
When I open VSCode, it asks to update tools.
All the tool updates fail:
However, in a regular terminal I can run the same commands in a terminal and they work ok:
I suspect this extension is not running the same version of go / the same settings at the terminal.
The text was updated successfully, but these errors were encountered: