Does jedi-vim conflict with YouCompleteMe?
Asked Answered
E

1

18

YouCompleteMe (YCM) and jedi-vim are two vim plugins that provide autocompletion, and both use jedi underneath for Python. However it's nice to have both since jedi-vim provides some useful features in addition to documentation, like 'go to definition' and 'view docstring', while YouCompleteMe works with other languages.

Since both provide Python autocomplete, is any special configuration needed to prevent the two plugins from conflicting? Or will jedi-vim's autocompleter simply override YCM in Python?

Esmond answered 29/4, 2015 at 17:38 Comment(3)
No practical expirience with both addons at the same time, but jedi-vim can be configured to not do anything automatically, but only on keypress. If the mappings of both addons do not collide, there should be no problem.Metrics
Jedi author here, they probably collide a bit. But if you disable certain things (like autocompletion) it could work. So @Metrics is right!Tko
YCM also provides functionality like GoToDefinition, GoToDoc and more, so you may consider removing jedi-vim completely.Bitternut
E
15

The most obvious conflict is not knowing whether you are using YCM or Jedi for autocompletion. In that case the simplest thing to do is to disable Jedi's autocompletion with a line in .vimrc, and use YCM's awesome (Jedi-powered for Python) autocomplete everywhere.

let g:jedi#completions_enabled = 0

The key mappings are not too bad. Both plugins map <leader>d (where <leader> defaults to \) but it doesn't matter, Jedi will override \d in Python files only and that particular YCM feature is not supported in Python.

Esmond answered 29/4, 2015 at 20:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.