ci(lean): adopt the rules_lean platform fix, drop the workaround and the stale patch - #296
Open
avrabe wants to merge 1 commit into
Open
ci(lean): adopt the rules_lean platform fix, drop the workaround and the stale patch#296avrabe wants to merge 1 commit into
avrabe wants to merge 1 commit into
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
…the stale patch
rules_lean#30 is fixed upstream in 70f5138 — "detect host platform at fetch time,
not lock time". Verified against gale rather than taken on the closure:
BEFORE (lock generated on this Mac):
"mathlib": { "attributes": {
"host_platform": "darwin_aarch64", <- froze the toolchain into the lock
"lean_version": "4.27.0", "mathlib_rev": "v4.27.0" } }
AFTER re-resolving on the new pin:
"mathlib": { "attributes": {
"lean_version": "4.27.0", "mathlib_rev": "v4.27.0" } }
host_platform is gone, so a committed lock is platform-neutral again. All four
platform repos are still generated (lean_{darwin,linux}_{aarch64,x86_64}); what
changed is that mathlib no longer pins one of them permanently.
So --lockfile_mode=off is removed. It was always a workaround with a named exit
condition, and this is that condition.
PATCH DROPPED, NOT REBASED. patches/rules_lean_mathlib_timeout.patch raised the
`lake update` timeout 600 -> 1800 and conflicted with the upstream change
(CONTENT_DOES_NOT_MATCH_TARGET near line 162). Rather than rebase it I checked
whether it was still needed: upstream now uses 3600/1200/7200, all larger than
our 1800. The patch was obsolete. patches/ is now empty and removed.
CI IS THE KILL-CRITERION, and it is the one I wrote on rules_lean#30: this
lockfile was generated on darwin_aarch64 and is committed unchanged; the Lean job
runs on ubuntu-22.04. If it goes green, a macOS-generated lock produced a working
Linux build — which is exactly what could not happen before. Locally: 8 of 8.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011QG86sovTbfnPNY9SfhSmo
avrabe
force-pushed
the
ci/rules-lean-platform-fix
branch
from
August 26, 2026 19:35
1e1f323 to
329b1e1
Compare
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.
rules_lean#30 is fixed upstream in
70f5138— "detect host platform at fetch time, not lock time". Verified against gale rather than taken on the closure.The lockfile is platform-neutral again
Before (lock generated on this Mac):
After re-resolving on the new pin:
host_platformis gone. All four platform repos are still generated (lean_{darwin,linux}_{aarch64,x86_64}) — what changed is thatmathlibno longer pins one of them permanently, which is what made a Linux runner execute a Mach-Olake(#288).So
--lockfile_mode=offis removed. It was a workaround with a named exit condition, and this is that condition.The patch is dropped, not rebased
patches/rules_lean_mathlib_timeout.patchconflicted with the upstream change (CONTENT_DOES_NOT_MATCH_TARGETnear line 162). Rather than rebase it I checked whether it was still needed: it raised thelake updatetimeout 600 → 1800, and upstream now uses 3600 / 1200 / 7200 — all larger. It was obsolete, not merely conflicting.patches/is now empty and removed.CI is the kill-criterion
This is the criterion I wrote on rules_lean#30, and this PR runs it for real:
The committed lockfile here was generated on
darwin_aarch64; theLean Proofsjob runs onubuntu-22.04. If it goes green, a macOS-generated lock produced a working Linux build — precisely what could not happen before. That is not something I can prove locally, which is the point.Locally:
bazel test //proofs/lean:all→ 8 of 8.Note
The
leanjob here still gates on//proofs/lean:all, so #295'sPartitionSupply.leanstays covered. Merge order between the two does not matter; whichever lands second rebases onto the other.🤖 Generated with Claude Code
https://claude.ai/code/session_011QG86sovTbfnPNY9SfhSmo