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: handle inconsistent vendoring error better #54986

Open
hyangah opened this issue Sep 9, 2022 · 0 comments
Open

x/tools/gopls: handle inconsistent vendoring error better #54986

hyangah opened this issue Sep 9, 2022 · 0 comments
Labels
gopls Issues related to the Go language server, gopls. NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. Tools This label describes issues relating to any tools in the x/tools repository.

Comments

@hyangah
Copy link
Contributor

hyangah commented Sep 9, 2022

gopls version: v0.9.5
go version:1.19
gopls settings: "gopls": { "ui.semanticTokens": true }

When inconsistent vendoring is detected, gopls fails to load workspace and shows an overwhelming notification:

Screen Shot 2022-09-09 at 6 42 30 PM

(the above screenshot was taken after starting gopls)

  1. Translate this go command error to a friendly actionable error message. It's already done in diagnostics.

Screen Shot 2022-09-09 at 7 04 56 PM

  1. Help users to pay attention to the go.mod diagnostic that already offers a quick-fix.

  2. (feeling adventurous :-P) Investigate if we can get rid of this error - what if gopls falls back to load workspace as if there was no vendor directory while reporting the inconsistent vendoring issue in go.mod? If the fix for cmd/go: return best-effort results despite inconsistent vendoring #39164 helps, should we prioritize it?

@gopherbot gopherbot added Tools This label describes issues relating to any tools in the x/tools repository. gopls Issues related to the Go language server, gopls. labels Sep 9, 2022
@gopherbot gopherbot added this to the Unreleased milestone Sep 9, 2022
@dle8 dle8 added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Sep 16, 2022
@dle8 dle8 modified the milestones: Unreleased, gopls/unplanned Sep 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gopls Issues related to the Go language server, gopls. NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. Tools This label describes issues relating to any tools in the x/tools repository.
Projects
None yet
Development

No branches or pull requests

3 participants