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

Support Not Generating Transitive Proto Dependencies #62

Open
naturalwarren opened this issue Jun 16, 2020 · 1 comment
Open

Support Not Generating Transitive Proto Dependencies #62

naturalwarren opened this issue Jun 16, 2020 · 1 comment
Labels
P4 This is either out of scope or we don't have bandwidth to review a PR. (No assignee)

Comments

@naturalwarren
Copy link

Alternative proto rulesets (namely stackb) support not generating Java byte code for proto_library.deps() via a transitive attribute.

Today, java_proto_library generates bytecode for both a proto_library's srcs and deps attributes. Generating bytecode for deps can lead to duplicate class exceptions if the consumer also tries to generate and pack the resulting class files into a JAR.

Would you consider supporting a transitive attribute for java_proto_library?

@Yannic
Copy link
Collaborator

Yannic commented Jun 18, 2020

AFAICT, this should be possible today if you define your own proto_lang_toolchain and adding the .proto files that are packed into the .jar to blacklisted_protos.

Generating code for transitive (non-blacklisted) protos is by design so you don't have to explicitly mirror the proto-graph for every language, so I think it's unlikely that a transitive attribute will be supported.

@comius comius added the P4 This is either out of scope or we don't have bandwidth to review a PR. (No assignee) label Feb 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P4 This is either out of scope or we don't have bandwidth to review a PR. (No assignee)
Projects
None yet
Development

No branches or pull requests

3 participants