From e7317a836a7ea6d0d6e923b3816c29a1e10a4d7c Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Tue, 14 Oct 2025 21:26:06 +0800 Subject: [PATCH] cephadm/build: Fix _has_python_pip() function check The _has_python_pip() function was incorrectly checking for the venv module instead of pip, causing it to always return the wrong result. This would prevent proper detection of whether pip is available during the cephadm build process. Fix by changing the module check from 'venv' to 'pip'. Signed-off-by: Kefu Chai --- src/cephadm/build.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cephadm/build.py b/src/cephadm/build.py index d86737dfd2a3..bdc117e9d27c 100755 --- a/src/cephadm/build.py +++ b/src/cephadm/build.py @@ -423,7 +423,7 @@ def _has_python_venv(executable): def _has_python_pip(executable): res = _run( - [executable, '-m', 'venv', '--help'], stdout=subprocess.DEVNULL + [executable, '-m', 'pip', '--help'], stdout=subprocess.DEVNULL ) return res.returncode == 0 -- 2.47.3