Skip to content

Commit b097aad

Browse files
authored
Keep dependency versions in sync for WORKSPACE and MODULE.bazel (#194)
* Keep dependency versions in sync for WORKSPACE and MODULE.bazel As mentioned in the Bazel blog article, the old `WORKSPACE` system is planned to be disabled by default in Bazel 8, and to be removed altogether in Bazel 9. The `WORKSPACE` file will eventually be removed, but for now, it’s best to keep the dependency versions in both systems in sync, so that we can build the project with Bzlmod either disabled or enabled. Note that there is a compatibility issue that prevents this project from depending on protobuf v22 and higher. Until that issue is fixed, v21.7 is the highest version that both systems have. References: - https://blog.bazel.build/2023/12/11/bazel-7-release.html#bzlmod - https://registry.bazel.build/modules/protobuf - https://github.com/protocolbuffers/protobuf/blob/v21.7/protobuf_deps.bzl#L96-L104 - #186 * Update PROTOC_VERSION to 21.7
1 parent f2c5583 commit b097aad

File tree

4 files changed

+6
-5
lines changed

4 files changed

+6
-5
lines changed

.github/workflows/build.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ permissions: read-all
66

77
# update in build.yml and codeql.yml at same time
88
env:
9-
PROTOC_VERSION: 21.3
9+
PROTOC_VERSION: 21.7
1010

1111
jobs:
1212
build:

.github/workflows/codeql.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ permissions: read-all
1515

1616
# update in build.yml and codeql.yml at same time
1717
env:
18-
PROTOC_VERSION: 21.3
18+
PROTOC_VERSION: 21.7
1919

2020
on:
2121
push:

MODULE.bazel

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
module(name = "protobuf_javascript", version = "3.21.2")
22

33
bazel_dep(name = "protobuf", version = "21.7", repo_name = "com_google_protobuf")
4-
bazel_dep(name = "rules_pkg", version = "0.9.1")
4+
bazel_dep(name = "rules_pkg", version = "0.7.0")

WORKSPACE

+3-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
44

55
http_archive(
66
name = "com_google_protobuf",
7-
strip_prefix = "protobuf-21.3",
8-
urls = ["https://github.com/protocolbuffers/protobuf/archive/refs/tags/v21.3.zip"],
7+
urls = ["https://github.com/protocolbuffers/protobuf/archive/refs/tags/v21.7.zip"],
8+
sha256 = "e13ca6c2f1522924b8482f3b3a482427d0589ff8ea251088f7e39f4713236053",
9+
strip_prefix = "protobuf-21.7",
910
)
1011

1112
load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

0 commit comments

Comments
 (0)