From 552d86a89c6231bb8314b97a1ebb3cc3a0be5d78 Mon Sep 17 00:00:00 2001 From: goldyfruit Date: Tue, 15 Oct 2024 12:07:19 -0400 Subject: [PATCH] [utils/common] Check for Python version higher than 3.8 --- utils/common.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/utils/common.sh b/utils/common.sh index 33f5288..2b2ccee 100644 --- a/utils/common.sh +++ b/utils/common.sh @@ -255,6 +255,13 @@ function required_packages() { # to match the target user. function create_python_venv() { echo -ne "➤ Creating installer Python virtualenv... " + + # Make sure Python version is higher then 3.8. + if [ "$(ver "$PYTHON")" -lt "$(ver 3.9)" ]; then + echo "python $PYTHON is not supported" &>>"$LOG_FILE" + on_error + fi + # Disable https://www.piwheels.org/simple when aarch64 CPU architecture # or Raspberry Pi 5 board are detected. if [ -f /etc/pip.conf ]; then