I found that for the package torchvision, auto-completion of method or class does not work for the modules inside this package.
But if I use jedi-vim for auto-completion, the auto-completion menu shows upon pressing ..
Expected
Auto-completion works for this package just like jedi-vim since they use the same underlying package Jedi.
Environment Information
OS: CentOS 7.4
Neovim version: NVIM v0.4.0-517-g8eaa45207
Provide a minimal init.vim with less than 50 lines (required)
" Use the following as a template.
set runtimepath+=/home/haojiedong/.local/share/nvim/plugged/deoplete.nvim/
set runtimepath+=/home/haojiedong/.local/share/nvim/plugged/deoplete-jedi/
let g:deoplete#enable_at_startup = 1
call deoplete#custom#source('jedi', 'is_debug_enabled', 1)
call deoplete#enable_logging('DEBUG', '/tmp/deoplete.log')
Generate logfiles if appropriate
export NVIM_PYTHON_LOG_FILE=/tmp/nvim-log
export NVIM_PYTHON_LOG_LEVEL=DEBUG
nvim -u minimal.vimrc
Then look at and attach the files /tmp/nvim-log_{PID} and
/tmp/deoplete.log here.
Steps to reproduce the issue after starting Neovim (required)
open a Python source file test.py, with the following content
from torchvision import models, datasets, transforms
start a new line and type models. or datasets. or transforms.
the auto-completion menu is not shown
But if I use the following minimal config instead
set runtimepath+=/home/haojiedong/.local/share/nvim/plugged/jedi-vim
let g:jedi#completions_enabled = 1
I can use auto-completion for the same test.py when I type models. or datasets. or transforms..
Note that deoplete-jedi does work for other packages such os. For example, for
from os import path
if I type path., the deoplete autocompletion menu will show up.
I do not know if this problem is caused by this specific package or due to deoplete-jedi. But since jedi-vim can show the auto-complete correctly and both jedi-vim and deoplete-jedi use the same underlying Jedi package, I think there may be something not working properly with deoplete-jedi.
Problem summary
I found that for the package torchvision, auto-completion of method or class does not work for the modules inside this package.
But if I use jedi-vim for auto-completion, the auto-completion menu shows upon pressing
.
.Expected
Auto-completion works for this package just like jedi-vim since they use the same underlying package Jedi.
Environment Information
Provide a minimal init.vim with less than 50 lines (required)
Generate logfiles if appropriate
Then look at and attach the files
/tmp/nvim-log_{PID}
and/tmp/deoplete.log
here.deoplete.log
Steps to reproduce the issue after starting Neovim (required)
open a Python source file
test.py
, with the following contentstart a new line and type
models.
ordatasets.
ortransforms.
the auto-completion menu is not shown
But if I use the following minimal config instead
I can use auto-completion for the same
test.py
when I typemodels.
ordatasets.
ortransforms.
.Note that deoplete-jedi does work for other packages such
os
. For example, forif I type
path.
, the deoplete autocompletion menu will show up.I do not know if this problem is caused by this specific package or due to deoplete-jedi. But since jedi-vim can show the auto-complete correctly and both jedi-vim and deoplete-jedi use the same underlying Jedi package, I think there may be something not working properly with deoplete-jedi.
Screen shot (if possible)
The completeion menu using jedi-vim