From 7fd17a1a822a7b5af3a92bea02061bd1564a5dc6 Mon Sep 17 00:00:00 2001 From: Hans Johnson Date: Mon, 8 Jul 2024 13:38:00 -0500 Subject: [PATCH] Replace deprecated pkgutil.find_loader use :1: DeprecationWarning: 'pkgutil.find_loader' is deprecated and slated for removal in Python 3.14; use importlib.util.find_spec() instead Signed-off-by: Hans Johnson --- runtests.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtests.sh b/runtests.sh index 0b3e20ce49..65e3a2bb6b 100755 --- a/runtests.sh +++ b/runtests.sh @@ -167,7 +167,7 @@ function clang_format { } function is_pip_installed() { - return $("${PY_EXE}" -c "import sys, pkgutil; sys.exit(0 if pkgutil.find_loader(sys.argv[1]) else 1)" $1) + return $("${PY_EXE}" -c "import sys, importlib.util; sys.exit(0 if importlib.util.find_spec(sys.argv[1]) else 1)" $1) } function clean_py {