Repository navigation
Bump llvm 0.8.26, rules_rs 0.2.0, protobuf 36.2; fix BCR incompatible-flags failure - #588
Merged
tinder-maxwellelliott merged 7 commits intoOct 30, 2026
Conversation
…-flags failure BCR has merged bazel-diff up to 67.0.1. Every registry PR since (67.0.2, 67.0.3, 68.0.0) fails all Bazel 8.x presubmit tasks with exit 73: BCR rebuilds each verify_targets task once per flag in its incompatible_flags.yml, and --incompatible_config_setting_private_default_visibility fails because 67.0.2 added the `without_mimalloc` config_setting without a visibility. Reproduced locally by consuming the v68.0.0 archive: target '@@bazel-diff+//src:without_mimalloc' is not visible from target '@@bazel-diff+//src:bazel-diff' The config_setting is now public, and bcr_consumer.yaml builds the 8.x row with the same five flags so this is caught on a PR rather than after a release. Dependency bumps: - llvm 0.8.19 -> 0.8.26: hermetic-llvm#853 (0.8.26) fixes the Windows exec host analysis cycle (hermetic-llvm#809, rules_rs#271) that kept the pin at 0.8.19. - rules_rs 0.1.3 -> 0.2.0: requires Bazel 8.7+, so bazel_compatibility and the CI minimum-Bazel example row move from 8.5.0 to 8.7.0. - protobuf 33.4 -> 36.2. Verified: bazel test //src/... //tools/... //:rust_clippy_check //:rust_format_check (16 pass); consumer build of the release archive with all five BCR incompatible flags on Bazel 8.x succeeds. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
llvm 0.8.26 registers hermetic Windows MSVC toolchains that match //platforms:windows_msvc. They download the MSVC runtime and Windows SDK through windows_support, which fails unless every Windows builder passes --repo_env=BAZEL_MSVC_RUNTIME_VISUAL_STUDIO_EULA=1 and --repo_env=BAZEL_WINDOWS_SDK_EULA=1 (both Windows CI example jobs failed there). Registering the 16 Linux/macOS exec-to-target toolchains explicitly leaves Windows on the locally installed Visual Studio toolchain, as with llvm 0.8.19, with no license acceptance in the repo or for consumers. Verified on macOS: toolchain resolution still selects the llvm toolchain for the host and for the x86_64-unknown-linux-musl release target; the musl release binary builds; the test suite passes. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The consumer workflow mirrored the registry presubmit's verify_targets builds but skipped its incompatible-flags phase, which is what rejected 67.0.2 through 68.0.0. It now downloads bazel-central-registry's incompatible_flags.yml, selects the flags for the matrix Bazel version with tools/bcr_incompatible_flags.py (a small parser for that file's shape, unit tested, so the runner needs no YAML library), and rebuilds the consumer targets once per flag like BCR does, naming every flag that needs migration. The matrix also gains windows-latest rows that use the presubmit's Windows build_flags, since the MAX_PATH stall in October was a Windows-only presubmit failure nothing here caught. Verified locally: the script returns BCR's five 8.x flags and none for 9.x against the live file; the per-flag loop passes all five against the packed release archive. The Windows rows are verified by this PR's CI. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
RUNNER_TEMP is "D:\a\_temp" on Windows; GNU tar in Git Bash read the drive
colon as a remote host ("Cannot connect to D: resolve failed") and the pack
step failed. Resolve the directory with cygpath once and use that path in
every bash step; the archive_override URL still derives its mixed-style
path from it.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Python on Windows writes the flag list with CRLF, so each flag reached Bazel with a trailing carriage return and was rejected as "Unrecognized option" against its own name. Strip it in the loop. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The Windows example job builds bazel-diff at HEAD, checks out the previous revision (master) and let the script `bazel run` there, rebuilding master's protobuf 33.4 with rules_cc 0.2.22 in the output base the HEAD build had just populated with rules_cc 0.2.25. MSVC's include validation then rejects protobuf_lite with an undeclared inclusion of a _virtual_includes header; master on its own passes, and the Linux job survives the same switch. Build once at HEAD and hand the script that binary through BAZEL_DIFF_BINARY, the override the script already honours. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The per-incompatible-flag rebuilds make the Windows 8.x row take about 40 minutes, which is too slow for every pull request. Releases are cut from master, so running there still catches a registry rejection before the next release. None of the rows is a required check. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
tinder-maxwellelliott
deleted the
claude/upgrade-llvm-protobuf-rules-rs-9757fb
branch
October 30, 2026 19:27
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.
Why BCR stopped merging at 67.0.1
Registry PRs for 67.0.2, 67.0.3 and 68.0.0 (#11404, #11422, #11451) pass every Bazel 9.x task and fail every 8.x task. The Buildkite log ends with:
BCR rebuilds each
verify_targetstask once per flag listed in itsincompatible_flags.yml(five flags for 8.x, none for 9.x). 67.0.2 (#580) addedconfig_setting(name = "without_mimalloc")insrc/BUILDwith no visibility, which that flag makes private. Reproduced locally by consuming the v68.0.0 archive with the flag:Separately, 68.0.0's registry PR is still a draft (publish-to-bcr opens drafts; marking it ready triggers the auto-approve) and its pipeline step 404'd on
release.tar.gzbecause the GitHub release was still a draft when Buildkite ran (publish at 13:23, finalize at 13:41). The fix here only reaches BCR with the next release; the three stuck PRs can be bypassed with a@bazel-io skip_check incompatible_flagscomment from their author or closed.Changes
src/BUILD:without_mimallocis//visibility:public.bcr_consumer.yaml: now mirrors the registry presubmit's incompatible-flags phase. It downloads BCR'sincompatible_flags.yml, selects the flags for the matrix Bazel version with the newtools/bcr_incompatible_flags.py(unit tested), and rebuilds the consumer targets once per flag like BCR does, so this class of failure fails here instead of the registry. The matrix also gains windows-latest rows using the presubmit's Windows build_flags, since last month's MAX_PATH stall was a Windows-only presubmit failure nothing here caught. The per-flag rebuilds push the Windows 8.x row to about 40 minutes, so the workflow now runs on master pushes and on demand rather than on every PR; releases are cut from master, so a registry rejection is still caught before the next release, and none of the rows is a required check.MODULE.bazel: llvm 0.8.19 → 0.8.26 (hermetic-llvm#853 fixes the Windows exec-host cycle hermetic-llvm#809 / rules_rs#271 that pinned us), rules_rs 0.1.3 → 0.2.0, protobuf 33.4 → 36.2. rules_rs 0.2.0 requires Bazel 8.7+, sobazel_compatibilityand the CI minimum-Bazel example row move from 8.5.0 to 8.7.0.MODULE.bazel.lockregenerated.Verification
bazel test //src/... //tools/... //:rust_clippy_check //:rust_format_check: 16/16 pass.Windows stays on the locally installed MSVC
llvm 0.8.26's hermetic Windows MSVC toolchain downloads the MSVC runtime and Windows SDK, which refuse without
--repo_env=BAZEL_MSVC_RUNTIME_VISUAL_STUDIO_EULA=1and--repo_env=BAZEL_WINDOWS_SDK_EULA=1from every Windows builder (both Windows example jobs failed on that). Rather than accept Microsoft's licenses in the repo and require them of Windows consumers,register_toolchainsnow lists the 16 Linux/macOS exec-to-target toolchains explicitly and leaves the Windows ones unregistered, so Windows keeps using Visual Studio as with llvm 0.8.19. Verified on macOS that the host and the musl Linux release target still resolve to the llvm toolchain.Windows upgrade note
llvm 0.8.26 raises rules_cc from 0.2.22 to 0.2.25. On Windows (local MSVC), building a pre-bump revision in an output base that a post-bump build has populated fails with an undeclared inclusion of a protobuf
_virtual_includesheader; each revision builds fine on its own, and Linux is unaffected. The Windows example CI job hit this by rebuilding master after HEAD, so it now builds once at HEAD and passes the binary to the script. A Windows user switching bazel-diff across this bump in one output base needs abazel clean.🤖 Generated with Claude Code