Be sure to update YCM's submodules when updating to the latest YCM revision!

1,146 views
Skip to first unread message

Floris Van den Abeele

unread,
Jan 8, 2014, 12:00:59 PM1/8/14
to ycm-...@googlegroups.com
Hi all,

I updated the LLVM CLANG compiler from 3.3 to 3.4 (it was released last week) and YCM from 322c4ef4d4 to the latest master branch revision (e8d1a4cef). However after recompiling YCM, it refused to load YCM when starting VIM. For recompiling I followed the 'Full Installation Guide' available at http://valloric.github.io/YouCompleteMe/

This is the output when running make in the ycm_build directory:
:~/ycm_build$ make
[ 67%] Built target BoostParts
[ 75%] Built target ycm_client_support
[ 87%] Built target ycm_core
[ 87%] Built target copy_testdata
[ 89%] Built target gmock
[ 97%] Built target ycm_core_tests
[ 98%] Built target gmock_main
[ 99%] Built target gtest
[100%] Built target gtest_main

When I start vim, I get errors relating to being unable to load YCM's support libs. :messages returns the following:
Messages maintainer: Bram Moolenaar <Br...@vim.org>
Error detected while processing function youcompleteme#Enable:
line   13:
Traceback (most recent call last):
Error detected while processing function youcompleteme#Enable:
line   13:
  File "<string>", line 1, in <module>
Error detected while processing function youcompleteme#Enable:
line   13:
  File "/home/fvdabeele/.vim/bundle/YouCompleteMe/autoload/../python/ycm/base.py", line 23, in <module>
Error detected while processing function youcompleteme#Enable:
line   13:
    from ycm import user_options_store
Error detected while processing function youcompleteme#Enable:
line   13:
  File "/home/fvdabeele/.vim/bundle/YouCompleteMe/autoload/../python/ycm/user_options_store.py", line 22, in <module>
Error detected while processing function youcompleteme#Enable:
line   13:
    from frozendict import frozendict
Error detected while processing function youcompleteme#Enable:
line   13:
ImportError: No module named frozendict
Error detected while processing function youcompleteme#Enable:
line   14:
Traceback (most recent call last):
Error detected while processing function youcompleteme#Enable:
line   14:
  File "<string>", line 1, in <module>
Error detected while processing function youcompleteme#Enable:
line   14:
NameError: name 'base' is not defined
Error detected while processing function youcompleteme#Enable:
line   16:
Traceback (most recent call last):
Error detected while processing function youcompleteme#Enable:
line   16:
  File "<string>", line 1, in <module>
Error detected while processing function youcompleteme#Enable:
line   16:
  File "/home/fvdabeele/.vim/bundle/YouCompleteMe/autoload/../python/ycm/user_options_store.py", line 22, in <module>
Error detected while processing function youcompleteme#Enable:
line   16:
    from frozendict import frozendict
Error detected while processing function youcompleteme#Enable:
line   16:
ImportError: No module named frozendict
Error detected while processing function youcompleteme#Enable:
line   17:
Traceback (most recent call last):
Error detected while processing function youcompleteme#Enable:
line   17:
  File "<string>", line 1, in <module>
Error detected while processing function youcompleteme#Enable:
line   17:
NameError: name 'user_options_store' is not defined
Error detected while processing function youcompleteme#Enable:
line   19:
Traceback (most recent call last):
Error detected while processing function youcompleteme#Enable:
line   19:
  File "<string>", line 1, in <module>
Error detected while processing function youcompleteme#Enable:
line   19:
NameError: name 'base' is not defined
Error detected while processing function youcompleteme#Enable:
line   19:
E858: Eval did not return a valid python object
YouCompleteMe unavailable: YCM support libs too old, PLEASE RECOMPILE
Press ENTER or type command to continue

Note that make ycm_support_libs in ~/ycm_build doesn't solve the issue (output from the make cmd below)
make ycm_support_libs
[ 77%] Built target BoostParts
[ 86%] Built target ycm_client_support
[100%] Built target ycm_core
[100%] Built target ycm_support_libs

Now it would appear that somehow the submodules of YCM in my local GIT working copy weren't updating when I ran git submodule update, git submodule returned:
~/.vim/bundle/YouCompleteMe$ git submodule
-ee198be6f06d39cef84b0817e0b88d3e08cbc477 python/ycm/completers/cs/OmniSharpServer
-af60aefbbf43da32f75753f0c69f572ece654e9b third_party/argparse
-154369b2b9f7393ca9d3d73de7e046e2342cf00a third_party/bottle
-a9f23e0c73819ef3433538c6bd820097a5b25e9b third_party/frozendict
-e34874543ec503747a15d455cd6a1accbe12070a third_party/jedi
-9968a10fcfad7268b552808c4f8946eecafc956a third_party/requests
-79e525634e33d86cb5f3e62dcba88f98fe4f4cbc third_party/requests-futures
-c957f1d70ab82ba15ce0dce8fca7cf70fe2f2b97 third_party/waitress

I had to run git submodule init followed by an update to get the latest versions of the submodules. After updating the output looked like this:
 ~/.vim/bundle/YouCompleteMe$ git submodule
 ee198be6f06d39cef84b0817e0b88d3e08cbc477 python/ycm/completers/cs/OmniSharpServer (remotes/origin/monodoc-40-gee198be)
 af60aefbbf43da32f75753f0c69f572ece654e9b third_party/argparse (heads/master)
 154369b2b9f7393ca9d3d73de7e046e2342cf00a third_party/bottle (0.11.1-201-g154369b)
 a9f23e0c73819ef3433538c6bd820097a5b25e9b third_party/frozendict (heads/master)
 e34874543ec503747a15d455cd6a1accbe12070a third_party/jedi (v0.7.0-117-ge348745)
 9968a10fcfad7268b552808c4f8946eecafc956a third_party/requests (v0.6.4-2394-g9968a10)
 79e525634e33d86cb5f3e62dcba88f98fe4f4cbc third_party/requests-futures (79e5256)
 c957f1d70ab82ba15ce0dce8fca7cf70fe2f2b97 third_party/waitress (0.8.7)

Note that I started with a fully working YCM installation prior to updating. My guess is that the git pull origin master I ran to update YCM to the latest revision broke the submodules somehow. I put the output from the git pull on pastebin: http://pastebin.com/rKvtfk34. Probably running git submodule init/update is always a good habit when updating a GIT repo with modules?
I taught I'd share my findings here, in case anyone else stumbles upon this particular problem (and finds nothing helpful on google).

Kind regards,
Floris

Peter Liu

unread,
Jul 8, 2015, 1:23:49 PM7/8/15
to ycm-...@googlegroups.com
Thanks just got hit by this myself, and

  git submodule update

was indeed the fix.

Alfred Bez

unread,
Jul 17, 2015, 1:14:48 PM7/17/15
to ycm-...@googlegroups.com
I had the same issue and 

git submodule update

in ~/.vim/bundle/YouCompleteMe solved the issue for me, too. 
Reply all
Reply to author
Forward
0 new messages