4

On Ubuntu 15.10 when changing the symlink /usr/bin/python from python2.7 to python3.4 then terminator won t start anymore. Do you know what the problem could be and how to fix it? Thank you :)

4
  • Check terminator's requirements - it may need python 2, and not python 3 - by changing where 'python' links to you forced it to try and use Python 3, where it may not work.
    – Thomas Ward
    May 16, 2016 at 1:21
  • Check terminator's requirements - it may need python 2, and not python 3 - by changing where 'python' links to you forced it to try and use Python 3, where it may not work.
    – Thomas Ward
    May 16, 2016 at 1:21
  • 1
    Changing /usr/bin/python is just going to cause problems. Don't. Even Python doesn't recommend it: python.org/dev/peps/pep-0394
    – muru
    Jan 9, 2017 at 8:07
  • Make sure not to have installed it via pip pip uninstall terminator and reboot the system. New version of terminator works great with python3
    – M at
    Jan 28, 2022 at 8:04

3 Answers 3

6

You can simply fix it by editing /usr/bin/terminator shebang path back to python2, see https://bugs.launchpad.net/ubuntu/+source/terminator/+bug/1621156

5

Edit the /usr/bin/terminator

sudo vi /usr/bin/terminator

and change the first line (shebang)

#!/usr/bin/python

to

#!/usr/bin/python2

NOTE: Get the path of python2 using:

$ which python2
/usr/bin/python2
2
  • I changed this but it still didn't work. Do I want to build terminator again?
    – azizbro
    Mar 18, 2020 at 3:09
  • Just this change should work. Also, please check the path with which python2 or which python2.7 Mar 18, 2020 at 7:42
0

To solve the problem I had to change the python3 version (I had 3.9 and changed to 3.8). Try to change it directly in the first line of /usr/bin/terminator, from

#!/usr/bin/python3

to ex 3.8

#!/usr/bin/python3.8

if this doesn't work try unlink python3 from 3.9 and link to 3.8 and then reinstall terminator:

use python3 -V too see immediatly which version you have to see if it is 3.9

1)goto usr/bin: cd /usr/bin

2)check each python command what is linked to: ls -lrth python*. Here I had python3 -> python3.9

also which python3 should give /usr/bin/python3

3)Unlink python3: sudo unlink python3

4)Link to another version: sudo ln -s python3.8 python3 I had 3.8 but I guess other older version work too. n.b you can use this command to change also python and python2 links

Now python3 -V should give the new version

5)Uninstall terminator and reinstall

sudo apt-get remove --auto-remove terminator
sudo apt-get purge --auto-remove terminator
sudo apt install terminator

Now it should work. if you need python3 to be pyton3.9 you can edit /usr/bin/terminator and change #!/usr/bin/python3 to #!/usr/bin/python3.8 and then relink python3 to python3.9

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.