Closed armed closed 1 month ago
Thanks, can you post the full log?
Hey, @jmgomez. Sorry for late reply. So that log above is from neovim's lsp.log, nimlangserver also creates nimlangserver.log file in project directory. Here it is:
DBG CPU Time benchmark="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0" time=0.258 command="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0"
DBG Found diagnostics file={}
DBG Stopping nimsuggest for root=/Users/armed/Dev/my-app/src/libsdk.nim
DBG Stopped nimsuggest res=ok()
DBG ShowMessage message="Nimsuggest initialized for /Users/armed/Dev/my-app/src/libsdk.nim"
DBG Running diagnostics uri=file:///Users/armed/Dev/my-app/src/libsdk.nim
DBG processQueue size=1
DBG Started... benchmark="chk \"/Users/armed/Dev/my-app/src/libsdk.nim\":0:0" command="chk \"/Users/armed/Dev/my-app/src/libsdk.nim\":0:0"
DBG timeoutCallback is set timeout=120000 command="chk \"/Users/armed/Dev/my-app/src/libsdk.nim\":0:0"
ERR NimSuggest Error (stderr) err=
DBG NimSuggest needed to be restarted due to an error
WRN Server stopped. projectFile=/Users/armed/Dev/my-app/src/libsdk.nim
DBG ShowMessage message="Using Nim Compiler Version 2.2.0 [MacOSX: arm64]"
INF Starting nimsuggest root=/Users/armed/Dev/my-app/src/libsdk.nim timeout=120000 path=/Users/armed/.local/share/mise/installs/nim/2.2.0/bin/nimsuggest workingDir=/Users/armed/Dev/my-app
DBG Parsing nimsuggest capability capability=con
DBG Parsing nimsuggest capability capability=exceptionInlayHints
DBG Parsing nimsuggest capability capability=unknownFile
DBG Nimsuggest Capabilities capabilities="{con, exceptionInlayHints, unknownFile}"
DBG Sending result(s) length=249 command="chk \"/Users/armed/Dev/my-app/src/libsdk.nim\":0:0"
DBG CPU Time benchmark="chk \"/Users/armed/Dev/my-app/src/libsdk.nim\":0:0" time=0.256 command="chk \"/Users/armed/Dev/my-app/src/libsdk.nim\":0:0"
DBG Found diagnostics file={}
DBG Stopping nimsuggest for root=/Users/armed/Dev/my-app/src/libsdk.nim
DBG Stopped nimsuggest res=ok()
DBG ShowMessage message="Nimsuggest initialized for /Users/armed/Dev/my-app/src/libsdk.nim"
DBG Running diagnostics uri=file:///Users/armed/Dev/my-app/src/cli/mockscanner.nim
DBG processQueue size=1
DBG Started... benchmark="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0" command="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0"
DBG timeoutCallback is set timeout=120000 command="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0"
ERR NimSuggest Error (stderr) err=
DBG NimSuggest needed to be restarted due to an error
WRN Server stopped. projectFile=/Users/armed/Dev/my-app/src/libsdk.nim
DBG ShowMessage message="Using Nim Compiler Version 2.2.0 [MacOSX: arm64]"
INF Starting nimsuggest root=/Users/armed/Dev/my-app/src/libsdk.nim timeout=120000 path=/Users/armed/.local/share/mise/installs/nim/2.2.0/bin/nimsuggest workingDir=/Users/armed/Dev/my-app
DBG Parsing nimsuggest capability capability=con
DBG Parsing nimsuggest capability capability=exceptionInlayHints
DBG Parsing nimsuggest capability capability=unknownFile
DBG Nimsuggest Capabilities capabilities="{con, exceptionInlayHints, unknownFile}"
DBG Sending result(s) length=249 command="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0"
DBG CPU Time benchmark="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0" time=0.259 command="chk \"/Users/armed/Dev/my-app/src/cli/mockscanner.nim\":0:0"
DBG Found diagnostics file={}
Langserver got into infinite nimguggest restart state. It was restarting nimsuiggest until I kill nimlangserver process tree completely and then trigger editor to start it again.
also my editor adds following config upon starting LSP
{
nim_langserver = {
settings = {
single_file_support = false,
nim = {
projectMapping = {
{
projectFile = "./src/libsdk.nim",
fileRegex = ".*\\.nim",
},
{
projectFile = "./src/cli.nim",
fileRegex = ".*\\.nim",
},
},
},
},
},
}
UPDATE:
nimlangserver
is built from master 5ccf289
nimsuggest
is from nim 2.2.0 distributionsame error
This is a nimsuggest
crash. You need to report it in the nim
repro. If you open the the project with the vscode
extension you will likely see the last cmd that made the code crash. Its probably chk \"/Users/armed/Dev/my-app/src/libsdk.nim\
.
Alternatively, you can just use directly nimsuggest
in the cmd line to reproduce it (https://nim-lang.org/docs/nimsuggest.html).
Nim version: 2.0.8 Langserver version: compiled from HEAD
ed6cc74
OS: macos, arm64Getting this error:
Have no idea how to debug, any advice?