56

I'm trying to install couchapp, which uses easy_install - and is quite explicit in stating a particular version of easy_install/setuptools is needed: 0.6c6. I seem to have easy_install already on my Mac, but there's no command-line arguments to check the version. Instead of just installing a new version over the top, I'd like to see whether it's necessary first.

So: Any pointers on how I can see what version of setuptools/easy_install I have installed on my machine?

I'm not a Python developer, so I'm assuming this is a simple question. However, I've not found anything via Google or here on SOF.

4 Answers 4

81

This seems to get a lot of hits from google, so I thought I'd update for those folks. I was able to do:

easy_install --version

which produced the output

setuptools 3.4.3

I believe this only works for some (newer?) versions of setuptools

3
  • 1
    Mine prints setuptools 2.0. This will work for Windows users too.
    – delroh
    Aug 7, 2014 at 6:20
  • Mine prints setuptools 1.1.6. Seems likely this may be all=)
    – joedragons
    Apr 13, 2016 at 21:17
  • I get ImportError: No module named extern when I think I'm running setuptools 28.8.0. Probably related to github.com/pypa/setuptools/issues/738
    – nealmcb
    Nov 18, 2016 at 0:17
20

One way would be to look at the actual source file for easy_install. Do

which easy_install

to see where it's located, and then use that path in

less path/to/easy_install

The second line in my easy_install script says:

# EASY-INSTALL-ENTRY-SCRIPT: 'setuptools==0.6c11','console_scripts','easy_install'

which suggests that I have easy_install version 0.6c11.

2
  • 4
    My file had no version information at all - which I'm assuming means it's too old. Thanks for the pointers, have installed a new version, everything seems fine thus far.
    – pat
    Dec 24, 2009 at 5:21
  • 1
    My version of easy_setup does not have that information anywhere in it, nor does it have a --version flag(!!). I ended up having to look in /Library/Python/2.7/site-packages/ to see what egg was installed (OS X).
    – Spanky
    Jan 3, 2014 at 3:52
12

On Windows, where Python is in the Path:

python -m easy_install --version

For me, I get setuptools 7.0 as the response.

0
3

If you don't have easy_install, this worked for me:

$ python
Python 3.10.0
>>> import setuptools
>>> setuptools.__version__ 

Solution found here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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