jedi-vim: Some modules not found
Issue
Trying to use jedi-vim with a python3 conda environment, I find that some modules are found but others are not, and result in "Omni completion (^O^N^P) Pattern not found. Some modules that are not working are scipy numpy sympy pandas
Examples of modules that are working matplotlib jsonschema markupsafe
Steps to reproduce
With the following minimal vim setup:
- set nocompatible " be iMproved, required
- filetype off " required
- let g:pymode_python = ‘python3’
- let &pythonthreedll = ‘/panfs/pfs.local/software/7/install/anaconda/4.7/lib/libpython3.7m.so.1.0’
- color elflord
- syntax on
- filetype plugin on
- set nu
Running “:python3 import numpy; print(np.arange(10))” returns the expected array. " :python3 import sys; print(sys.path) " includes the path to my conda environment.
Not sure what else to try.
Output of “:verbose JediDebugInfo”
- jedi-vim git version: Unknown option: -C usage: git [–version] [–help] [-c name=value] [–exec-path[=<path>]] [–html-path] [–man-path] [–info-path] [-p|–paginate|–no-pager] [–no-replace-objects] [–bare] [–git-dir=<path>] [–work-tree=<path>] [–namespace=<name>] <command> [<args>]
- jedi git submodule status: Unknown option: -C usage: git [–version] [–help] [-c name=value] [–exec-path[=<path>]] [–html-path] [–man-path] [–info-path] [-p|–paginate|–no-pager] [–no-replace-objects] [–bare] [–git-dir=<path>] [–work-tree=<path>] [–namespace=<name>] <command> [<args>]
- parso git submodule status: Unknown option: -C usage: git [–version] [–help] [-c name=value] [–exec-path[=<path>]] [–html-path] [–man-path] [–info-path] [-p|–paginate|–no-pager] [–no-replace-objects] [–bare] [–git-dir=<path>] [–work-tree=<path>] [–namespace=<name>] <command> [<args>]
Global Python
Using Python version 3 to access Jedi.
- global sys.executable:
/home/sether35/.conda/envs/notebook/bin/python3 - global sys.version:
3.7.3 (default, Mar 27 2019, 22:15:47), [GCC 7.3.0] - global site module:
/home/sether35/.conda/envs/notebook/lib/python3.7/site.py
Jedi
- path:
/panfs/pfs.local/home/sether35/.vim/pack/plugins/start/jedi-vim/pythonx/jedi/jedi/__init__.py - version: 0.15.1
Jedi environment: <SameEnvironment: 3.7.3 in /home/sether35/.conda/envs/notebook>
- executable: /home/sether35/.conda/envs/notebook/bin/python3
- sys_path:
/panfs/pfs.local/work/laird/sether35/hoomd-blue/panfs/pfs.local/home/sether35/home/sether35/.conda/envs/notebook/lib/python37.zip/home/sether35/.conda/envs/notebook/lib/python3.7/home/sether35/.conda/envs/notebook/lib/python3.7/lib-dynload/home/sether35/.conda/envs/notebook/lib/python3.7/site-packages
Known environments
-
<Environment: 3.7.3 in /home/sether35/.conda/envs/notebook> (/home/sether35/.conda/envs/notebook/bin/python3.7)
-
<Environment: 2.7.5 in /usr> (/usr/bin/python2.7)
Settings
omnifunc=jedi#completions
Last set from ~/.vim/bundle/jedi-vim/autoload/jedi.vim line 620
completeopt=menuone,longest,preview
Last set from ~/.vim/bundle/jedi-vim/plugin/jedi.vim line 36
:version
VIM - Vi IMproved 8.1 (2018 May 18, compiled Sep 18 2019 16:07:18)
Included patches: 1-2052
Compiled by r557e636@login1
Huge version without GUI. Features included (+) or not (-):
+acl +cindent +cursorshape +file_in_path +jumplist +mksession +mouse_xterm +printer -sound +terminal +virtualedit -xim
+arabic +clientserver +dialog_con +find_in_path +keymap +modify_fname +multi_byte +profile +spell +terminfo +visual -xpm
+autocmd +clipboard +diff +float +lambda +mouse +multi_lang +python/dyn +startuptime +termresponse +visualextra +xsmp_interact
+autochdir +cmdline_compl +digraphs +folding +langmap -mouseshape -mzscheme +python3/dyn +statusline +textobjects +viminfo +xterm_clipboard
-autoservername +cmdline_hist -dnd -footer +libcall +mouse_dec +netbeans_intg +quickfix -sun_workshop +textprop +vreplace -xterm_save
-balloon_eval +cmdline_info -ebcdic +fork() +linebreak -mouse_gpm +num64 +reltime +syntax +timers +wildignore
+balloon_eval_term +comments +emacs_tags +gettext +lispindent -mouse_jsbterm +packages +rightleft +tag_binary +title +wildmenu
-browse +conceal +eval -hangul_input +listcmds +mouse_netterm +path_extra -ruby -tag_old_static -toolbar +windows
++builtin_terms +cryptv +ex_extra +iconv +localmap +mouse_sgr +perl +scrollbind -tag_any_white +user_commands +writebackup
+byte_offset +cscope +extra_search +insert_expand +lua -mouse_sysmouse +persistent_undo +signs -tcl +vartabs +X11
+channel +cursorbind -farsi +job +menu +mouse_urxvt +postscript +smartindent +termguicolors +vertsplit +xfontset
system vimrc file: "$VIM/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
user exrc file: "$HOME/.exrc"
defaults file: "$VIMRUNTIME/defaults.vim"
fall-back for $VIM: "/panfs/pfs.local/work/laird/sether35/sw/vim/share/vim"
Compilation: gcc -std=gnu99 -c -I. -Iproto -DHAVE_CONFIG_H -g -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc -std=gnu99 -Wl,--enable-new-dtags -Wl,-rpath,/usr/lib64/perl5/CORE -L/usr/local/lib -Wl,--as-needed -o vim -lSM -lICE -lXpm -lXt -lX11 -lSM -lICE -lm -ltinfo -lnsl -ldl -L/usr/lib -llua -Wl,--enable-new-dtags -Wl,-rpath,/usr/lib64/perl5/CORE -fstack-protector -L/usr/lib64/perl5/CORE -lperl -lresolv -lnsl -ldl -lm -lcrypt -lutil -lpthread -lc
:messages
Messages maintainer: Bram Moolenaar <Bram@vim.org>
"test.py" 14L, 183C
VIM - Vi IMproved 8.1 (2018 May 18, compiled Sep 18 2019 16:07:18)
1: ~/.vimrc
2: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/ftoff.vim
3: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/colors/elflord.vim
4: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/syntax.vim
5: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/synload.vim
6: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/syncolor.vim
7: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/filetype.vim
8: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/ftplugin.vim
9: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/getscriptPlugin.vim
10: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/gzip.vim
11: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/logiPat.vim
12: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/manpager.vim
13: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/matchparen.vim
14: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/netrwPlugin.vim
15: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/rrhelper.vim
16: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/spellfile.vim
17: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/tarPlugin.vim
:scriptnames
1: ~/.vimrc
2: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/ftoff.vim
3: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/colors/elflord.vim
4: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/syntax.vim
5: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/synload.vim
6: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/syncolor.vim
7: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/filetype.vim
8: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/ftplugin.vim
9: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/getscriptPlugin.vim
10: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/gzip.vim
11: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/logiPat.vim
12: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/manpager.vim
13: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/matchparen.vim
14: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/netrwPlugin.vim
15: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/rrhelper.vim
16: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/spellfile.vim
17: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/tarPlugin.vim
18: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/tohtml.vim
19: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/vimballPlugin.vim
20: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/plugin/zipPlugin.vim
21: ~/.vim/bundle/jedi-vim/plugin/jedi.vim
22: ~/.vim/bundle/nerdtree/plugin/NERD_tree.vim
23: ~/.vim/bundle/nerdtree/autoload/nerdtree.vim
24: ~/.vim/bundle/nerdtree/lib/nerdtree/path.vim
25: ~/.vim/bundle/nerdtree/lib/nerdtree/menu_controller.vim
26: ~/.vim/bundle/nerdtree/lib/nerdtree/menu_item.vim
27: ~/.vim/bundle/nerdtree/lib/nerdtree/key_map.vim
28: ~/.vim/bundle/nerdtree/lib/nerdtree/bookmark.vim
29: ~/.vim/bundle/nerdtree/lib/nerdtree/tree_file_node.vim
30: ~/.vim/bundle/nerdtree/lib/nerdtree/tree_dir_node.vim
31: ~/.vim/bundle/nerdtree/lib/nerdtree/opener.vim
32: ~/.vim/bundle/nerdtree/lib/nerdtree/creator.vim
33: ~/.vim/bundle/nerdtree/lib/nerdtree/flag_set.vim
34: ~/.vim/bundle/nerdtree/lib/nerdtree/nerdtree.vim
35: ~/.vim/bundle/nerdtree/lib/nerdtree/ui.vim
36: ~/.vim/bundle/nerdtree/lib/nerdtree/event.vim
37: ~/.vim/bundle/nerdtree/lib/nerdtree/notifier.vim
38: ~/.vim/bundle/nerdtree/autoload/nerdtree/ui_glue.vim
39: ~/.vim/bundle/nerdtree/nerdtree_plugin/exec_menuitem.vim
40: ~/.vim/bundle/nerdtree/nerdtree_plugin/fs_menu.vim
41: ~/.vim/bundle/nerdtree/nerdtree_plugin/vcs.vim
42: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/syntax/python.vim
43: ~/.vim/bundle/jedi-vim/after/syntax/python.vim
44: ~/.vim/bundle/jedi-vim/autoload/jedi.vim
45: ~/.vim/bundle/vim-flake8/ftplugin/python_flake8.vim
46: ~/.vim/bundle/jedi-vim/ftplugin/python/jedi.vim
47: /panfs/pfs.local/work/laird/sether35/sw/vim/share/vim/vim81/ftplugin/python.vim
48: ~/.vim/bundle/jedi-vim/after/ftplugin/python/jedi.vim
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 25 (5 by maintainers)
Commits related to this issue
- completions: skip docstr without preview, handle exceptions Closes https://github.com/davidhalter/jedi-vim/issues/948. — committed to blueyed/jedi-vim by blueyed 5 years ago
- completions: skip docstr without preview, handle exceptions Closes https://github.com/davidhalter/jedi-vim/issues/948. — committed to blueyed/jedi-vim by blueyed 5 years ago
- completions: skip docstr without preview, handle exceptions (#958) Closes https://github.com/davidhalter/jedi-vim/issues/948. — committed to davidhalter/jedi-vim by blueyed 5 years ago
I’m reopening this, because the Jedi bug is not yet fixed. If you want @GiBg1aN you can also open an issue in the Jedi tracker. I’m fine with discussing this here though as well.
I tried to disable docstrings on completion directly from the code, now the completion from jedi-vim works correctly. I’ll try to check the code later. Anyway, at the moment I hypothesize that libraries like numpy, pandas, etc have a help docstring which is so long to fill the buffer/cache reserved for them. Thus, the function call fails.