Skip to content

Commit

Permalink
Bazel 8 + rules_java 8 compatibility updates
Browse files Browse the repository at this point in the history
Bumps dependencies to versions that are compatible with both Bazel 7.5.0
and 8.0.0. Part of bazelbuild#1482. Closes bazelbuild#1652.

- ScalaPB jars: 0.11.17 => 1.0.0-alpha.1
- `rules_python`: 0.38.0 => 1.2.0
- `rules_cc`: 0.0.9 => 0.1.1
- `abseil-cpp`: 20220623.1 => 20250127.0
- `rules_java`: 7.12.4 => 8.9.0
- `protobuf`: 21.7 => 29.3
- `rules_proto`: 6.0.2 => 7.1.0
- `google-common-protos`: 2.52.0 => 2.53.0

This precipitated the following updates also included in this commit:

- Loads `java_proto_library` from `com_google_protobuf`.
- Bumps `.bazelversion` to 7.5.0.
- Sets `.bazelci/presubmit.yml` to use Bazel 7.5.0 instead of 6.5.0, and
  `last_rc` in place of `7.x`.
- Sets `common --enable_workspace --noenable_bzlmod` in `.bazelrc` and
  `tools/bazel\.rc\.buildkite`.
- Adds `allow_empty = True` to a `glob` expression in
  `//test/semanticdb:lib_with_tempsrc`.
- Removes Scala 2.11 test cases.

Bazel 6 is officially unsupported as of this change and the upcoming
`rules_scala` 7.0.0 release. `WORKSPACE` builds succeed under Bazel
6.5.0 (with C++ compiler flags) for the time being, but are not
guaranteed to continue working. (Bazel 6 Bzlmod builds would break
anyway, because Bazel 6 doesn't provide `use_repo_rule`, required by
`rules_jvm_external` 6.3, which is required by `protobuf` v29.)

The `README` now documents that `scala_proto` or any rules otherwise
depending on `protobuf` are no longer supported out of the box for Scala
2.11. Such users will have to ensure they register their own downgraded
versions, at their own risk of future `rules_scala` 7.x incompatibility.

Version bump related updates to `.bazelversion`,`WORKSPACE`, and
`third_party/repositories` comprise the bulk of this change. Other
small, yet important changes (other than those due to the version bumps
noted above) include:

- Adding a new `examples/overridden_artifacts` repository and the
  `overridden_artifacts_example` test case in
  `test/shell/test_examples.sh`.

- Making `_validate_scalac_srcjar()` and `dt_patched_compiler_setup()` in
  `scala/private/macros/scala_repositories.bzl` more tolerant of
  dictionaries containing keys mapped to `None`. The new
  `overridden_artifacts_example` test covers this.

Bazel 8 and `rules_java` 8 require `protobuf` >= v29. After the
`protobuf` v29 bump, and before the ScalaPB 1.0.0-alpha.1 bump,
`scala_proto` targets would fail with the following error:

```txt
ERROR: .../external/com_google_protobuf/src/google/protobuf/BUILD.bazel:23:14:
  ProtoScalaPBRule
  external/com_google_protobuf/src/google/protobuf/any_proto_jvm_extra_protobuf_generator_scalapb.srcjar
  failed: (Exit 1): scalapb_worker failed:
  error executing ProtoScalaPBRule command
  (from target @@com_google_protobuf//src/google/protobuf:any_proto)
  bazel-out/.../bin/src/scala/scripts/scalapb_worker
    ... (remaining 2 arguments skipped)

--jvm_extra_protobuf_generator_out:
  java.lang.NoSuchMethodError:
  'java.lang.Object com.google.protobuf.DescriptorProtos$FieldOptions.getExtension(com.google.protobuf.GeneratedMessage$GeneratedExtension)'
    at scalapb.compiler.DescriptorImplicits$ExtendedFieldDescriptor.fieldOptions(DescriptorImplicits.scala:329)
  [ ...snip... ]

java.lang.RuntimeException: Exit with code 1
    at scala.sys.package$.error(package.scala:30)
    at scripts.ScalaPBWorker$.work(ScalaPBWorker.scala:44)
    at io.bazel.rulesscala.worker.Worker.persistentWorkerMain(Worker.java:96)
    at io.bazel.rulesscala.worker.Worker.workerMain(Worker.java:49)
    at scripts.ScalaPBWorker$.main(ScalaPBWorker.scala:39)
    at scripts.ScalaPBWorker.main(ScalaPBWorker.scala)

ERROR: .../external/com_google_protobuf/src/google/protobuf/BUILD.bazel:23:14
  Building source jar external/com_google_protobuf/src/google/protobuf/any_proto_scalapb-src.jar
  failed: (Exit 1): scalapb_worker failed:
  error executing ProtoScalaPBRule command
  (from target @@com_google_protobuf//src/google/protobuf:any_proto)
  bazel-out/darwin_arm64-opt-exec-ST-a828a81199fe/bin/src/scala/scripts/scalapb_worker
    ... (remaining 2 arguments skipped)
```

Here's why the other changes were necessary in light of the version
bumps:

- `java_proto_library` from `rules_java` is now officially deprecated,
  hence loading it from `com_google_protobuf`.

- Setting `common --enable_workspace --noenable_bzlmod` (instead of
  `build`) fixes `test_semanticdb_handles_removed_sourcefiles`. This
  test relies on `bazel query`, which is also affected by these flags,
  hence `common` instead of `build`. Bazel 8 defaults to
  `--enable_bzlmod --noenable_workspace`, causing the `WORKSPACE` run of
  this test to fail.

- `glob` requires an explicit `allow_empty = True` parameter now that
  `--incompatible_disallow_empty_glob` defaults to `True` in Bazel 8.

- ScalaPB 0.9.8, the last version compatible with Scala 2.11, does not
  support `protobuf` >= 26.0. For this reason, we must remove the Scala
  2.11 test cases.

We should consider dropping Scala 2.11 support at this point, since
there's no ScalaPB release for it that supports later versions of
`protobuf`. That, and we could remove some of the special case code
added in the following changes, amongst other 2.11 support details:

- bazelbuild#1631
- bazelbuild#1648
- bazelbuild#1687
- bazelbuild#1688

Finally, the motivation for the non-version bump changes:

- The design bug in the upcoming Bzlmod API for `overridden_artifacts`
  reported by @dmivankov precipitated the `examples/overriden_artifacts`
  repo and test. See:
  bazelbuild#1482 (comment)
  bazelbuild#1482 (comment)

- The `_validate_scalac_srcjar()` update maintains the strict checks for
  mutually exclusive values, while preventing client code from having to
  explicitly filter out `None` entries. This pairs with the change in
  `dt_patched_compiler_setup()` that uses the `compiler_srcjar`
  dictionary. These changes helps keep the upcoming module extension a
  bit cleaner.
  • Loading branch information
mbland committed Feb 28, 2025
1 parent eadc090 commit b822a64
Show file tree
Hide file tree
Showing 58 changed files with 432 additions and 263 deletions.
23 changes: 12 additions & 11 deletions .bazelci/presubmit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,17 @@ tasks:
# Install xmllint
- sudo apt update && sudo apt install --reinstall libxml2-utils -y
- "./test_rules_scala.sh"
test_rules_scala_linux_latest:
name: "./test_rules_scala (latest Bazel)"
# Switch `last_rc` to `last_green` once Bzlmod lands.
# https://github.com/bazelbuild/rules_scala/issues/1482
test_rules_scala_linux_last_rc:
name: "./test_rules_scala (last_rc Bazel)"
platform: ubuntu2004
# Restore `bazel: latest` once Bazel 8 compatibility lands (#1625, #1652).
bazel: 7.x
bazel: last_rc
shell_commands:
# Install xmllint
- sudo apt update && sudo apt install --reinstall libxml2-utils -y
- echo "build --enable_workspace" >> .bazelrc
- "./test_rules_scala.sh || buildkite-agent annotate --style 'warning' \"Optional build with latest Bazel version failed, [see here](${BUILDKITE_BUILD_URL}#${BUILDKITE_JOB_ID}) (It is not mandatory but worth checking)\""
- "./test_rules_scala.sh || buildkite-agent annotate --style 'warning' \"Optional build with last_rc Bazel version failed, [see here](${BUILDKITE_BUILD_URL}#${BUILDKITE_JOB_ID}) (It is not mandatory but worth checking)\""
test_rules_scala_macos:
name: "./test_rules_scala"
platform: macos
Expand All @@ -53,16 +54,16 @@ tasks:
- "set PATH=/usr/bin;%PATH%" #Make sure bash uses msys commands over windows commands. (i.e. find).
- "bash -lc \"pacman --noconfirm --needed -S libxml2\"" #tests require xmllint
- "bash test_rules_scala.sh"
test_coverage_linux_6_5_0:
test_coverage_linux_7_5_0:
name: "./test_coverage"
platform: ubuntu2004
bazel: 6.5.0
bazel: 7.5.0
shell_commands:
- "./test_coverage.sh"
test_coverage_macos_6.5.0:
test_coverage_macos_7.5.0:
name: "./test_coverage"
platform: macos
bazel: 6.5.0
bazel: 7.5.0
shell_commands:
- "./test_coverage.sh"
test_reproducibility_linux:
Expand Down Expand Up @@ -93,13 +94,13 @@ tasks:
examples_linux:
name: "./test_examples"
platform: ubuntu2004
bazel: 6.5.0
bazel: 7.5.0
shell_commands:
- "./test_examples.sh"
cross_build_linux:
name: "./test_cross_build"
platform: ubuntu2004
bazel: 6.5.0
bazel: 7.5.0
shell_commands:
- "./test_cross_build.sh"
lint_linux:
Expand Down
8 changes: 4 additions & 4 deletions .bazelrc
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Switch to --noenable_workspace when Bzlmod lands.
# https://github.com/bazelbuild/rules_scala/issues/1482
common --enable_workspace --noenable_bzlmod

build --enable_platform_specific_config

#Windows needs --worker_quit_after_build due to workers not being shut down when the compiler tools need to be rebuilt (resulting in 'file in use' errors). See Bazel Issue#10498.

build:windows --worker_quit_after_build --enable_runfiles

# Remove upon completing Bzlmod compatibility work.
# - https://github.com/bazelbuild/rules_scala/issues/1482
build --noenable_bzlmod
2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.5.0
7.5.0
118 changes: 64 additions & 54 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,7 @@ load("@rules_scala//scala:deps.bzl", "rules_scala_dependencies")

rules_scala_dependencies()

# In `rules_scala` 7.x, `scala/deps.bzl` imports `rules_java` 7.x. This
# statement will change for `rules_scala` 8.x, which will use `rules_java` 8.x.
load(
"@rules_java//java:repositories.bzl",
"rules_java_dependencies",
"rules_java_toolchains",
)
load("@rules_java//java:rules_java_deps.bzl", "rules_java_dependencies")

rules_java_dependencies()

Expand All @@ -78,13 +72,11 @@ bazel_skylib_workspace()

# If you need a specific `rules_python` version, specify it here.
# Otherwise you may get the version defined in the `com_google_protobuf` repo.
# We use 0.38.0 to maintain compatibility with Bazel 6.5.0; this will change in
# rules_scala 8.0.0.
http_archive(
name = "rules_python",
sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
strip_prefix = "rules_python-0.38.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
sha256 = "9c6e26911a79fbf510a8f06d8eedb40f412023cf7fa6d1461def27116bff022c",
strip_prefix = "rules_python-1.1.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/1.1.0/rules_python-1.1.0.tar.gz",
)

load("@rules_python//python:repositories.bzl", "py_repositories")
Expand All @@ -100,6 +92,8 @@ load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

protobuf_deps()

load("@rules_java//java:repositories.bzl", "rules_java_toolchains")

rules_java_toolchains()

load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies")
Expand Down Expand Up @@ -256,14 +250,14 @@ maximum available at the time of writing.

[ci-config]: ./.bazelci/presubmit.yml

| Bazel/Dependency | `rules_scala` 7.x | `rules_scala` 8.x<br/>(Coming soon! See bazelbuild/rules_scala#1482 and bazelbuild/rules_scala#1652.) |
| :-: | :-: | :-: |
| Bazel versions using Bzlmod<br/>(Coming soon! See bazelbuild/rules_scala#1482.) | 6.5.0, 7.5.0 | 7.5.0, 8.x |
| Bazel versions using `WORKSPACE` | 6.5.0, 7.5.0 | 6.5.0, 7.5.0, 8.x<br/>(see the [notes on 6.5.0 compatibility](#6.5.0)) |
| `protobuf` | v21.7<br/>(can support up to v25.5) | v29.3 |
| `abseil-cpp` | 20220623.1 | 20250127.0 |
| `rules_java` | 7.12.4 | 8.x |
| `ScalaPB` | 0.11.17<br/>(0.9.8 for Scala 2.11) | 1.0.0-alpha.1 |
| Bazel/Dependency | `rules_scala` 7.x |
| :-: | :-: |
| Bazel versions using Bzlmod<br/>(Coming soon! See bazelbuild/rules_scala#1482.) | 7.5.0, 8.x |
| Bazel versions using `WORKSPACE` | 6.5.0, 7.5.0, 8.x<br/>(see the [notes on 6.5.0 compatibility](#6.5.0)) |
| `protobuf` | v29.3 |
| `abseil-cpp` | 20250127.0 |
| `rules_java` | 8.9.0 |
| `ScalaPB` | 1.0.0-alpha.1 |

## Usage with [bazel-deps](https://github.com/johnynek/bazel-deps)

Expand Down Expand Up @@ -351,9 +345,13 @@ that folder.
## Breaking changes in `rules_scala` 7.x

__The main objective of `rules_scala` 7.x is to enable existing users to migrate
to Bazel 7 and Bzlmod.__ To facilitate a gradual migration, it remains
compatible with both `WORKSPACE` and Bzlmod. However, it contains the following
breaking changes when upgrading from `rules_scala` 6.x.
to Bazel 8 and Bzlmod.__ To facilitate a gradual migration, it is compatible
with both Bazel 7 and Bazel 8, and both `WORKSPACE` and Bzlmod. It remains
compatible with Bazel 6.5.0 builds using `WORKSPACE` for the time being, but
Bazel 6 is no longer officially supported.

`rules_java` 7.x contains the following breaking changes when upgrading from
`rules_scala` 6.x.

### <a id="new-toolchains-api"></a>New `scala_toolchains()` API for `WORKSPACE`

Expand Down Expand Up @@ -710,13 +708,6 @@ dependencies into scope. However, another way to fix this specific problem is to
call `use_repo` for every builtin repository needed by the
`setup_scala_toolchain()` call.

## Breaking changes coming in `rules_scala` 8.x

__The main objective of 8.x will be to enable existing users to migrate to Bazel
8 and Bzlmod.__ To facilitate a gradual migration, it will remain compatible
with both `WORKSPACE` and Bzlmod. However, it will contain the following
breaking changes when upgrading from `rules_scala` 7.x.

### Replace some `$(location)` calls with `$(rootpath)` for Bazel 8

This isn't actually a `rules_scala` breakage, but a Bazel 8 breakage encountered
Expand All @@ -731,16 +722,16 @@ future compatibility.

### <a id="6.5.0"></a>Limited Bazel 6.5.0 compatibility

`rules_scala` 8.0.0 will not support Bzlmod with Bazel 6.5.0 because
[Bazel 6.5.0 doesn't support 'use_repo_rule'](
https://bazel.build/versions/6.5.0/rules/lib/globals), which
__`rules_scala` 7.x officially drops support for Bazel 6.5.0.__ Bzlmod builds
with Bazel 6.5.0 won't work at all because [Bazel 6.5.0 doesn't support
'use_repo_rule']( https://bazel.build/versions/6.5.0/rules/lib/globals), which
['rules_jvm_external' >= 6.3 requires](
https://github.com/bazelbuild/rules_scala/issues/1482#issuecomment-2515496234).

`WORKSPACE` builds will continue to work with Bazel 6.5.0, but not out of the
box. Per bazelbuild/rules_scala#1647, using Bazel 6.5.0 with `rules_scala` 8.x
will require adding the following flags to `.bazelrc`, required by the newer
`abseil-cpp` version used by `protobuf`:
At the moment, `WORKSPACE` builds mostly continue to work with Bazel 6.5.0, but
not out of the box, and may break at any time. Per bazelbuild/rules_scala#1647,
such builds require adding the following flags to `.bazelrc`, required by the
newer `abseil-cpp` version used by `protobuf`:

```txt
common --enable_platform_specific_config
Expand All @@ -757,27 +748,46 @@ Note that this example uses `common:` config settings instead of `build:`. This
seems to prevent invalidating the action cache between `bazel` runs, which
improves performance.

### Bazel module compatibility levels between 7.0.0 and 8.0.0
If you have another dependency that requires an earlier `protobuf` version, use
the following maximum dependency versions:

`rules_scala` 7.0.0 and 8.0.0 will have different
[`compatibility_level`](https://bazel.build/external/module#compatibility_level)
values for their [`module()`](https://bazel.build/rules/lib/globals/module)
directives. This is due to the gap in supported `protobuf` versions documented
in bazelbuild/rules_scala#1647 (between v25.5 and v28) and dropping support for
Bazel 6.5.0 Bzlmod builds.
| Dependency | Max Bazel 6.5.0 compatible version | Reason |
| :-: | :-: | :- |
| `protobuf` | v25.6 | `ScalaPB` doesn't support `protobuf` v26 or v27. |
| `abseil-cpp` | 20240722.0 | Latest that works with `protobuf` v25; requires C++ compiler flags. |
| `rules_java` | 7.12.4 | 8.x requires `protobuf` v27 and later. |
| `rules_cc` | 0.0.9 | 0.0.10 requires Bazel 7 to define `CcSharedLibraryHintInfo`.<br/>0.0.13 requires at least `protobuf` v27.0. |
| `ScalaPB` | 0.11.17<br/>(0.9.8 for Scala 2.11) | Supports `protobuf` < v26. |

### `scala_proto` not supported for Scala 2.11

[ScalaPB 0.9.8](https://github.com/scalapb/ScalaPB/releases/tag/v0.9.8), the
last version compatible with Scala 2.11, does not support `protobuf` >= v26.
Since `rules_scala` now depends on a more recent `protobuf` version, we had to
remove the Scala 2.11 test cases.

This will ensure any users attempting to mismatch `protobuf` and `rules_scala`
versions will break during module resolution, rather than during a later
execution step. (Though, as described in bazelbuild/rules_scala#1647, there are
now measures in place to cause the build to crash during a mismatch instead of
hanging.)
Building `scala_proto` for Scala 2.11 requires [building with Bazel 6.5.0
under `WORKSPACE`](#6.5.0), with the maximum dependency versions specified in
that section. While this may continue to work for some time, it is not
officially supported.

### Bazel module compatibility levels

`rules_scala` 7.0.0 will set the
[`compatibility_level`](https://bazel.build/external/module#compatibility_level)
value for its [`module()`](https://bazel.build/rules/lib/globals/module)
directive. The `compatibility_level` for `rules_scala` will track major version
numbers (per [semantic versioning](https://semver.org/)), and this `README` will
clearly document the reason for the level bump. `compatibility_level` mismatches
in the module graph will cause module resolution to fail, signaling the presence
of known breaking changes.

The concept of proper `compatibility_level` usage is still up for discussion in
bazelbuild/bazel#24302. The `compatibility_level` for `rules_scala`
implementation will track major version numbers (per [semantic
versioning](https://semver.org/)), and clearly document the reason for the level
bump. If a version bump may break builds for any known reason, we will explain
why up front instead of waiting for users to be surprised.
bazelbuild/bazel#24302. However, the policy above favors forcing module
resolution to fail, rather than allowing a later execution step to fail with a
potentially confusing error message. If a version bump may break builds for any
known reason, we will explain why up front instead of waiting for users to be
surprised.

[A comment from #1647 illustrates how 'rules_erlang' fails due to
'compatibility_level' conflicts][erlang]. The ['rules_erlang' 3.0.0 release
Expand Down
14 changes: 6 additions & 8 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,7 @@ load("//scala:deps.bzl", "rules_scala_dependencies")

rules_scala_dependencies()

load(
"@rules_java//java:repositories.bzl",
"rules_java_dependencies",
"rules_java_toolchains",
)
load("@rules_java//java:rules_java_deps.bzl", "rules_java_dependencies")

rules_java_dependencies()

Expand All @@ -19,9 +15,9 @@ bazel_skylib_workspace()

http_archive(
name = "rules_python",
sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
strip_prefix = "rules_python-0.38.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
sha256 = "2ef40fdcd797e07f0b6abda446d1d84e2d9570d234fddf8fcd2aa262da852d1c",
strip_prefix = "rules_python-1.2.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/1.2.0/rules_python-1.2.0.tar.gz",
)

load("@rules_python//python:repositories.bzl", "py_repositories")
Expand All @@ -32,6 +28,8 @@ load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

protobuf_deps()

load("@rules_java//java:repositories.bzl", "rules_java_toolchains")

rules_java_toolchains()

load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies")
Expand Down
2 changes: 1 addition & 1 deletion dt_patches/compiler_sources/.bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.5.0
7.5.0
2 changes: 1 addition & 1 deletion dt_patches/test_dt_patches/.bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.5.0
7.5.0
10 changes: 6 additions & 4 deletions dt_patches/test_dt_patches/WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ load("@rules_scala//scala:deps.bzl", "rules_scala_dependencies")

rules_scala_dependencies()

load("@rules_java//java:repositories.bzl", "rules_java_dependencies", "rules_java_toolchains")
load("@rules_java//java:rules_java_deps.bzl", "rules_java_dependencies")

rules_java_dependencies()

Expand All @@ -21,9 +21,9 @@ bazel_skylib_workspace()

http_archive(
name = "rules_python",
sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
strip_prefix = "rules_python-0.38.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
sha256 = "2ef40fdcd797e07f0b6abda446d1d84e2d9570d234fddf8fcd2aa262da852d1c",
strip_prefix = "rules_python-1.2.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/1.2.0/rules_python-1.2.0.tar.gz",
)

load("@rules_python//python:repositories.bzl", "py_repositories")
Expand All @@ -34,6 +34,8 @@ load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

protobuf_deps()

load("@rules_java//java:repositories.bzl", "rules_java_toolchains")

rules_java_toolchains()

load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies")
Expand Down
2 changes: 1 addition & 1 deletion dt_patches/test_dt_patches_user_srcjar/.bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.5.0
7.5.0
10 changes: 6 additions & 4 deletions dt_patches/test_dt_patches_user_srcjar/WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ load("@rules_scala//scala:deps.bzl", "rules_scala_dependencies")

rules_scala_dependencies()

load("@rules_java//java:repositories.bzl", "rules_java_dependencies", "rules_java_toolchains")
load("@rules_java//java:rules_java_deps.bzl", "rules_java_dependencies")

rules_java_dependencies()

Expand All @@ -21,9 +21,9 @@ bazel_skylib_workspace()

http_archive(
name = "rules_python",
sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
strip_prefix = "rules_python-0.38.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
sha256 = "2ef40fdcd797e07f0b6abda446d1d84e2d9570d234fddf8fcd2aa262da852d1c",
strip_prefix = "rules_python-1.2.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/1.2.0/rules_python-1.2.0.tar.gz",
)

load("@rules_python//python:repositories.bzl", "py_repositories")
Expand All @@ -34,6 +34,8 @@ load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

protobuf_deps()

load("@rules_java//java:repositories.bzl", "rules_java_toolchains")

rules_java_toolchains()

load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies")
Expand Down
2 changes: 1 addition & 1 deletion examples/crossbuild/.bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.5.0
7.5.0
10 changes: 6 additions & 4 deletions examples/crossbuild/WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ load("@rules_scala//scala:deps.bzl", "rules_scala_dependencies")

rules_scala_dependencies()

load("@rules_java//java:repositories.bzl", "rules_java_dependencies", "rules_java_toolchains")
load("@rules_java//java:rules_java_deps.bzl", "rules_java_dependencies")

rules_java_dependencies()

Expand All @@ -21,9 +21,9 @@ bazel_skylib_workspace()

http_archive(
name = "rules_python",
sha256 = "ca2671529884e3ecb5b79d6a5608c7373a82078c3553b1fa53206e6b9dddab34",
strip_prefix = "rules_python-0.38.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/0.38.0/rules_python-0.38.0.tar.gz",
sha256 = "2ef40fdcd797e07f0b6abda446d1d84e2d9570d234fddf8fcd2aa262da852d1c",
strip_prefix = "rules_python-1.2.0",
url = "https://github.com/bazelbuild/rules_python/releases/download/1.2.0/rules_python-1.2.0.tar.gz",
)

load("@rules_python//python:repositories.bzl", "py_repositories")
Expand All @@ -34,6 +34,8 @@ load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")

protobuf_deps()

load("@rules_java//java:repositories.bzl", "rules_java_toolchains")

rules_java_toolchains()

load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies")
Expand Down
Loading

0 comments on commit b822a64

Please sign in to comment.