Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
x/tools/gopls: missing metadata for import #40685
Ok yep, this is easily reproducible by adding a symbol from an unimported package and accepting the quick fix. Will investigate.
Edit: Less easily reproducible than I thought. I reproduced it by adding
Looks like this is a consequence of #36857--an overlaid file in a package that has a test variant really needs to be added both to the original package and its test variant. We currently don't handle this, but I think the ordering of the pre-1.15
Now it's being added to the test variant, which results in incorrect
…ated overlay bug Something about the ordering of `go list` results must have changed in Go 1.15, so overlays with test variants were failing to get the correct imports. Technically, the correct solution would have been to support overlays for a package *and* its test variant, but for the purposes of gopls, it's actually more important that the overlays apply to the package itself (rather than its test variant). Fixes golang/go#40685 Change-Id: I3282557502f7f30bf484e1e6c17b90db824bc7d0 Reviewed-on: https://go-review.googlesource.com/c/tools/+/253800 Run-TryBot: Rebecca Stambler <email@example.com> Reviewed-by: Michael Matloob <firstname.lastname@example.org> Reviewed-by: Heschi Kreinick <email@example.com>