onsails / lspkind.nvim

vscode-like pictograms for neovim lsp completion items
MIT License
1.47k stars 36 forks source link

deprecated error in lspkind #39

Closed desdic closed 2 years ago

desdic commented 2 years ago

neovim 0.6

Error detected while processing /home/kgn/src/private/neovim/init.lua: E5113: Error while calling lua chunk: ...site/pack/packer/start/lspkind-nvim/lua/lspkind/init.lua:123: Vim(echoerr):DEPRECATED replaced by mode option. stack traceback: [C]: in function 'nvim_command' ...site/pack/packer/start/lspkind-nvim/lua/lspkind/init.lua:123: in function 'init' ...site/pack/packer/start/lspkind-nvim/lua/lspkind/init.lua:163: in function 'cmp_format' /home/kgn/.config/nvim/lua/config/cmp.lua:47: in main chunk [C]: in function 'require' /home/kgn/.config/nvim/init.lua:7: in main chunk

just updated

WIttyJudge commented 2 years ago

After updates.

Error detected while processing /home/wittyjudge/dotfiles/.config/nvim/init.lua: E5113: Error while calling lua chunk: ...site/pack/packer/start/lspkind-nvim/lua/lspkind/init.lua:122: attempt to index local 'opts' (a nil value) stack traceback: ...site/pack/packer/start/lspkind-nvim/lua/lspkind/init.lua:122: in function 'init' ...tyjudge/.config/nvim/lua/plugins-config/lspkind-nvim.lua:36: in main chunk [C]: in function 'require' /home/wittyjudge/.config/nvim/lua/plugins-config/init.lua:53: in main chunk [C]: in function 'require' /home/wittyjudge/.config/nvim/init.lua:39: in main chunk Press ENTER or type command to continue

zeitchef commented 2 years ago

For the moment, replacing the option with_text with mode in your config (see README) will take care of the error. Would have been nice to have a bit more notice on the deprecation, but it is what it is.

rlopzc commented 2 years ago

I fixed by adding mode in lspkind.init({ mode = "symbol_text" })

demizer commented 2 years ago

Causing the following error at startup:

Error detected while processing /data/dotfiles/nvim/plugin/nvim-cmp.lua:                                                                                                                            
E5113: Error while calling lua chunk: ...m/site/pack/paqs/start/lspkind-nvim/lua/lspkind/init.lua:122: attempt to index local 'opts' (a nil value)                                                  
stack traceback:                                                                                                                                                                                    
        ...m/site/pack/paqs/start/lspkind-nvim/lua/lspkind/init.lua:122: in function 'init'                                                                                                         
        /home/jesusa/.config/nvim/plugin/nvim-cmp.lua:5: in main chunk                                                                                                                              
onsails commented 2 years ago

Should be fixed by #40, thanks for spotting this.