Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upx/tools/gopls: show diagnostic for for circular dependency #33085
Comments
This comment has been minimized.
This comment has been minimized.
Good catch, thank you for noticing this. You are right, |
This comment has been minimized.
This comment has been minimized.
I would like to claim this one ;) |
This comment has been minimized.
This comment has been minimized.
Great! Let me know if you need any advice on how to tackle it, or please feel free to reach out to me directly on Gophers Slack. |
This comment has been minimized.
This comment has been minimized.
As @stamblerre suggested I will take something easier for first task. Leaving this for now. |
This comment has been minimized.
This comment has been minimized.
Change https://golang.org/cl/209857 mentions this issue: |
This comment has been minimized.
This comment has been minimized.
After #35964 gets fixed. We need to adjust/write the diagnostic tests inside (tools/internal/lsp/testdata/circular/) to test the behavior and ensure that it is working. |
This change will provide a more useful error when you are self importing a package. It has TODOs in place to propagate the "import cycle not allowed" error from go list to the user. Updates golang/go#33085 Change-Id: Ia868a7c688b0f0a7a9689cfda5ea8cea8ae1faff Reviewed-on: https://go-review.googlesource.com/c/tools/+/209857 Run-TryBot: Rohan Challa <rohan@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Rebecca Stambler <rstambler@golang.org>
This comment has been minimized.
This comment has been minimized.
Change https://golang.org/cl/210942 mentions this issue: |
VS Code. Say, we have a circular dependency. In this case
go vet
would warn that it's not allowed. However it seems thatgopls
doesn't check this and just stops working (not providing hover outputs, references, what so ever) with these non-informative errors in output: