Closed wanfintara closed 4 years ago
@wanfintara thanks for the report. Please provide additional info about your setting.
Run Preferences: Open Settings (JSON)
command to open your settings.json file.
Share all the settings with the go.
or ["go"]
or gopls
prefixes.
Run go env
from the integrated terminal and share the output (feel free to redact confidential or sensitive info).
Run the above command (gopkgs -format '{{.Name}};{{.ImportPath}}'
) from the integrated terminal.
Check if there is any failure log of the gopkgs
command execution in the View: Toggle Output
> 'Go' or 'Log (Extension Host)' menu.
@hyangah @stamblerre
all go settings
"go.gopath": "/Users/wanfintara/Documents/go",
"go.docsTool": "gogetdoc",
"go.lintTool":"golangci-lint",
"go.lintFlags": [
"--config=${workspaceFolder}/.golangci.yml",
"--fast"
],
"go.useLanguageServer": true,
"go.languageServerExperimentalFeatures": {
"diagnostics": true, // for build and vet errors as you type
// "documentLink": true,
// "format": true
},
// "go.coverOnSave": true,
// "go.coverOnSingleTest": true,
// "go.autocompleteUnimportedPackages": true,
"go.coverageDecorator": {
"type": "gutter",
"coveredHighlightColor": "rgba(64,128,128,0.5)",
"uncoveredHighlightColor": "rgba(128,64,64,0.25)",
"coveredGutterStyle": "blockgreen",
"uncoveredGutterStyle": "blockred"
},
"go.lintOnSave": "off",
"[go]": {
"editor.snippetSuggestions": "none",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.organizeImports": true
},
},
"gopls": {
"usePlaceholders": true, // add parameter placeholders when completing a function
// "completionDocumentation": true // for documentation in completion items
"completeUnimported": true,
"staticcheck": false
}
gopkgs -format '{{.Name}};{{.ImportPath}}'
stat /Users/wanfintara/Documents/go/src/github.com/gravitational/teleport/docs/latest: too many levels of symbolic links
View: Toggle Output
has nothing
go env
〤 go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/Users/wanfintara/Library/Caches/go-build"
GOENV="/Users/wanfintara/Library/Application Support/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOINSECURE=""
GONOPROXY=""
GONOSUMDB=""
GOOS="darwin"
GOPATH="/Users/wanfintara/Documents/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/Cellar/go/1.14.2_1/libexec"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/Cellar/go/1.14.2_1/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
AR="ar"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="/usr/local/Homebrew/Library/Homebrew/shims/mac/super/pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/ct/p1ppm59x6b79r2g19w5r7fn80000gn/T/go-build823860923=/tmp/go-build -gno-record-gcc-switches -fno-common"
This is an issue of github.com/gravitational/teleport
. They have a misconfigured symbolic link
for docs/latest
. It's point to itself and causes the stat
command (and probably many others) to fail.
Please file an issue at https://github.com/gravitational/teleport/issues.
And, if this file is for documentation only, delete or fix the symbolic link locally (/Users/wanfintara/Documents/go/src/github.com/gravitational/teleport/docs/latest
) while waiting for the fix in the upstream.
Will do, thanks alot.
Filed an issue here
Thanks for following up! I'll close this issue since it's an upstream bug.
When running
GO: Add Import
command, always got this messageTried googling for solutions, but still cant fix it.
Go version: go1.14.2 darwin/amd64 VS Code version : 1.44.0