summaryrefslogtreecommitdiffstatshomepage
path: root/runtime/autoload/provider/python3.vim
AgeCommit message (Collapse)AuthorFiles
2025-03-29fix(provider): misleading :checkhealth if user sets ↵Sathya Pramodh1
g:loaded_python3_provider=1 #32696 Problem: :checkhealth shows a confusing message if user sets g:loaded_python3_provider=1. Solution: - Show a warning if that var is set to 1. - Update provider modules to default to 0. Any user code that is checking for 1, is like already broken because these may be set to 2.
2024-02-03refactor: create function for deferred loadingdundargoc1
The benefit of this is that users only pay for what they use. If e.g. only `vim.lsp.buf_get_clients()` is called then they don't need to load all modules under `vim.lsp` which could lead to significant startuptime saving. Also `vim.lsp.module` is a bit nicer to user compared to `require("vim.lsp.module")`. This isn't used for some nested modules such as `filetype` as it breaks tests with error messages such as "attempt to index field 'detect'". It's not entirely certain the reason for this, but it is likely it is due to filetype being precompiled which would imply deferred loading isn't needed for performance reasons.
2024-01-22refactor: rewrite python provider in luadundargoc1
2019-08-04provider: g:loaded_xx_provider=2 means "enabled and working"Justin M. Keyes1
Value of 1 cannot be used, because users might set that in their vimrc to _disable_ a provider, which would confuse :checkhealth and has().
2019-08-04provider: decide status by g:loaded_xx_providerJustin M. Keyes1
2019-08-04provider: let providers decide their statusRui Abreu Ferreira1
Instead of deciding provider status in eval_has_provider, move the decision to the provider Vim scripts. Previously, provider loading worked as follows: 1. eval_has_provider() verified provider availability by searching for the provider#providername#Call function and cached this verificaion as a static variable for some providers 2. providers short-circuited on loading to prevent the definition of the Call function (with the exception of the node provider that did not) This commit changes the expected interface between nvim and its providers to facilitate provider reloading, by splitting the verification of the provider from the availability of the Call function. eval_has_provider() now checks for a provider#providername#enabled variable. It is up to the provider script to set this to 0 or 1 accordingly. eval_call_provider() remains unchanged. All providers hosting a Call function were updated to respect this. The clipboard provider now has a Reload function to reload the provider.
2017-12-17provider/nodejs: check version in Detect()Justin M. Keyes1
2017-04-19health.vim: Set 'iskeyword' to that of ft=help.Justin M. Keyes1
2017-02-14providers: Disable if `g:loaded_*` exists.Justin M. Keyes1
The exists('g:loaded_foo') convention is rather common, and may be relied upon in some cases. It's also very unlikely that a user or plugin has any reason to set g:loaded_foo to zero, so the principle of least surprise can be brushed aside here. https://github.com/neovim/neovim/issues/6107#issuecomment-279532143
2017-02-13health.vim: Do not check intentionally disabled providers.Justin M. Keyes1
Closes #6107
2016-06-15doc: cleanupJustin M. Keyes1
2016-03-15python: move script_host.py to python-clientBjörn Linse1
2015-11-03runtime/autoload/provider/python{,3}.vim: fix E168Daniel Hahler1
Do not use `finish` inside of `provider#python{,3}#Call`, but `return`.
2015-06-09provider/python: Call: fix usage of 'finish' in functionDaniel Hahler1
Do not call it again in case of an exception in `remote#host#Require` (ref: https://github.com/neovim/neovim/pull/2549#issuecomment-102674350).
2015-06-09provider/python: define Prog and Error functions alwaysDaniel Hahler1
`provider#pythonX#Error` and `provider#pythonX#Prog` are currently meant for debugging only (the error message is not being used), and should therefore be defined always, especially in case of errors. Ref: https://github.com/neovim/neovim/pull/2549#issuecomment-98607580
2015-04-21Add if_python3 supportShougo Matsushita1
Reviewed-by: Michael Reed <m.reed@mykolab.com>, Daniel Hahler <github@thequod.de> Helped-by: Daniel Hahler <github@thequod.de>