ncm2: It seems like that ncm2 doesn't have a satisfactory cooperation with autozimu/LanguageClient-neovim for java.
If you’re having trouble with NCM2, Please provide the following information along with your detailed issue description:
OS
arch linux (If you’re using Linux, sharing a reproducible, vimrc minimized docker image, can definitely help solving the issue)
neovim :version
output
v0.3.2-1016-gc16529afa
Minimal vimrc for reproducing the issue
Plug 'ncm2/ncm2'
Plug 'roxma/nvim-yarp'
Plug 'ncm2/ncm2-bufword'
Plug 'ncm2/ncm2-tmux'
Plug 'ncm2/ncm2-path'
Plug 'fgrsnau/ncm2-otherbuf',
Plug 'ncm2/ncm2-ultisnips'
inoremap <silent> <expr> <CR> ncm2_ultisnips#expand_or("\<CR>", 'n')
let $NVIM_PYTHON_LOG_FILE="/tmp/nvim_log"
let $NVIM_PYTHON_LOG_LEVEL="DEBUG"
let g:python_host_skip_check=1
let g:python_host_prog = '/usr/bin/python2'
let g:python3_host_skip_check=1
let g:python3_host_prog = '/usr/bin/python3'
let g:ncm2#auto_popup=1
set completeopt=noselect,menuone,noinsert
autocmd InsertEnter * call ncm2#enable_for_buffer()
" au TextChangedI * call ncm2#auto_trigger()
function! Multiple_cursors_before()
call ncm2#lock('vim-multiple-cursors')
endfunction
function! Multiple_cursors_after()
call ncm2#unlock('vim-multiple-cursors')
endfunction
Plug 'autozimu/LanguageClient-neovim', {
\ 'branch': 'next',
\ 'do': 'bash install.sh',
\ 'frozen': 1,
\ }
let g:LanguageClient_serverCommands = {
\ 'java': ['jdtls'],
\ }
let g:LanguageClient_autoStart = 1
let g:LanguageClient_loadSettings = 1
set completefunc=LanguageClient#complete
set formatexpr=LanguageClient#textDocument_rangeFormatting_sync()
let g:LanguageClient_completionPreferTextEdit=1
let g:LanguageClient_hasSnippetSupport =0
let g:LanguageClient_diagnosticsEnable=0
neovim :messages
output when the error occurs
/home/cogig/.vim/plugged/ncm2-ultisnips/autoload/ncm2_ultisnips.vim|42| ncm2_ultisnips#_do_expand_completed[16]
|| provider#python3#Call[18]
|| Traceback (most recent call last):
|| File "<string>", line 1, in <module>
|| File "/home/cogig/.vim/plugged/ncm2-ultisnips/pythonx/ncm2_lsp_snippet/utils.py", line 10, in apply_additional_text_edits
|| apply_lsp_additional_text_edits(ud, lspitem)
|| File "/home/cogig/.vim/plugged/ncm2-ultisnips/pythonx/ncm2_lsp_snippet/utils.py", line 33, in apply_lsp_additional_text_edits
|| additional_text_edits = resolved.get('additionalTextEdits', None)
|| Error detected while processing function
/home/cogig/.vim/plugged/ncm2-ultisnips/autoload/ncm2_ultisnips.vim|42| ncm2_ultisnips#_do_expand_completed[16]
|| provider#python3#Call[18]
|| AttributeError: 'NoneType' object has no attribute 'get'
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 24 (11 by maintainers)
Links to this issue
Commits related to this issue
- fix ncm2/ncm2#114, ignore empty resolved result — committed to ncm2/ncm2-ultisnips by roxma 6 years ago
@cogig The problem you encountered may look like this according to your description. https://asciinema.org/a/vp3iS0hvgqnplxNSTQHLtRkh4 We may come up against the same problem.But I’m not sure if the bug is belong to ncm2.Because ncm2 works well with pyls and other language servers.