I got a bazel-ci bug report that bazel-remote fails to build with the tip of bazel's master branch, because incompatible_use_toolchain_transition has been removed:
buchgr/bazel-remote#831
(04:09:29) ERROR: Traceback (most recent call last):
--
| File "/var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/3025b0a37590b9c7d740f1ac50d854c9/external/aspect_bazel_lib++toolchains+bsd_tar_toolchains/defs.bzl", line 15, column 20, in <toplevel>
| resolved_toolchain = rule(
| Error in rule: rule() got unexpected keyword argument 'incompatible_use_toolchain_transition'
| (04:09:29) ERROR: /var/lib/buildkite-agent/builds/bk-docker-j6js/bazel-org-repo-root/bazel-remote/BUILD.bazel:104:10: While resolving toolchains for target //:bazel-remote-image (3a46b04): invalid registered toolchain '@bsd_tar_toolchains//:all': while parsing '@bsd_tar_toolchains//:all': error loading package '@@aspect_bazel_lib++toolchains+bsd_tar_toolchains//': initialization of module 'defs.bzl' failed
| (04:09:29) ERROR: Analysis of target '//:bazel-remote-image' failed; build aborted
| (04:09:29) INFO: Elapsed time: 2.776s, Critical Path: 0.02s
| (04:09:29) INFO: 1 process: 1 internal.
| (04:09:29) ERROR: Build did NOT complete successfully
| (04:09:29) FAILED:
It looks like incompatible_use_toolchain_transition was removed from rules_pkg, and then added back because it broke builds using bazel 4.x. Is it time to remove it again?