Skip to content

Commit 4c163dd

Browse files
authored
Restore compatibility_level, yank 7.2.3 (#1817)
Restores `compatibility_level = 7` to the `module` directive and yanks version 7.2.3 from the Bazel Central Registry. --- Per #1816, #1815 removed the `compatibility_level` attribute of the `module` directive too soon. Builds using Bazel <8.6.0 or <9.1.0 with other `rules_scala` 7.x dependencies in the build graph would break once any module introduces `rules_scala` 7.2.3.
1 parent 8cef613 commit 4c163dd

2 files changed

Lines changed: 13 additions & 4 deletions

File tree

.bcr/metadata.template.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,7 @@
2121
"github:bazel-contrib/rules_scala"
2222
],
2323
"versions": [],
24-
"yanked_versions": {}
24+
"yanked_versions": {
25+
"7.2.3": "removed compatibility_level too soon (https://github.com/bazel-contrib/rules_scala/issues/1816)"
26+
}
2527
}

MODULE.bazel

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,19 @@
11
"""Bazel module definition for rules_scala"""
22

3+
# The publish-to-bcr GitHub workflow supplies the actual `version`. See:
4+
# - https://bazel.build/external/faq#module-versioning-best-practices
5+
# - https://github.com/bazel-contrib/publish-to-bcr/blob/v1.1.0/src/domain/create-entry.ts#L176-L216
6+
#
7+
# compatibility_level is a no-op in Bazel >= 8.6.0 and >= 9.1.0, but we'll keep
8+
# it until we stop supporting Bazel 7. See:
9+
# - https://github.com/bazelbuild/bazel/pull/28600
10+
# - https://bazel.build/release
11+
# - https://github.com/bazel-contrib/rules_scala/issues/1816
312
module(
413
name = "rules_scala",
5-
# The publish-to-bcr GitHub workflow supplies the actual `version`. See:
6-
# - https://bazel.build/external/faq#module-versioning-best-practices
7-
# - https://github.com/bazel-contrib/publish-to-bcr/blob/v1.1.0/src/domain/create-entry.ts#L176-L216
814
version = "",
915
bazel_compatibility = [">=7.1.0"],
16+
compatibility_level = 7,
1017
)
1118

1219
SCALA_VERSION = "2.12.21"

0 commit comments

Comments
 (0)