Options:
- Global option: g:jedi#case_insensitive_completion
- Buffer-local option: b:jedi_case_insensitive_completion
Values:
- 0 to disable case insensitive completion.
- 1 to enable case insensitive completion (default).
This commit removes the inner string quotation of the default value for the
added_sys_path setting. The inner quotes cause the value of the resulting
variable g:jedi#added_sys_path to be the sting "[]" instead of an empty list.
Without this it would not go there with an already open qf window, and
would go to an unexpected buffer line instead of selecting the entry.
This is a follow-up to b689409, where it was decided that it should
always require the user to select an entry.
An exception is when the same usages are used again: then it will select
the nearest/current entry only (via ":cc").
It basically allows to give a warning when '1' is used / set explicitly, and
the 'conceal' feature is not available.
Also defaulting to '2' (cmdline mode) then seems better than not using
it.
This is just some minor clean up before
https://github.com/davidhalter/jedi-vim/pull/652.
When being initialized via ftplugin `set shortmess+=F` (default in
Neovim by now) causes the additional information (the full traceback) to
be silenced.
This patch uses `:unsilent` to always display it.
Ref: https://github.com/neovim/neovim/issues/8675
* jedi_vim.jedi_import_error: add location
This is useful for debugging. It contains e.g. the path to parso, if
importing failed from there.
Example:
> Error: jedi-vim failed to initialize Python: jedi#setup_python_imports: could not import jedi: cannot import name 'PythonTokenTypes' (in /…/jedi-vim/pythonx/jedi/jedi/api/completion.py:1). (in function jedi#init_python[3]..<SNR>44_init_python[27]..jedi#setup_python_imports, line 37)
* init: handle jedi_vim.jedi_import_error in Vim plugin
Using `set shortmess+=F` would suppress the `:echom` used in
`jedi_vim.no_jedi_warning` [1].
This patch makes `jedi#setup_python_imports` handle the error instead.
1: https://github.com/neovim/neovim/issues/8675
* Revisit error handling with loading jedi_vim
* jedi#debug_info: display parso submodule separately
* Fix jedi#reinit_python
* fixup! Revisit error handling with loading jedi_vim
* display_debug_info: handle exceptions with environment.get_sys_path
* fixup! Revisit error handling with loading jedi_vim
[ci skip]
It was removed previously, since it now refers to the environment being
used.
This brings it back for now.
There could be a separate var for it later, and/or it needs changes
later (or rather the environment needs a new variable name, since it
should refer to the executable really) - but this is good for now I think.
Fixes https://github.com/davidhalter/jedi-vim/issues/833
This allows vimlparser to parse the vim file again, and it is more
convenient to have it in a real Python file anyway.
Small refactoring and minor text changes included.
Move jedi_vim.py and the jedi submodule into pythonx, which gets added
to Vim's internal sys.path. While jedi cannot be imported directly from
there, it still makes sense for consistency.
This is relevant for when using `:JediDebuginfo` in a broken setup,
where the call to `jedi#init_python()` in the autoload file throws an
error already (but `jedi#debug_info` is defined/loaded before already).