0

I followed first approach in this link to install python 3.8

Steps I followed:

 sudo yum install -y amazon-linux-extras
 amazon-linux-extras | grep -i python
sudo amazon-linux-extras enable python3.8
sudo yum install python3.8

After that, python3.8 command is working.

[ec2-user@amazonlinux ~]$ python3.8 --version
Python 3.8.5

But not python3.

[ec2-user@amazonlinux ~]$ python3 --version
-bash: python3: command not found

changing the link below, is suggested not as it is breaking the system. So I didn't try.

rm /usr/bin/python3 
ln -s /usr/bin/python3.8 /usr/bin/python3 

1 Answers1

0

Use alternatives to manage different versions of python interpreters

update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.8 1

Yuri K
  • 1
  • 1