You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Output of :echo &pythonthreedll(only vim, not neovim):
Output of :py print(sys.version):
Output of :py3 print(sys.version):
3.6.9 (default, Mar 15 2022, 13:55:28)
[GCC 8.4.0]
Output of :echo g:Lf_Debug_Cmd:
Output of :echo g:Lf_FilesFromCache:
Operating system:
Linux
Mac OS X
Windows
Etc.
Configurations related to LeaderF in vimrc:
Describe your question, feature request, or bug.
After installing the c extension with :LeaderfInstallCExtension, and launching vim with any Leaderf command,
there is still output 0 for echo g:Lf_fuzzyEngine_C.
I have dive into the Leaderf source code, and found the code in autoload/leaderf/python/leaderf/manager.py
raise a ImportError: undefined symbol: Py_InitModule4_64.
Cause the compilation python version used in install.sh is my work environment, which exactly is 3.7.7.
The actually python version Leaderf depends on is the VIM's version, aka 3.6.
Steps to reproduce
Execute the install.sh to compile fuzzyEngine and fuzzyMatchC library with python 3.7.7, and import the
library .so (which is the fuzzyEngine.cpython-37m-x86_64-linux-gnu.so and fuzzyMatchC.cpython-37m-x86_64-linux-gnu.so in my machine) with VIM's python version (which is python 3.6 in my env).
Actual behaviour
Raise a ImportError: undefined symbol: Py_InitModule4_64.
Expected behaviour
I suggest that the install.sh may be written in a more robust way, to avoid the possible conflict between python versions.
In my scene, I recompile the fuzzy library with the full python binary (3.6) path manually, and then it works.
The text was updated successfully, but these errors were encountered:
vim --version
ornvim --version
:VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Oct 24 2020 16:26:37)
Included patches: 1-1897
Modified by [email protected]
Compiled by [email protected]
Huge version without GUI. Features included (+) or not (-):
+acl -farsi +mouse_sgr +tag_binary
+arabic +file_in_path -mouse_sysmouse -tag_old_static
+autocmd +find_in_path +mouse_urxvt -tag_any_white
+autochdir +float +mouse_xterm -tcl
-autoservername +folding +multi_byte +termguicolors
-balloon_eval -footer +multi_lang +terminal
+balloon_eval_term +fork() -mzscheme +terminfo
-browse +gettext +netbeans_intg +termresponse
++builtin_terms -hangul_input +num64 +textobjects
+byte_offset +iconv +packages +textprop
+channel +insert_expand +path_extra +timers
+cindent +ipv6 -perl +title
-clientserver +job +persistent_undo -toolbar
-clipboard +jumplist +popupwin +user_commands
+cmdline_compl +keymap +postscript +vartabs
+cmdline_hist +lambda +printer +vertsplit
+cmdline_info +langmap +profile +virtualedit
+comments +libcall -python +visual
+conceal +linebreak +python3 +visualextra
+cryptv +lispindent +quickfix +viminfo
+cscope +listcmds +reltime +vreplace
+cursorbind +localmap +rightleft +wildignore
+cursorshape -lua -ruby +wildmenu
+dialog_con +menu +scrollbind +windows
+diff +mksession +signs +writebackup
+digraphs +modify_fname +smartindent -X11
-dnd +mouse +sound -xfontset
-ebcdic -mouseshape +spell -xim
+emacs_tags +mouse_dec +startuptime -xpm
+eval +mouse_gpm +statusline -xsmp
+ex_extra -mouse_jsbterm -sun_workshop -xterm_clipboard
+extra_search +mouse_netterm +syntax -xterm_save
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: "/usr/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -Wdate-time -g -O2 -fdebug-prefix-map=/build/vim-KZNIhZ/vim-8.2.1897=. -fstack-protector-strong -Wformat -Werror=format-security -D_REENTRANT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc -Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,now -Wl,--as-needed -o vim -lm -ltinfo -lselinux -lcanberra -lacl -lattr -lgpm -ldl -L/usr/lib/python3.6/config-3.6m-x86_64-linux-gnu -lpython3.6m -lpthread -ldl -lutil -lm
:echo has("python")
: 0:echo has("python3")
: 1:echo &pythondll
(only vim, not neovim)::echo &pythonthreedll
(only vim, not neovim)::py print(sys.version)
::py3 print(sys.version)
:3.6.9 (default, Mar 15 2022, 13:55:28)
[GCC 8.4.0]
:echo g:Lf_Debug_Cmd
::echo g:Lf_FilesFromCache
:Describe your question, feature request, or bug.
After installing the c extension with
:LeaderfInstallCExtension
, and launching vim with anyLeaderf
command,there is still output
0
forecho g:Lf_fuzzyEngine_C
.I have dive into the
Leaderf
source code, and found the code inautoload/leaderf/python/leaderf/manager.py
raise a
ImportError: undefined symbol: Py_InitModule4_64
.Cause the compilation python version used in
install.sh
is my work environment, which exactly is3.7.7
.The actually python version
Leaderf
depends on is theVIM
's version, aka3.6
.Steps to reproduce
Execute the
install.sh
to compile fuzzyEngine and fuzzyMatchC library withpython 3.7.7
, and import thelibrary
.so
(which is thefuzzyEngine.cpython-37m-x86_64-linux-gnu.so
andfuzzyMatchC.cpython-37m-x86_64-linux-gnu.so
in my machine) withVIM
's python version (which ispython 3.6
in my env).Actual behaviour
Raise a
ImportError: undefined symbol: Py_InitModule4_64
.Expected behaviour
I suggest that the
install.sh
may be written in a more robust way, to avoid the possible conflict between python versions.In my scene, I recompile the
fuzzy
library with the full python binary (3.6) path manually, and then it works.The text was updated successfully, but these errors were encountered: