You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
extension/src/goInstallTools.ts: require go1.21+ for tools installation
The Go extension will require go1.21 for tools installation from v0.44.0
(and is prerelease version v0.43.x).
This is a planned change and it was discussed in the v0.42.0 release note.
(https://github.com/golang/vscode-go/releases/tag/v0.42.0 Jul 17 2024).
`installTools` is the entry function for tools installation.
If the go version is too old, it suggests go1.21+ or the workaround
(go.toolsManagement.go).
* Misc changes
- Previously, when the build info of a binary is not available,
we didn't ask to update the tool. Since go1.18, the build info
should be available. So, now suggest to reinstall the tool.
- Bug fix: For vscgo, we used toolExecutionEnvironment when running
go install.
It should be toolInstallationEnvironment. This clears some env vars
like GO111MODULE, GOPROXY, GOOS, GOARCH, GOROOT which can interfere
with the go tool invocation.
Fixes#3411
Change-Id: Ifff0661d88a9adfc6bd3e0a25702d91921bcb77f
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/616676
Reviewed-by: Robert Findley <[email protected]>
Commit-Queue: Hyang-Ah Hana Kim <[email protected]>
kokoro-CI: kokoro <[email protected]>
Reviewed-by: Hongxiang Jiang <[email protected]>
`Failed to find a go command (go${minVersion} or newer) needed to install tools. `+
179
+
`Failed to find a go command (go${MINIMUM_GO_VERSION} or newer) needed to install tools. `+
171
180
`The go command (${goForInstall.binaryPath}) is too old (go${goForInstall.svString}). `+
172
-
'If your project requires a Go version older than go1.19, either manually install the tools or, use the "go.toolsManagement.go" setting '+
173
-
'to configure the Go version used for tools installation. See https://github.com/golang/vscode-go/issues/2898.'
181
+
`If your project requires a Go version older than go${MINIMUM_GO_VERSION}, please manually install the tools or, use the "go.toolsManagement.go" setting `+
182
+
`to configure a different go command (go ${MINIMUM_GO_VERSION}+) to be used for tools installation. See https://github.com/golang/vscode-go/issues/3411.`
174
183
);
175
184
returnmissing.map((tool)=>{
176
-
return{tool: tool,reason: `failed to find go (requires go${minVersion} or newer)`};
185
+
return{tool: tool,reason: `failed to find go (requires go${MINIMUM_GO_VERSION} or newer)`};
177
186
});
178
187
}
179
188
@@ -273,20 +282,21 @@ async function tmpDirForToolInstallation() {
273
282
returntoolsTmpDir;
274
283
}
275
284
276
-
// installTool installs the specified tool.
285
+
// installTool is used by goEnvironmentStatus.ts.
286
+
// TODO(hyangah): replace the callsite to use defaultToolsManager and remove this.
0 commit comments