From bce96d2fd483e71826728c6f9ac721fc9dd7d2cf Mon Sep 17 00:00:00 2001 From: William Boman Date: Sun, 21 Jan 2024 18:47:59 +0100 Subject: feat: don't use vim.g.python3_host_prog as a candidate for python (#1606) This is inconsistent with how other system dependencies are resolved and is not documented anywhere. --- lua/mason-core/installer/managers/pypi.lua | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'lua/mason-core/installer/managers/pypi.lua') diff --git a/lua/mason-core/installer/managers/pypi.lua b/lua/mason-core/installer/managers/pypi.lua index 0f3de1fb..7c0e5bb9 100644 --- a/lua/mason-core/installer/managers/pypi.lua +++ b/lua/mason-core/installer/managers/pypi.lua @@ -72,13 +72,7 @@ function M.init(opts) a.scheduler() - local executables = platform.is.win - and _.list_not_nil( - vim.g.python3_host_prog and vim.fn.expand(vim.g.python3_host_prog), - "python", - "python3" - ) - or _.list_not_nil(vim.g.python3_host_prog and vim.fn.expand(vim.g.python3_host_prog), "python3", "python") + local executables = platform.is.win and { "python", "python3" } or { "python3", "python" } -- pip3 will hardcode the full path to venv executables, so we need to promote cwd to make sure pip uses the final destination path. ctx:promote_cwd() -- cgit v1.2.3-70-g09d2