How to fix the liblang 3.7 error in YouCompleteMe for Vim if you just updated clang and llvm to 3.8


If you’ve just updated your llvm and clang to version 3.8 you might encounter the following error in YouCompleteMe for Vim:

ImportError: libclang.so.3.7: cannot open shared object file: No such file or directory
Hint: Check for this error by running: :YCMToggleLogs stderr

The simplest fix for me was to just recompile YCM, for me as I installed it with bundle, it was as simple as:

cd ~/.vim/bundle/YouCompleteMe ./install.py

Then just restart Vim and voilà!