x/tools/gopls: inaccurate functionality for import with package name mismatching its path #51411
Labels
gopls/completion
Issues related to auto-completion 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.
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
Milestone
Reported in slack: gopls offers inaccurate functionality when importing github.com/wagslane/go-rabbitmq, which has the package name "rabbitmq". Completion is inaccurate, and import statements get removed on save:
@hyangah points out that this only happens when the module is not yet required by the
go.mod
. This is therefore probably a chicken-and-egg problem, but one that can be quite confusing for our users.The text was updated successfully, but these errors were encountered: