Closed lovettchris closed 2 years ago
I think this is DocumentUri.toPath?
not supporting absolute Windows paths
Is that where ctx.fileName
is coming from? I couldn't find the source code, can you include a pointer to the code so I can try and fix it on my machine?
Note that https://github.com/leanprover/lean4/pull/1257 fixes the npm build problem, but the Rubiks cube sample still doesn't work due to this path problem, so I see this in the editor:
Is that where
ctx.fileName
is coming from? I couldn't find the source code, can you include a pointer to the code so I can try and fix it on my machine?
It's here: https://github.com/leanprover/lean4/blob/da139efa08b773045af08524cc19f7d1aea9c27a/src/Lean/Server/Utils.lean#L78-L85. As you can see, it's a quite naive implementation right now, it doesn't do real URL decoding.
This is fixed by https://github.com/leanprover/lean4/pull/1452
Prerequisites
Description
Steps to Reproduce
lake build rubiksJs
Expected behavior:
Build should succeed.
Actual behavior:
The problem appears to be that the beginning of the
ctx.fileName
is mangled like this:\d%3A\Temp\lean4-samples\RubiksCube\Rubiks.lean
It should be as follows instead:
d:\Temp\lean4-samples\RubiksCube\Rubiks.lean
This could be related to https://github.com/leanprover/lean4/pull/1257
Reproduces how often: 100%
Versions
Lean (version 4.0.0-nightly-2022-08-01, commit c76fa0681651, Release)
Additional Information
Any additional information, configuration or data that might be necessary to reproduce the issue.