bazelbuild / bazel

a fast, scalable, multi-language and extensible build system
https://bazel.build
Apache License 2.0
23.21k stars 4.06k forks source link

[Bazel CI] Downstream project broken by rules_java upgrade #23619

Open meteorcloudy opened 1 month ago

meteorcloudy commented 1 month ago
(04:10:49) ERROR: /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/67c259e1fb9766950734b85418b03ced/external/rules_java_builtin/toolchains/BUILD:285:14: While resolving toolchains for target @@rules_java_builtin//toolchains:platformclasspath (4f6c53c): No matching toolchains found for types @@rules_java_builtin//toolchains:bootstrap_runtime_toolchain_type.
To debug, rerun with --toolchain_resolution_debug='@@rules_java_builtin//toolchains:bootstrap_runtime_toolchain_type'

Bisect points to https://github.com/bazelbuild/bazel/commit/f92124acf3d0eb99d06570ddc380aca7ab354b90

meteorcloudy commented 1 month ago

@hvadehra Looks like https://github.com/bazelbuild/bazel/pull/23571 is getting cherry-picked back to 7.4, you probably want to fix this one to make sure the upgrade is backwards compatible?

meteorcloudy commented 1 month ago

I bisected with rules_android using

bazel --bisect=c364bd65eee1b5b0874de85f41c39c2d6915ff8b..HEAD build --enable_workspace --noenable_bzlmod --nobuild //test/rules/...
meteorcloudy commented 1 month ago

https://github.com/kythe/kythe/issues/6138 might be the same issue

hvadehra commented 1 month ago

cc @comius

hvadehra commented 1 month ago

Looks like the failures are only when using WORKSPACE, and not with bzlmod. So presumably they're picking up an older version of rules_java?