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: add a work-around for file watching bug in VS Code #40812

Open
stamblerre opened this issue Aug 15, 2020 · 1 comment
Open

x/tools/gopls: add a work-around for file watching bug in VS Code #40812

stamblerre opened this issue Aug 15, 2020 · 1 comment
Labels
gopls/metadata Issues related to metadata loading in gopls gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Milestone

Comments

@stamblerre
Copy link
Contributor

VS Code currently does not allow the language server to watch files outside of the workspace root: microsoft/vscode#100870.

This means that users who open subdirectories of modules or modules with replace directives may see bugs because gopls's view of the workspace state is incorrect.

@heschik has suggested that we should add a work-around to address this -- we could clear out the entire cache when we see >= 10 (or fewer?) batched didChangeWatchedFiles notifications. We can do this for any module with a replace directive or for any workspace whose root is not the module root.

@stamblerre stamblerre added this to the gopls/v1.0.0 milestone Aug 15, 2020
@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 Aug 15, 2020
@stamblerre stamblerre added this to Needs Triage in vscode-go: gopls by default Nov 10, 2020
@stamblerre stamblerre moved this from Needs Triage to Non-critical in vscode-go: gopls by default Nov 10, 2020
@stamblerre stamblerre removed this from Non-critical in vscode-go: gopls by default Dec 16, 2020
@stamblerre stamblerre added this to Needs Triage in vscode-go: gopls by default via automation Dec 21, 2020
@stamblerre stamblerre removed this from Needs Triage in vscode-go: gopls by default Jan 6, 2021
@stamblerre stamblerre added this to To Do in gopls on-deck Feb 28, 2021
@suzmue suzmue added the gopls/metadata Issues related to metadata loading in gopls label May 10, 2022
@findleyr
Copy link
Contributor

It looks like the upstream bug has been fixed. We should test to confirm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gopls/metadata Issues related to metadata loading in gopls gopls Issues related to the Go language server, gopls. Tools This label describes issues relating to any tools in the x/tools repository.
Projects
No open projects
Development

No branches or pull requests

4 participants