Julian / Julian/lean.nvim

Feature request: Jump to corresponding file and line in trouble.nvim diagnostics

Open
#359 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Lua
Stars
581
Forks
60
Avg merge
4d 12h
Merged PRs (30d)
2

Description

When using lean.nvim with [trouble.nvim](https://github.com/folke/trouble.nvim) (similar to VSCode Problems panel), it would be nice if clicking on a Lean error message could go to the corresponding file and line, currently clicking on something like

```
error: ././././LibraryName/FileName.lean:112:4: error message
```

in the diagnostic output has no effect.

Context:

[Zulip](https://leanprover.zulipchat.com/#narrow/channel/113488-general/topic/lean.2Envim/near/479123024)

More information:

To reproduce, assuming you have 2 files, A.lean and B.lean, and B imports A. Now introduce an error in A, e.g. a typo of a type. If we open A.lean with lean.nvim, trouble will have a diagnostic message that can successfully jump to the error line, e.g.

image

But if we open file B, as the error comes from A, B will have a long error at where A is imported, but no way to jump to the acual error line in A:

image

(some long warning omitted in between)

image

It can only jump to the import of A, which is difficult to dive in for the cause of the error in A.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.