Skip to content

fix: parse LEAN_VERSION_MINOR correctly in release_checklist.py - #12785

Merged
kim-em merged 1 commit into
masterfrom
fix-release-checklist-cmake-parse
Mar 4, 2026
Merged

kim-em merged 1 commit into
masterfrom
fix-release-checklist-cmake-parse

Conversation

@kim-em

@kim-em kim-em commented Mar 4, 2026 •

Copy link
Copy Markdown
Collaborator

This PR fixes a parsing bug in `release_checklist.py` introduced by #12700, which changed the version variables in `src/CMakeLists.txt` to use `CACHE STRING ""` for overridability:

```cmake
set(LEAN_VERSION_MINOR 30 CACHE STRING "")
```

The old code used `split()[-1].rstrip(")")` to extract the version number, which now yields `""` (the empty string argument) instead of the minor version. Use a regex to extract the digit directly.

🤖 Prepared with Claude Code

The CMakeLists.txt format is `set(LEAN_VERSION_MINOR 30 CACHE STRING "")`,
so taking `split()[-1]` gives `""` not the version number. Use a regex to
extract the digit directly.

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
@kim-em kim-em added the changelog-no Do not include this PR in the release changelog label Mar 4, 2026
@kim-em
kim-em enabled auto-merge March 4, 2026 11:51
@kim-em
kim-em added this pull request to the merge queue Mar 4, 2026
Merged via the queue into master with commit 1c60b40 Mar 4, 2026
23 of 25 checks passed
@github-actions github-actions Bot added the toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN label Mar 4, 2026
@mathlib-lean-pr-testing

Copy link
Copy Markdown

Mathlib CI status (docs):

  • ❗ Batteries/Mathlib CI will not be attempted unless your PR branches off the nightly-with-mathlib branch. Try git rebase 0fb289c4705c63f8fb0b1fc311c027868da20654 --onto cda84702e9b31165f1f83c657b532f36f34e0bd0. You can force Mathlib CI using the force-mathlib-ci label. (2026-03-04 12:19:46)

@leanprover-bot

Copy link
Copy Markdown
Collaborator

Reference manual CI status:

  • ❗ Reference manual CI will not be attempted unless your PR branches off the nightly-with-manual branch. Try git rebase 0fb289c4705c63f8fb0b1fc311c027868da20654 --onto cda84702e9b31165f1f83c657b532f36f34e0bd0. You can force reference manual CI using the force-manual-ci label. (2026-03-04 12:19:47)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog-no Do not include this PR in the release changelog toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants