ray-x / lsp_signature.nvim

LSP signature hint as you type
Apache License 2.0
2.01k stars 56 forks source link

using Blob as a String #252

Open miki725 opened 1 year ago

miki725 commented 1 year ago

getting the following error from lsp signature:

Error executing vim.schedule lua callback: Vim:E976: using Blob as a String
stack traceback:
        [C]: in function 'strdisplaywidth'
        /usr/share/nvim/runtime/lua/vim/lsp/util.lua:1457: in function '_make_floating_popup_size'
        ...er/start/lsp_signature.nvim/lua/lsp_signature/helper.lua:401: in function 'cal_pos'
        ...cker/start/lsp_signature.nvim/lua/lsp_signature/init.lua:453: in function 'handler'
        /usr/share/nvim/runtime/lua/vim/lsp.lua:1383: in function ''
        vim/_editor.lua: in function <vim/_editor.lua:0>

I just recently updated all my plugins with PackerSync however not sure when I did the last upgrade so prolly something changed in the last month or so which could cause this?

here is my neovim version:

➜ nvim --version
NVIM v0.8.2
Build type: Release
LuaJIT 2.1.0-beta3
Compiled by builduser

Features: +acl +iconv +tui
See ":help feature-compile"

   system vimrc file: "$VIM/sysinit.vim"
  fall-back for $VIM: "/usr/share/nvim"

Run :checkhealth for more info
ray-x commented 1 year ago

Is it happened for all LSP you are using? or a specific LSP?

miki725 commented 1 year ago

hmm indeed does not seem to happen in typescript but happens with python pyright lsp. pyright bug somewhere? anything specific which I can report issue there if its an issue with specific LSPs?

ray-x commented 1 year ago

You can enable those:

  debug = trhe, -- set to true to enable debug logging
  log_path = vim.fn.stdpath("cache") .. "/lsp_signature.log", -- log dir when debug is on
  -- default is  ~/.cache/nvim/lsp_signature.log
  verbose = true, -- show debug line number

And attach the logs for pyright.
It might be related to a specific pyright version. Or might be related to the signature. It looks good to me.

image

miki725 commented 1 year ago

this is my version:

➜ pyright --version
pyright 1.1.287

what version are you using?

Abh15h3k commented 1 year ago

facing the same issue here. any update on this?