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

Embedded go_proto_library not being indexed #5566

Closed
tingilee opened this issue Oct 30, 2023 · 4 comments
Closed

Embedded go_proto_library not being indexed #5566

tingilee opened this issue Oct 30, 2023 · 4 comments
Assignees
Labels
awaiting-maintainer Awaiting review from Bazel team on issues lang: go Go rules integration product: GoLand GoLand plugin type: bug

Comments

@tingilee
Copy link
Contributor

Description of the bug:

In Bazel plugin in Goland, when go_library refers to embedded go_proto_library, source files in the go_library cannot refer to definitions in the go_proto_library.

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

For this snippet of code, IDE should index translators.go to be able to refer to types declared in fooproto_go_proto. Please see the repro in the attached PR.

go_proto_library(
    name = "fooproto_go_proto",
    compilers = ["@io_bazel_rules_go//proto:go_grpc"],
    importpath = "github.com/bazelbuild/intellij/examples/go/with_proto/proto",
    proto = ":fooproto_proto",
    visibility = ["//visibility:public"],
)

go_library(
    name = "proto",
    srcs = ["translators.go"],
    embed = [":fooproto_go_proto"],
    importpath = "github.com/bazelbuild/intellij/examples/go/with_proto/proto",
    visibility = ["//visibility:public"],
)

Which Intellij IDE are you using? Please provide the specific version.

2023.2

What programming languages and tools are you using? Please provide specific versions.

Goland, golang

What Bazel plugin version are you using?

Version 2023.10.27.0.1-api-version-233

Have you found anything relevant by searching the web?

No response

Any other information, logs, or outputs that you want to share?

No response

@tingilee tingilee added awaiting-maintainer Awaiting review from Bazel team on issues type: bug labels Oct 30, 2023
@tingilee
Copy link
Contributor Author

Created a PR: #5567

@iancha1992 iancha1992 linked a pull request Oct 30, 2023 that will close this issue
3 tasks
@iancha1992 iancha1992 added the product: GoLand GoLand plugin label Oct 30, 2023
@iancha1992 iancha1992 added the lang: go Go rules integration label Oct 30, 2023
@tingilee
Copy link
Contributor Author

tingilee commented Nov 3, 2023

@blorente Can you review this diff? #5567 We're very interested in getting this patched and unblock developers.

@tpasternak
Copy link
Collaborator

Duplicate of #5538

@tpasternak tpasternak marked this as a duplicate of #5538 Nov 16, 2023
@blorente
Copy link
Collaborator

@tingilee Reviewed the diff, left some comments. Thanks for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-maintainer Awaiting review from Bazel team on issues lang: go Go rules integration product: GoLand GoLand plugin type: bug
Projects
Development

Successfully merging a pull request may close this issue.

6 participants