fidget.nvim
fidget.nvim copied to clipboard
clang12 - failed "lsp.lua:93: attempt to call field 'get_clients' (a nil value) " - seems to only work tag="legacy"
neovim v0.10 - using packer
NOTE: Just switched to lazy. Still having the same problem.
use {
'j-hui/fidget.nvim',
config = function()
require("fidget").setup({})
end
}
I'm starting clangd in the following way:
require('mason-lspconfig').setup({
handlers = {
lsp_zero.default_setup,
clangd = function()
lspconfig.clangd.setup({
cmd = { 'clangd-12', '-j=6', '--background-index', '--clang-tidy' }
})
end
}
})
I see clangd-12 running as a process. I'm not sure what I'm doing wrong. If I switch to tag=legacy things "work" though I'm not sure what I'm missing in terms of the latest and greated fidget features.
When I open a *cpp file w/ a compile_commands.json at the project root, I get the error shown in the subject. :LspInfo shows the following:
Press q or <Esc> to close this window. Press <Tab> to view server doc.
Language client log: XXXX/lsp.log
Detected filetype: cpp
1 client(s) attached to this buffer:
Client: clangd (id: 2, bufnr: [1])
filetypes: c, cpp, objc, objcpp, cuda, proto
autostart: true
root directory: XXXX
cmd: /usr/bin/clangd-12 -j=6 --background-index --clang-tidy
1 active client(s) not attached to this buffer:
Client: copilot (id: 1, bufnr: [])
filetypes:
autostart: false
root directory: Running in single file mode.
cmd: node XXXX/.local/share/nvim/site/pack/packer/start/copilot.vim/dist/agent.js --stdio
Configured servers list: cssls, rust_analyzer, bashls, jsonls, julials, pyright, texlab, dockerls, lua_ls, dotls, clangd, html, marksman, taplo, lemminx, sqlls, yamlls, tsserver
Here's a little snippet of lsp.log with verbose logging turned on:
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" "I[17:38:09.422] --> $/progress\n"
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'V[17:38:09.423] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"0/6","percentage":0}}}\n\n'
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" "I[17:38:09.423] --> $/progress\n"
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'V[17:38:09.423] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"1/6","percentage":16.666666666666668}}}\n\n'
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'I[17:38:09.424] --> $/progress\nV[17:38:09.424] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"1/6","percentage":16.666666666666668}}}\n\n'
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" "I[17:38:09.424] --> $/progress\n"
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'V[17:38:09.424] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"1/6","percentage":16.666666666666668}}}\n\n'
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" "I[17:38:09.424] --> $/progress\n"
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'V[17:38:09.424] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"1/6","percentage":16.666666666666668}}}\n\n'
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'I[17:38:09.424] --> $/progress\nV[17:38:09.424] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"1/6","percentage":16.666666666666668}}}\n\n'
[ERROR][2024-02-26 17:38:09] .../vim/lsp/rpc.lua:677 "rpc" "/usr/bin/clangd-12" "stderr" 'I[17:38:09.424] --> $/progress\nV[17:38:09.424] >>> {"jsonrpc":"2.0","method":"$/progress","params":{"token":"backgroundIndexProgress","value":{"kind":"report","message":"1/6","percentage":16.666666666666668}}}\n\n'
Just switched back to the legacy tag - and the progress spinner appears and no errors.