Skip to content

fix: lake: await needs before processing module headers#13601

Merged
tydeu merged 1 commit into
leanprover:masterfrom
tydeu:lake/await-needs
May 3, 2026
Merged

fix: lake: await needs before processing module headers#13601
tydeu merged 1 commit into
leanprover:masterfrom
tydeu:lake/await-needs

Conversation

@tydeu
Copy link
Copy Markdown
Member

@tydeu tydeu commented May 2, 2026

This PR changes Lake's module import graph processing to await the completion of any needs targets or other extra dependencies (such as cloud releases). This both enables the needs targets to influence header processing and prevents them from racing with said processing.

Known Limitation: This PR currently blocks on the needs targets rather than running the import processing in a callback. This is done to keep import processing simple and in a single thread. If this proves to be a performance issue, this can be restructured in a future PR with a more sophisticated refactor.

Closes #13598

@tydeu tydeu added changelog-lake Lake lake-ci Run all Lake tests labels May 2, 2026
@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 May 2, 2026
@leanprover-bot
Copy link
Copy Markdown
Collaborator

Reference manual CI status:

  • ❗ Reference manual CI can not be attempted yet, as the nightly-testing-2026-04-29 tag does not exist there yet. We will retry when you push more commits. If you rebase your branch onto nightly-with-manual, reference manual CI should run now. You can force reference manual CI using the force-manual-ci label. (2026-05-02 07:40:23)

@github-actions github-actions Bot added the mathlib4-nightly-available A branch for this PR exists at leanprover-community/mathlib4-nightly-testing:lean-pr-testing-NNNN label May 2, 2026
@tydeu tydeu marked this pull request as ready for review May 2, 2026 07:55
@mathlib-lean-pr-testing
Copy link
Copy Markdown

Mathlib CI status (docs):

@mathlib-lean-pr-testing mathlib-lean-pr-testing Bot added the breaks-mathlib This is not necessarily a blocker for merging: but there needs to be a plan label May 2, 2026
@tydeu tydeu added this pull request to the merge queue May 3, 2026
Merged via the queue into leanprover:master with commit dae3257 May 3, 2026
45 of 49 checks passed
@tydeu tydeu deleted the lake/await-needs branch May 3, 2026 19:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaks-mathlib This is not necessarily a blocker for merging: but there needs to be a plan changelog-lake Lake lake-ci Run all Lake tests mathlib4-nightly-available A branch for this PR exists at leanprover-community/mathlib4-nightly-testing:lean-pr-testing-NNNN 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.

Intermittent panic in lake build on Task.get

2 participants