deoplete-plugins / deoplete-lsp

LSP Completion source for deoplete

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

An error occurs during LSP completion

nabezokodaikon opened this issue · comments

Problems summary

An error occurs during LSP completion.

Expected

No error occurs during LSP completion.

Environment Information

  • deoplete: 218229c593de9ca3b526605c50da7cb7e6ffb47c

  • deoplete-lsp: 00937dd

  • nvim-lspconfig: f81570d1288fd974098e0f311f728469ca919155

  • nvim-treesitter: 84015ac3c7e3f6a05482a26b78a072f8242e62c7

  • OS: Mac

  • neovim/Vim :version output: NVIM v0.5.0-dev+nightly-915-gf76f72a27

  • :checkhealth or :CheckHealth result(neovim only): OK

Provide a minimal init.vim/vimrc with less than 50 lines (Required!)

if &compatible
    set nocompatible
endif

filetype off
filetype plugin indent off

let $CACHE = expand('~/.cache')
if !isdirectory(expand($CACHE))
    call mkdir(expand($CACHE), 'p')
endif
let s:dein_dir = expand('$CACHE/dein')
let s:dein_repo_dir = s:dein_dir . '/repos/github.com/Shougo/dein.vim'
if &runtimepath !~# '/dein.vim'
    if !isdirectory(s:dein_repo_dir)
        execute '!git clone https://github.com/Shougo/dein.vim' s:dein_repo_dir
    endif
    execute 'set runtimepath^=' . s:dein_repo_dir
endif
if !dein#load_state(s:dein_dir)
    finish
endif
call dein#begin(s:dein_dir, expand('<sfile>'))

call dein#add('Shougo/deoplete.nvim')
call dein#add('deoplete-plugins/deoplete-lsp')
call dein#add('neovim/nvim-lspconfig')
call dein#add('nvim-treesitter/nvim-treesitter')

call dein#end()
call dein#save_state()
if has('vim_starting') && dein#check_install()
    call dein#install()
endif
lua << EOF
require'lspconfig'.denols.setup{}
local treesitter = require'nvim-treesitter.configs';
treesitter.setup {
    ensure_installed = "maintained",
    highlight = {
        enable = true,
        disable = {
            "rust",
        },
    },
}
EOF
filetype plugin indent on
call deoplete#enable()

How to reproduce the problem from neovim/Vim startup (Required!)

  1. $ touch foo.ts
  2. Start NeoVim.
  3. Run 'call dein#update()' command.
  4. Run 'TSUpdate' command.
  5. Restart NeoVim.
  6. Open foo.ts file on NeoVim.
  7. Enter the code below.
  class A {
    public value: string;
    constructor() {
      this.value = "";
    }
  }

  class B {
    public a_value: A;
    constructor() {
      this.a_value = new A();
    }
  }

  class C {
    public b_value: B;
    constructor() {
      this.b_value = new B();
    }
  }

  const c = new C();
  c.b_value.a_value.value.

Screenshot (if possible)

スクリーンショット 2021-06-16 23 49 19

Upload the log file

deoplete.log

Fixed.

It is the fault of #25 changs.

Thank you for your quick response!