deoplete-plugins / deoplete-clang

deoplete.nvim source for C/C++/Obj-C/Obj-C++ with clang-python3
MIT License
189 stars 73 forks source link

Errors: No module named deoplete.logger #22

Closed Toqozz closed 8 years ago

Toqozz commented 8 years ago

Problems summary

Upon trying to type I get errors from deoplete: ImportError: No module named 'deoplete.logger'

Environment Information

" Your minimal init.vim
" Tiny init.vim for deoplete-clang
set runtimepath+=$HOME/.config/nvim/plugged/deoplete.nvim
set runtimepath+=$HOME/.config/nvim/plugged/deoplete-clang

let g:deoplete#enable_at_startup = 1
let g:deoplete#enable_smart_case = 1
let g:deoplete#file#enable_buffer_path = 1

let g:deoplete#sources#clang#libclang_path = "~/code/build/clang-llvm/lib/libclang.so"
let g:deoplete#sources#clang#clang_header = '~/code/build/clang-llvm/lib/clang'
" i have also tried using system clang!
" let g:deoplete#sources#clang#sort_algo = 'priority' " alphabetical

filetype plugin indent on
syntax on

The reproduce ways from neovim starting (Required!)

  1. Launch Neovim.
  2. Enter insert mode.
  3. Type.

    Generate a logfile if appropriate

http://ix.io/vzc

Errors from deoplete:

http://ix.io/vzd

Thanks for all your help.

zchee commented 8 years ago

@Toqozz Hi :) Maybe, you does not use latest deoplete. Could you check it? FYI, https://github.com/Shougo/deoplete.nvim/commit/7ce47a109c802ebd0030540e5ef4cc0e1fa7b1df

Toqozz commented 8 years ago

It's up-to-date in the plugin manager, I will get the latest version from github in the morning!

By the way, awesome work on the readme; really great.

zchee commented 8 years ago

@Toqozz Oh, still occured error?

Toqozz commented 8 years ago

Yes, perhaps something is going wrong with vim-plug.

zchee commented 8 years ago

@Toqozz Hm, okay. I'll debug. wait a little.

Toqozz commented 8 years ago

I sleep now, I promise to take a look in the morning.

Thanks a lot man.

zchee commented 8 years ago

@Toqozz Hmm.... I don't yet know why to occur error. Just in case, could you check the exists this file?

/home/toqoz/.config/nvim/plugged/deoplete.nvim/rplugin/python3/deoplete/logger.py

or please post this result.

ls -la /home/toqoz/.config/nvim/plugged/deoplete.nvim/rplugin/python3/deoplete

By the way, awesome work on the readme; really great.

Thanks! :)

Toqozz commented 8 years ago
$ ls -la /home/toqoz/.config/nvim/plugged/deoplete.nvim/rplugin/python3/deoplete/
total 56
drwxr-xr-x 6 toqoz users  4096 Apr  5 22:18 .
drwxr-xr-x 3 toqoz users  4096 Apr  5 21:33 ..
-rw-r--r-- 1 toqoz users 12766 Apr  5 21:33 deoplete.py
drwxr-xr-x 2 toqoz users  4096 Apr  5 21:33 filters
-rw-r--r-- 1 toqoz users  1280 Apr  5 21:33 __init__.py
-rw-r--r-- 1 toqoz users  4903 Apr  5 21:33 logger.py
drwxr-xr-x 2 toqoz users  4096 Apr  5 22:18 __pycache__
drwxr-xr-x 3 toqoz users  4096 Apr  5 21:36 sources
drwxr-xr-x 2 toqoz users  4096 Apr  5 21:33 tests
-rw-r--r-- 1 toqoz users  3758 Apr  5 21:33 util.py
Toqozz commented 8 years ago

Perhaps I should take this issue over to deoplete.nvim?

zchee commented 8 years ago

@Toqozz Hmm.... strange :(

I'm deoplete.nvim collaborator. If you re-post to deoplete.nvim, I will comment on it lol

BTW, neovim/python-client also use latest?

Toqozz commented 8 years ago

I'm using the python-neovim one from arch repositories:

community/python-neovim 0.1.5-1 [installed]
zchee commented 8 years ago

@Toqozz Oh, now python-client latest version is 0.1.7. https://github.com/neovim/python-client/releases Could you try it?

git clone https://github.com/neovim/python-client.git
cd python-client
pip3 install -U .
Toqozz commented 8 years ago
 $ [~/g/python-client] ————— sudo pip3 install -U .
[sudo] password for toqoz: 
Processing /home/toqoz/git/python-client
Requirement already up-to-date: msgpack-python>=0.4.0 in /usr/lib/python3.5/site-packages (from neovim==0.1.7)
Requirement already up-to-date: greenlet in /usr/lib/python3.5/site-packages (from neovim==0.1.7)
Installing collected packages: neovim
  Found existing installation: neovim 0.1.5
    Uninstalling neovim-0.1.5:
      Successfully uninstalled neovim-0.1.5
  Running setup.py install for neovim ... done
Successfully installed neovim-0.1.7

Exact same error.

zchee commented 8 years ago

@Toqozz Hmm...

The last method, clean install deoplete.nvim and deoplete-clang.

cd /path/to/tmp
git clone https://github.com/Shougo/deoplete.nvim
git clone --recursive https://github.com/zchee/deoplete-clang
" Change /path/to/tmp dir
set runtimepath+=/path/to/tmp/deoplete.nvim
set runtimepath+=/path/to/tmp/deoplete-clang

let g:deoplete#enable_at_startup = 1
let g:deoplete#enable_smart_case = 1
let g:deoplete#file#enable_buffer_path = 1

let g:deoplete#sources#clang#libclang_path = "~/code/build/clang-llvm/lib/libclang.so"
let g:deoplete#sources#clang#clang_header = '~/code/build/clang-llvm/lib/clang'
" i have also tried using system clang!
" let g:deoplete#sources#clang#sort_algo = 'priority' " alphabetical

filetype plugin indent on
syntax on

and, I use NVIM v0.1.3-398-gba1487d(latest). I will test use NVIM v0.1.2 stable.

If you still occur error, Please me your environment as much as possible. I will reproduce using the Docker the same environment as you.

Also, Please give some time to think about it :(

Shougo commented 8 years ago

I think your deoplete is too old.

Toqozz commented 8 years ago

OK, I successfully got it working on my macbook.

I then compared the nvim directories to find that I somehow had multiple installs of deoplete everywhere... I have no idea how or why... maybe from changing the runtime directories.

After removing the different deoplete-related directories, I no longer get the logging error. Sorry for the brain ache.

Now I have an issue that I fear is even dumber..

I get "OSError: /home/toqoz/code/build/clang-llvm/lib/libclang.so cannot open shared object file: No such file or directory."

The file is most definitely there: http://imgur.com/7laGrpg

Could it be an ssh issue?

zchee commented 8 years ago

@Toqozz yeah :tada:

ok, I will comments for new issue :)

Toqozz commented 8 years ago

Working! :tada:

I rebuilt llvm from scratch to fix the other issue.

Thank you so much for your time, patience and help! 😄

zchee commented 8 years ago

@Toqozz I'm relieved to hear that :)

Enjoy asynchronous completion!!