bazelbuild / rules_jvm_external

Bazel rules to resolve, fetch and export Maven artifacts
Apache License 2.0
323 stars 246 forks source link

`use_repo_rule` usage breaks Bazel 5/6 support #1055

Closed luispadron closed 7 months ago

luispadron commented 7 months ago

use_repo_rule is currently only in Bazel 7+ and rules_jvm_external 6.0 uses this. It causes the following failure:

ERROR: https:/bcr.bazel.build/modules/rules_jvm_external/6.0/MODULE.bazel:65:13: name 'use_repo_rule' is not defined
ERROR: Error computing the main repository mapping: in module dependency chain <root> -> rules_jvm_external@6.0: error executing MODULE.bazel file for rules_jvm_external@6.0
shs96c commented 7 months ago

This is a known issue, and why the bzlmod section of the release notes starts with If you are using Bazel 7 or above.

Since Bazel 7 is the latest LTS, bzlmod behaviour changed between the 6.5.0 and 7.0.0, and the previous WORKSPACE-based approach still works, we won't be making changes.

keith commented 3 months ago

I submitted a PR for discussion https://github.com/bazelbuild/rules_jvm_external/pull/1151