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

x/tools/gopls: option to enable analysis across entire workspace #45600

Closed
mgdotson opened this issue Apr 16, 2021 · 2 comments
Closed

x/tools/gopls: option to enable analysis across entire workspace #45600

mgdotson opened this issue Apr 16, 2021 · 2 comments

Comments

@mgdotson
Copy link

@mgdotson mgdotson commented Apr 16, 2021

What version of Go are you using (go version)?

$ go version
go version go1.16.3 linux/amd64

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOOS="linux"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOVCS=""
GOVERSION="go1.16.3"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/dev/null"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build867817669=/tmp/go-build -gno-record-gcc-switches"

What did you do?

gopls version
golang.org/x/tools/gopls v0.6.10
    golang.org/x/tools/gopls@v0.6.10 h1:8Ebz8PymS2umcuCFhoz67unyJfWsipjTIrkBUF9kypg=

image

VSCODE: Open up go workspace. Analysis highlights on Explorer Panel do not show any files with any issues and analysis on bottom toolbar show 0 warnings and 0 issues.

Click on a file to open it and still no update to the issues or warnings. Save the file - with no changes made, and the issues and warnings are only updated for the current directory with that file.

What did you expect to see?

I expected to see all the issues and warnings for my entire workspace, top level project and all pkg sub modules. Attached pictures should have all three files highlighted and both the directories.
image (1)
image (2)

What did you see instead?

No analysis or warning evaluations. I would expect to see all of the files with analysis issues or warnings in my explorer window and as a summary in my bottom toolbar

@mknyszek mknyszek changed the title Option to enable analysis across entire workspace x/tools/gopls: option to enable analysis across entire workspace Apr 16, 2021
@gopherbot gopherbot added this to the Unreleased milestone Apr 16, 2021
@mknyszek
Copy link
Contributor

@mknyszek mknyszek commented Apr 16, 2021

@mgdotson
Copy link
Author

@mgdotson mgdotson commented Apr 24, 2021

This seems to be working again once I restarted my Athens Proxy service as there was an issue downloading one of the mongo-drivers when changing lint tool setting to use golanglint-ci.

VSCode setting "go.lintOnSave": "workspace" is linting the entire workspace without issue and without setting "go.lintTool" in vscode settings, the default staticcheck is being called as expected and entire workspace is being linted.

@mgdotson mgdotson closed this Apr 24, 2021
@stamblerre stamblerre removed this from the gopls/unplanned milestone Apr 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants