fwcd / kotlin-language-server

Kotlin code completion, diagnostics and more for any editor/IDE using the Language Server Protocol
MIT License
1.62k stars 203 forks source link

File scheme missing when renaming funtion #478

Closed JingMatrix closed 6 months ago

JingMatrix commented 1 year ago

I use neovim with kotlin-language-server. When I try to rename a function, it causes error:

/usr/share/nvim/runtime/lua/vim/uri.lua:107: URI must contain a scheme: /home/jing/D
ocuments/Project/someKotlinFile.kt
stack traceback:
        [C]: in function 'assert'
        /usr/share/nvim/runtime/lua/vim/uri.lua:107: in function 'uri_to_fname'
        /usr/share/nvim/runtime/lua/vim/uri.lua:128: in function 'uri_to_bufnr'
        /usr/share/nvim/runtime/lua/vim/lsp/util.lua:578: in function 'apply_text_document_edit'
        /usr/share/nvim/runtime/lua/vim/lsp/util.lua:866: in function 'apply_workspace_edit'
        /usr/share/nvim/runtime/lua/vim/lsp/handlers.lua:300: in function 'handler'
        /usr/share/nvim/runtime/lua/vim/lsp/buf.lua:321: in function 'handler'
        /usr/share/nvim/runtime/lua/vim/lsp.lua:1394: in function ''
        vim/_editor.lua: in function <vim/_editor.lua:0>

Apparently, the file scheme is missing before the file location.