v0.32.0 - 8 Mar, 2022
This version includes features to enhance Go 1.18 support. It works best when paired with the latest Go Language Server (gopls
v0.8.0+) and Delve (dlv
v1.8.0+).
Go 1.18 introduces substantial changes to the language spec, so many tools need rebuilding with Go 1.18 or newer. The extension now suggests updates of tools if it finds they were built with old versions of go
which are inadequate for the version used for the project. If you opted in for auto-update, tools will be auto-updated.
In order to use Go 1.18, please follow the instruction to configure your Visual Studio Code to locate the right go binary, and run the Go tools using the "Go: Install/Update Tools" command.
A list of all issues and changes can be found in the v0.32.0 milestone and commit history.
Changes
-
Starting with Go 1.18, the
go
command provides native support for multi-module workspaces, viago.work
files. The new "Open 'go.work'" option in the Go status bar's quickpick menu allows users to access the correspondinggo.work
file.
-
The extension no longer depends on
gopkgs
. Its use for "Go: Browse Packages" and "Go: Add Import" commands had been replaced withgo list
or commands ingopls
. (Issue 258) -
The extension uses
gopls
instead ofgo-outline
ifgopls
v0.8.0 or newer is used. We plan to complete the replacement work in the next release. (Issue 1020) -
The new
"go.toolsManagement.go"
setting allows users to specify the Go command for tools installation/updates separate from the Go command used for the project. -
The latest
gopls
requires go 1.13+ for installation, so the extension no longer asks forgopls
updates when an older versions ofgo
is used. (Issue 2030) Notegopls
compiled with go 1.13 or newer can still process projects that use go 1.12. In case, you want to updategopls
while working with an older version of Go, utilize the new"go.toolsManagement.go"
setting. -
Reduced the verbosity of "Go: Locate Configured Go Tools" output.
Code Health
- Updated to mocha@9.2.0 (CVE-2021-23566).
- Deflaked debug tests.
- Changed to check
go.dev/dl
instead ofgolang.org/dl
for Go release. - Improved documentation for the default formatting behavior and template support.