mirror of
https://github.com/aljazceru/Auto-GPT.git
synced 2026-02-23 15:14:44 +01:00
Adds check for Python 3.10 and print error message if required version not detected. (#3598)
* Updated run script to check for Python 3.10 and above, and provide informative error messages for unsupported versions. * Updated run script to check for Python 3.10 and above, and provide informative error messages for unsupported versions. --------- Co-authored-by: merwanehamadi <merwanehamadi@gmail.com>
This commit is contained in:
20
run.sh
20
run.sh
@@ -15,11 +15,15 @@ function find_python_command() {
|
||||
|
||||
PYTHON_CMD=$(find_python_command)
|
||||
|
||||
$PYTHON_CMD scripts/check_requirements.py requirements.txt
|
||||
if [ $? -eq 1 ]
|
||||
then
|
||||
echo Installing missing packages...
|
||||
$PYTHON_CMD -m pip install -r requirements.txt
|
||||
fi
|
||||
$PYTHON_CMD -m autogpt $@
|
||||
read -p "Press any key to continue..."
|
||||
if $PYTHON_CMD -c "import sys; sys.exit(sys.version_info < (3, 10))"; then
|
||||
$PYTHON_CMD scripts/check_requirements.py requirements.txt
|
||||
if [ $? -eq 1 ]
|
||||
then
|
||||
echo Installing missing packages...
|
||||
$PYTHON_CMD -m pip install -r requirements.txt
|
||||
fi
|
||||
$PYTHON_CMD -m autogpt $@
|
||||
read -p "Press any key to continue..."
|
||||
else
|
||||
echo "Python 3.10 or higher is required to run Auto GPT."
|
||||
fi
|
||||
Reference in New Issue
Block a user