Results 1 to 4 of 4

Thread: Uninstall python 2.7?

  1. #1
    Join Date
    Oct 2010
    Location
    Ohio
    Beans
    0
    Distro
    Xubuntu 10.04 Lucid Lynx

    Uninstall python 2.7?

    I just installed Python 2.7 from the source and started to work on one of my Tk apps. I tried to run it and it gives the error that _tkinter can't be imported. So I tried wx/ gtk/ pygame and none of these could be imported...

    I just need to know how to uninstall Python 2.7, as it's not in my installed programs on the software center, and make uninstall didn't work.

  2. #2
    Join Date
    Sep 2010
    Location
    Kent UK
    Beans
    62
    Distro
    Ubuntu

    Re: Uninstall python 2.7?

    Quote Originally Posted by trippn740 View Post
    I just installed Python 2.7 from the source and started to work on one of my Tk apps. I tried to run it and it gives the error that _tkinter can't be imported. So I tried wx/ gtk/ pygame and none of these could be imported...

    I just need to know how to uninstall Python 2.7, as it's not in my installed programs on the software center, and make uninstall didn't work.
    Hi

    Try synaptic package manager
    Ibod.

  3. #3
    Join Date
    Dec 2006
    Beans
    Hidden!

    Re: Uninstall python 2.7?

    Quote Originally Posted by ibod View Post
    Hi

    Try synaptic package manager
    Please read carefully the post before answering. He explicitly said he had installed Python 2.7 from source, and is thus not available to remove it through the package manager.


    As for the OP. Are you having problems with your entire Ubuntu system or only with your program?

    It is quite natural that you cannot import third party modules, because the new Python installation may be searching other paths with non-existent modules. It is a bad idea to install a newer Python version just because it's newer. You need to know what you are doing before doing it, specifically to avoid over-writing your older Python installation.

    In general, there is no straight-forward way to remove Python 2.7 installed from source. You could simply remove the directories that were created and their contents.

    And make sure you don't have Python binaries such as "/usr/local/bin/python" which override the default "/usr/bin/python". This last one should be a symbolic link to the previous Python binary, "/usr/bin/python2.6".

    Also see this thread "How do I install python 2.7 in lucid?", for a similar issue regarding installing/removing Python from source.

  4. #4
    Join Date
    Oct 2010
    Location
    Ohio
    Beans
    0
    Distro
    Xubuntu 10.04 Lucid Lynx

    Re: Uninstall python 2.7?

    I worked it out with changing the link to python;

    Code:
    sudo ln -f /usr/bin/python2.6 /usr/local/bin/python
    I'm back to 2.6 for the default, and didn't have to delete 2.7

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •