aboutsummaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
Diffstat (limited to 'runtime')
-rw-r--r--runtime/autoload/remote/host.vim11
-rw-r--r--runtime/doc/msgpack_rpc.txt5
2 files changed, 10 insertions, 6 deletions
diff --git a/runtime/autoload/remote/host.vim b/runtime/autoload/remote/host.vim
index e81aa81665..b07593f39b 100644
--- a/runtime/autoload/remote/host.vim
+++ b/runtime/autoload/remote/host.vim
@@ -219,7 +219,9 @@ function! s:RequirePythonHost(name)
" In some distros, python3 is the default python
let python_host_prog = 'python2'
else
- throw 'No python interpreter found'
+ throw 'No python interpreter found.' .
+ \ " Try setting 'let g:python_host_prog=/path/to/python' in your '.nvimrc'" .
+ \ " or see ':help nvim-python'."
endif
" Make sure we pick correct python version on path.
@@ -231,7 +233,8 @@ function! s:RequirePythonHost(name)
let import_result = system(python_host_prog .
\ ' -c "import neovim, sys; sys.stdout.write(\"ok\")"')
if import_result != 'ok'
- throw 'No neovim module found for ' . python_version
+ throw 'No neovim module found for ' . python_version . '.' .
+ \ " Try installing it with 'pip install neovim' or see ':help nvim-python'."
endif
try
@@ -241,7 +244,9 @@ function! s:RequirePythonHost(name)
endif
catch
endtry
- throw 'Failed to load python host'
+ throw 'Failed to load python host.' .
+ \ " Try upgrading the Neovim python module with 'pip install --upgrade neovim'" .
+ \ " or see ':help nvim-python'."
endfunction
call remote#host#Register('python', function('s:RequirePythonHost'))
diff --git a/runtime/doc/msgpack_rpc.txt b/runtime/doc/msgpack_rpc.txt
index 8e53241775..0fb419e5d5 100644
--- a/runtime/doc/msgpack_rpc.txt
+++ b/runtime/doc/msgpack_rpc.txt
@@ -113,9 +113,8 @@ string 'hello world!' on the current nvim instance:
A better way is to use the python REPL with the `neovim` package, where API
functions can be called interactively:
>
- >>> from neovim import socket_session, Nvim
- >>> session = socket_session('[address]')
- >>> nvim = Nvim.from_session(session)
+ >>> from neovim import attach
+ >>> nvim = attach('socket', path='[address]')
>>> nvim.command('echo "hello world!"')
<
==============================================================================