-
Notifications
You must be signed in to change notification settings - Fork 18k
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: only show outside of GOPATH/modules warning once #37279
Comments
I think the correct fix for this would be to show the warning only once, on view creation, instead of on diagnostics. |
What about only showing the warning if the user actively tries to do something via i.e. the initial attempt to pre-load the workspace can fail, it only becomes relevant if the user actually does something within that workspace, i.e. open a |
Right now, we only show the warning if the user is working outside of GOPATH/modules and has a dependency we cannot resolve. This has been an acceptable approximation of "something went wrong and here's a hint", but it can cause the warning to pop up when the user is just typing an import manually. I think showing it once only if we see errors in the package (caused by dependencies) is probably the best fix because we don't want to bother the user unnecessarily (and opening an ad-hoc package is not necessarily wrong). |
If the workspace outside GOPATH/modules we show this message a lot if the user has code with diagnostics. I think it would be better only to show it if it's the inital load or the user is changing configuration (and there are other errors). I have a CL. |
Change https://golang.org/cl/230897 mentions this issue: |
See microsoft/vscode-go#3055.
The text was updated successfully, but these errors were encountered: