Skip to content

Conversation

Kripner
Copy link

@Kripner Kripner commented Feb 17, 2025

Solves the problem that invalid import statements were not reported as errors.

Before:

{"cmd": "import BlahBlahBlah"}

{"env": 0}

After:

{"cmd": "import BlahBlahBlah"}

{"messages":
 [{"severity": "error",
   "pos": {"line": 1, "column": 0},
   "endPos": null,
   "data":
   "unknown module prefix 'BlahBlahBlah'\n\nNo directory 'BlahBlahBlah' or file 'BlahBlahBlah.olean' in the search path entries:\n././.lake/packages/Cli/.lake/build/lib\n././.lake/packages/batteries/.lake/build/lib\n././.lake/packages/Qq/.lake/build/lib\n././.lake/packages/aesop/.lake/build/lib\n././.lake/packages/proofwidgets/.lake/build/lib\n././.lake/packages/importGraph/.lake/build/lib\n././.lake/packages/LeanSearchClient/.lake/build/lib\n././.lake/packages/plausible/.lake/build/lib\n././.lake/packages/mathlib/.lake/build/lib\n././.lake/build/lib\n/home/m/.elan/toolchains/leanprover--lean4---v4.15.0/lib/lean\n/home/m/.elan/toolchains/leanprover--lean4---v4.15.0/lib/lean"}],
 "env": 0}

Similarly, invalid import statements were not reported when processing a file using {"path": "..."}, which is now fixed.

@kim-em
Copy link
Contributor

kim-em commented May 1, 2025

It seems that there is much more here than in the PR description. Do you want to push again with just the code you want here?

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

Successfully merging this pull request may close these issues.

2 participants