Added check for python version (#1570)

* Added check for python version

* Update for PYTHON_VERSION_X_Y
This commit is contained in:
Ranvir Singh Virk
2023-06-21 18:56:47 -07:00
committed by GitHub
parent 1a8e2024d6
commit 18daec78c8

View File

@@ -27,6 +27,11 @@ PYTHON_VERSION_X_Y=`${PYTHON} -c 'import sys; version=sys.version_info[:2]; prin
echo "Python: $PYTHON"
echo "Python version: $PYTHON_VERSION_X_Y"
if [ "$PYTHON_VERSION_X_Y" != "3.11" ]; then
echo "Error: Python version 3.11 is required."
exit 1
fi
if [[ "$SKIP_VENV" != "1" ]]; then
if [[ -z "${CONDA_PREFIX}" ]]; then
# Not a conda env. So create a new VENV dir