From edfb447ff883c2833b56828bbdc11435299021ae Mon Sep 17 00:00:00 2001 From: Michael Henry Date: Sun, 31 Aug 2025 14:17:21 -0400 Subject: [PATCH] fix(health): update advice for Python #35564 Problem: `:checkhealth` advice for Python is out-of-date. Solution: Update the advice to point to `:help provider-python`. (cherry picked from commit f311c96973a561ba5e664f46e758a97fd10acdcb) --- runtime/lua/vim/provider/health.lua | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/runtime/lua/vim/provider/health.lua b/runtime/lua/vim/provider/health.lua index e4b5206fa4..a0c4ac0626 100644 --- a/runtime/lua/vim/provider/health.lua +++ b/runtime/lua/vim/provider/health.lua @@ -724,10 +724,9 @@ local function python() local message = 'Detected pip upgrade failure: Python executable can import "pynvim" but not "neovim": ' .. pynvim_exe local advice = { - 'Use that Python version to reinstall "pynvim" and optionally "neovim".', + 'Use that Python version to uninstall any "pynvim" or "neovim", e.g.:', pynvim_exe .. ' -m pip uninstall pynvim neovim', - pynvim_exe .. ' -m pip install pynvim', - pynvim_exe .. ' -m pip install neovim # only if needed by third-party software', + 'Then see :help provider-python for "pynvim" installation steps.', } health.error(message, advice) end @@ -753,7 +752,7 @@ local function python() if is_bad_response(current) then health.error( 'pynvim is not installed.\nError: ' .. current, - 'Run in shell: ' .. python_exe .. ' -m pip install pynvim' + 'See :help provider-python for "pynvim" installation steps.' ) end