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: updates to go.sum needed, disabled by -mod=readonly with experimentalWorkspaceModule #44097
Comments
Thanks for opening this issue. Are you able to share the full log? Redacting pieces is fine, but a complete log will help us get a better sense of the issue. @heschik: My guess is that this is caused by https://golang.org/cl/287032 because @samstride is using the experimental workspace module (#44085 (comment)). |
@stamblerre , edited original post and added the missing Sorry, did I need to do something else (like turn rpc traces on) and paste those logs? |
Yes, if you could share the logs with the following setting enabled that would be best. "go.languageServerFlags": [
"-rpc.trace"
] |
|
Thank you for sharing these logs. Can you please run Then, can you please try running Obviously this error message is not useful at all, so that's an issue, but I just want to confirm that I understand the problem first. |
I'll echo what @stamblerre said: thank you for taking the time to report this, it's really helpful for us to get error reports from users experimenting with workspace modules as we work on this feature. One additional note: be aware that the |
Hmmm, ok, so the original rpc logs I pasted had folders names modified/redacted. So when I use As mentioned, the error message is not very helpful for now and I need to figure out where the error is in my workspace. I have 50+ mod files in the my workspace. Anyways, here is the output (any idea why I have module gopls-workspace
go 1.12
require (
config v1.9999999.0-goplsworkspace
filestore/api v1.9999999.0-goplsworkspace
support/api v1.9999999.0-goplsworkspace
support/lookup v1.9999999.0-goplsworkspace
utils v1.9999999.0-goplsworkspace
vault v1.9999999.0-goplsworkspace
)
replace utils => /Users/darkknight/customer1/utils
replace config => /Users/darkknight/customer1/config
replace vault => /Users/darkknight/customer1/vault
replace filestore/api => /Users/darkknight/customer1/filestore/api
replace support/api => /Users/darkknight/customer1/support/api
replace support/lookup => /Users/darkknight/customer1/support/lookup The above works since I modified it to match the logs provided. |
Woohoooo... I found 2 modules that had issues: 1 module had go code that wasn't correct and the other one had a bad package. Once I sorted that out, the whole thing fixed itself. Until the error message can be fixed, I guess the only way to find the root cause it is to open up each module and look for errors. |
Thanks @samstride. The
Do you mean that by limiting your gopls.mod to just these modules, your workspace loaded without error?
Well, I'm glad you figured it out but we agree, the whole UX of this failure mode needs to be improved. Thanks for reporting, and for following up. |
Also, do you mind clarifying what steps you took to correct the broken modules? Did you run |
@stamblerre, How to reproduce the issue I was facing:
I did run @findleyr , yup, by limiting the BTW, I am happy to jump on a meet call and share my screen if that helps. |
Change https://golang.org/cl/289772 mentions this issue: |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Issue introduced by updating gopls to
v0.6.5
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Updated gopls to v0.6.5
VSCode settings for
gopls
:What did you expect to see?
No
gopls
errors.What did you see instead?
Below output from
gopls (server)
Attempted to fix errors by running
go mod tidy
but that did not help.The text was updated successfully, but these errors were encountered: