Kit
Kit

Reputation: 31543

Reset easy_install after uninstalling Python on OS X

I had 64-bit Python at first, then I installed BeautifulSoup using easy_install.

For some reason, I uninstalled 64-bit Python using this method. Then I reinstalled the 32-bit version from Python.org. However:

Kit:~ Kit$ easy_install beautifulsoup
Searching for beautifulsoup
Best match: BeautifulSoup 3.2.0
Processing BeautifulSoup-3.2.0-py2.6.egg
BeautifulSoup 3.2.0 is already the active version in easy-install.pth

Using /Library/Python/2.6/site-packages/BeautifulSoup-3.2.0-py2.6.egg
Processing dependencies for beautifulsoup
Finished processing dependencies for beautifulsoup

This is a nasty sign that I haven't really found an easy way to cleanly uninstall Python on OS X. Besides, it mentions BeautifulSoup for Python 2.6, but I have 2.7. Sad :(

How do I reset easy-install.pth? I couldn't find it on Spotlight.

Upvotes: 0

Views: 1207

Answers (1)

Nicholas Riley
Nicholas Riley

Reputation: 44371

Looks like you're running easy_install from the system Python 2.6. Apple ships easy_install with the OS. If you just installed Python 2.7 from python.org, you'll need to install distribute for that version. (Note that you'll need to do this as root so it can write to /usr/local/bin.) There are also Python version-suffixed easy_install versions, e.g. easy_install-2.6, so if for some reason you want to install a package in the system Python, then you can still do so.

Also, investigate pip which has an uninstall feature.

Upvotes: 1

Related Questions