Closed svampkorg closed 8 months ago
I ran into this too and did some digging. If you change line 27 in lua/dressing/select/telescope.lua
from local client_id = item[1]
to local client_id = item.ctx.client_id
code actions work correctly again. Looking through neovim commits I'm assuming 9281edb is what broke it.
I ran into this too and did some digging. If you change line 27 in
lua/dressing/select/telescope.lua
fromlocal client_id = item[1]
tolocal client_id = item.ctx.client_id
code actions work correctly again. Looking through neovim commits I'm assuming 9281edb is what broke it.
LTDR: It worked! 👍
Awesome find! I struggled a bit with Lazy plugin manager, trying to use the dev parameter to point to a version of dressing I had cloned locally. It worked, partly. For whatever reason Lazy could not find the branch I had created. Probably because it wasn't pushed to remote and I didn't want to do that just yet, so I cloned dressing instead =P But I can now confirm that doing the changes you suggested works!
Should be fixed!
is it me, or its breaking on my config now after this commit ??
NVIM v0.10.0-dev-4eea609
I updated neovim to NVIM v0.10.0-dev-a935c75
now fixed it
I am on the latest neovim nightly NVIM v0.10.0-dev-1138+g71d9b7d15
.
This fix didnt seem to work for me, rather it was the problem. Removing the version check again fixed the issue for me... https://github.com/stevearc/dressing.nvim/blob/fe3071330a0720ce3695ac915820c8134b22d1b0/lua/dressing/select/telescope.lua#L28
I have NVIM v0.10.0-dev-1420+g9dc440400-Homebrew
and dressing.nvim commit 94b0d24
And running :lua print(vim.fn.has("nvim-0.10"))
evaluates to 1
but I still see this error:
Error 00:51:24 msg_show.lua_error Error executing vim.schedule lua callback: ...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:29: attempt to index field 'ctx' (a nil value)
stack traceback:
...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:29: in function <...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:8>
...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:137: in function 'select'
...are/nvim/lazy/dressing.nvim/lua/dressing/select/init.lua:70: in function 'fn'
vim/_editor.lua:342: in function <vim/_editor.lua:341>
https://github.com/stevearc/dressing.nvim/assets/551858/c6e9b151-90cd-4217-b721-4628f7fde444
Describe the bug Dressing overrides the built in vim.ui.select function and I believe using code_actions with this overridden selector got broken after these changes in nightly nvim: https://github.com/neovim/neovim/commit/9281edb334a374e7753d4a6b7a05e31120e39772
I now get this, when opening up code-actions: Error executing vim.schedule lua callback: ...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:28: attempt to index a nil value stack traceback: ...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:28: in function <...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:8> ...vim/lazy/dressing.nvim/lua/dressing/select/telescope.lua:132: in function 'select' ...are/nvim/lazy/dressing.nvim/lua/dressing/select/init.lua:70: in function 'fn' vim/_editor.lua:343: in function <vim/_editor.lua:342>
If I use Telescope extension ui-select I get this: Error executing vim.schedule lua callback: ...e-ui-select.nvim/lua/telescope/_extensions/ui-select.lua:35: attempt to index a nil value stack traceback: ...e-ui-select.nvim/lua/telescope/_extensions/ui-select.lua:35: in function <...e-ui-select.nvim/lua/telescope/_extensions/ui-select.lua:23> ...e-ui-select.nvim/lua/telescope/_extensions/ui-select.lua:96: in function 'select' ...ovim/HEAD-f1e9aa8/share/nvim/runtime/lua/vim/lsp/buf.lua:720: in function 'on_code_action_results' ...ovim/HEAD-f1e9aa8/share/nvim/runtime/lua/vim/lsp/buf.lua:789: in function 'handler' ...r/neovim/HEAD-f1e9aa8/share/nvim/runtime/lua/vim/lsp.lua:1516: in function 'fn' vim/_editor.lua:343: in function <vim/_editor.lua:342>
Not sure if to report issue here or at telescope-ui-select.. or both!
System information
vim.ui.select
backend? If so, which one? vim.ui.select, applied to code_actions from lispTo Reproduce Steps to reproduce the behavior:
If possible, provide a minimal file that will trigger the issue (see tests/manual for examples of short ways to call
vim.ui.*
):Screenshots If applicable, add screenshots to help explain your problem.
Additional context I borrowed some code from the creator of all those mini-plugins, namely the mini.pick plugin - pick.lua in his repo https://github.com/echasnovski/mini.nvim/tree/main - and used his ui_select to override vim.ui.select, and it works without this error I get with either dressing or telescope-ui-select extension. Not sure what the difference is. I'm not that fluent in Lua :)