Repository navigation
Conversation
PR summary 3f672c49f7Import changes for modified filesNo significant changes to the import graph Import changes for all files
|
|
This pull request has conflicts, please merge |
grunweg
reviewed
Oct 19, 2026
| public import ImportGraph.Lean.Environment | ||
|
|
||
| -- An explicit ordinary import makes the representative definition rejected in | ||
| -- `ImportDevTools.lean` valid. This rules out rejection solely because the API is intrinsically meta. |
Contributor
There was a problem hiding this comment.
I don't understand the second sentence. Can you rephrase, please?
This branch has not been deployed
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.
Use meta imports for ImportGraph and LeanSearchClient, and add regression tests following #43912. After
public import Mathlib, ordinary runtime definitions using representative APIs must fail, while corresponding meta definitions succeed. An explicit ordinary ImportGraph import enables its representative runtime definition.The tests explicitly document that they check representative declarations: they do not guarantee that other declarations have not become available at runtime. LeanSearchClient already marks its representative declaration
metaupstream, so its test checks that API's phase rather than detecting ordinary imports. These tests do not prevent theorem statements about dependency types.Related to #43912; this PR is independent and targets
master.Validation:
Mathlib.Tactic.Common,Mathlib.Tactic.DuplicateDecls, andMathlib.Tactic.Linter.UpstreamableDecl.lake env lean MathlibTest/ImportDevTools.leanandlake env lean MathlibTest/ImportDevToolsExplicit.leanpassed.lake exe lint-style Mathlib Archive Counterexamples Wantedpassed.🤖 Prepared with Codex