From 42f94603692d1165f5ebd4f0bed069b047aa2060 Mon Sep 17 00:00:00 2001 From: Donald Zou Date: Fri, 10 Apr 2026 16:18:12 +0800 Subject: [PATCH] Update wgd.sh --- src/wgd.sh | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/src/wgd.sh b/src/wgd.sh index 29dc60db..9736d7cc 100755 --- a/src/wgd.sh +++ b/src/wgd.sh @@ -247,27 +247,19 @@ _checkWireguard(){ _checkPythonVersion(){ - version_pass=$($pythonExecutable -c 'import sys; print("1") if (sys.version_info.major == 3 and sys.version_info.minor >= 10) else print("0");') + version_pass=$($pythonExecutable -c 'import sys; print("1") if (sys.version_info.major == 3 and sys.version_info.minor >= 12) else print("0");') version=$($pythonExecutable --version) if [ $version_pass == "1" ] then printf "[WGDashboard] %s Found compatible version of Python. Will be using %s to install WGDashboard.\n" "$heavy_checkmark" "$($pythonExecutable --version)" return; - elif python3.10 --version > /dev/null 2>&1 - then - printf "[WGDashboard] %s Found Python 3.10. Will be using [python3.10] to install WGDashboard.\n" "$heavy_checkmark" - pythonExecutable="python3.10" - elif python3.11 --version > /dev/null 2>&1 - then - printf "[WGDashboard] %s Found Python 3.11. Will be using [python3.11] to install WGDashboard.\n" "$heavy_checkmark" - pythonExecutable="python3.11" elif python3.12 --version > /dev/null 2>&1 then printf "[WGDashboard] %s Found Python 3.12. Will be using [python3.12] to install WGDashboard.\n" "$heavy_checkmark" pythonExecutable="python3.12" else printf "[WGDashboard] %s Could not find a compatible version of Python. Current Python is %s.\n" "$heavy_crossmark" "$version" - printf "[WGDashboard] WGDashboard required Python 3.10, 3.11 or 3.12. Halting install now.\n" + printf "[WGDashboard] WGDashboard required Python 3.12 or above. Halting install now.\n" kill $TOP_PID fi }