Whenever :CocFzfList symbols is run, the following error issues:
Error detected while processing function <SNR>153_echo_cb:
line 2:
E15: Invalid expression: ~/.pyenv/versions/neovim/bin/python' is not executable.' | echohl None
This is the command issued in s:echo_core. I'm not well-versed in vimscript, so it isn't clear to me why the expression is invalid. However, the root cause is more obvious. For reference,
let python3 = get(g:, 'python3_host_prog', 'python3')
if !executable(python3)
call coc_fzf#common#echom_error(string(python3) . ' is not executable.')
g:python3_host_prog resolves to ~/.pyenv/versions/neovim/bin/python on my machine. executable apparently doesn't understand the tilde, so executable(python3) results in 0. Technically this is executable's fault, not coc-fzf's, but a possible patch would be to add something like the following:
if has('unix')
let python3 = substitute(python3, '\~', $HOME, "")
endif
if !executable(python3) ...
That may be a bad solution for a variety of reasons that aren't apparent to me, but I'll submit a PR for review.
Environment
echo $FZF_DEFAULT_OPTS
: (Not set)bat --version
: 0.12.1(n)vim --version
: NVIM v0.7.2Describe the Bug
Whenever
:CocFzfList symbols
is run, the following error issues:This is the command issued in
s:echo_core
. I'm not well-versed in vimscript, so it isn't clear to me why the expression is invalid. However, the root cause is more obvious. For reference,g:python3_host_prog
resolves to~/.pyenv/versions/neovim/bin/python
on my machine.executable
apparently doesn't understand the tilde, soexecutable(python3)
results in0
. Technically this isexecutable
's fault, notcoc-fzf
's, but a possible patch would be to add something like the following:That may be a bad solution for a variety of reasons that aren't apparent to me, but I'll submit a PR for review.
To Reproduce
Minimal vimrc
Steps to Reproduce
:e myfile.py
<space>s
Expected Behavior
python3
is found to be executable and the symbols list is displayed.