2

So on my 18.04 I upgraded my python3 to 3.7 (which build a meld dependency) and did this:

update-alternatives --install /usr/bin/python python /usr/bin/python3 1

which made the python command default to python 3 but not am realizing it is breaking a number of utilities such as our software build, thg and my lock screen, networking. I'd like to revert but have discovered this command does not revert as desired:

update-alternatives --install /usr/bin/python python /usr/bin/python2 1

How would I revert my system to it's original state of python launching python2?

Is this not recommended or will there be any side effects if I did this route?

sudo rm /etc/alternatives/python
sudo ln -s /usr/bin/python2 /etc/alternatives/python
2
  • The usual interactive usage would be sudo update-alternatives --config python, then follow the on-screen instructions - did you try that? Aug 12, 2022 at 20:30
  • Wish I saw this a little earlier I had deleted /etc/alternatives/python and created a link to /usr/bin/python2. Hope there are no side effects from my manual approach.
    – simgineer
    Aug 12, 2022 at 20:43

0

You must log in to answer this question.

Browse other questions tagged .