Skip to content

contrib_rules_jvm dependencies visible in build targets #340

@sbridges

Description

@sbridges

I have some protocol buffer files generated with an older version of protoc. Compiling those fails if when I add contrib_rules_jvm to MODULES.bazel. I think contrib_rules_jvm is loading a different version of protocol buffers, and that version is added as a dependency when compiling the java_library.

You can reproduce with the following archive,

test-archive.zip

bazel build ... fails with

foo/FooOuterClass.java:99: error: cannot find symbol
        makeExtensionsImmutable();

If I comment out bazel_dep(name = "contrib_rules_jvm", version = "0.28.0") in MODULE.bazel, then bazel build ... succeeds.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions