Update rules_rust to 0.73.0; drop unused rules_rust WORKSPACE setup - #812
Merged
Merged
Conversation
rules_rust >= 0.71 no longer ships rust/repositories.bzl (WORKSPACE support removed). Under hybrid mode (--enable_bzlmod --enable_workspace, i.e. Bazel 7/8 CI jobs), the root module's bazel_dep repos shadow same-named WORKSPACE repos, so the load() of that file in tests/WORKSPACE resolved to the bzlmod rules_rust and broke the main repository mapping for every hybrid invocation - this is what forced the rules_rust upgrade to be reverted in bazel-contrib#811. The WORKSPACE rules_rust setup is dead weight anyway: the rules_rust tests in run_external_tests.sh only run with bzlmod enabled. Remove it and re-apply the rules_rust 0.70.0 -> 0.73.0 upgrade (bazel-contrib#787).
helly25
requested review from
dzbarsky,
fmeum,
jsharpe and
rrbutani
as code owners
August 4, 2026 06:40
helly25
enabled auto-merge (squash)
August 4, 2026 07:36
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Re-applies the rules_rust 0.70.0 → 0.73.0 upgrade (#787) that had to be reverted in #811, by first removing the root cause: the unused rules_rust setup in
tests/WORKSPACE.Why the upgrade broke hybrid mode: rules_rust ≥ 0.71 no longer ships
rust/repositories.bzl(WORKSPACE support removed upstream). In the hybrid CI jobs (Bazel 7/8 with--enable_bzlmod --enable_workspace), the root module'sbazel_deprepos shadow same-named WORKSPACE repos — so theload("@rules_rust//rust:repositories.bzl", ...)intests/WORKSPACEresolved to the bzlmod rules_rust (not the WORKSPACE-pinned 0.67.0 http_archive) and failed with:This killed every bazel invocation in those jobs, including ones that don't use rust at all (msan). Bazel 9 jobs were unaffected (WORKSPACE is gone there); pure-WORKSPACE jobs (bzlmod=false) were unaffected (no shadowing).
Why removing the WORKSPACE setup is safe: the rules_rust tests in
run_external_tests.shonly run with bzlmod enabled (Bazel 9+), and nothing else in the tests workspace uses rust. The WORKSPACE block was dead weight. A comment now documents why it must not be re-added.Closes #787.
Test plan
@rules_rust//test/unit/{interleaved_cc_info,native_deps}:allat 0.73.0 passed previously on the chore(deps): combined dependency upgrades unblocked by #810 #811 branch pre-revert; a Bazel 8 hybrid-mode analysis run is in flight and results will be posted here if anything turns up.