Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Python installing setuptools, ez_setup.py error

I am trying to install setuptools on Windows.
The documentation says I should run ez_setup.py.
So I did and I get the following output:

Extracting in c:\users\ut601039\appdata\local\temp\tmpf6a2mb
Now working in c:\users\ut601039\appdata\local\temp\tmpf6a2mb\setuptools-1.0
Installing Setuptools
Something went wrong during the installation.
See the error message above.

Traceback (most recent call last):
  File "D:\Python\Setuptools\ez_setup.py", line 357, in <module>
    sys.exit(main())
SystemExit: 2

The error message isn't very informative. Looking into the code I found:

        if not _python_cmd('setup.py', 'install', *install_args):
            log.warn('Something went wrong during the installation.')
            log.warn('See the error message above.')
            # exitcode will be 2
            return 2

I went to _python_cmd() and found:

def _python_cmd(*args):
args = (sys.executable,) + args
return subprocess.call(args) == 0

I found that subprocess.call(args) returns 1 instead of the expected 0.

like image 274
José Avatar asked Aug 19 '13 18:08

José


1 Answers

how are you trying to run & install it? ideally.. run cmd then cd to extracted folder & run python setup.py install this should install it.. if you are on 64 bit windows with 64bit python then you need to get the appropriate version can be found here: (http://www.lfd.uci.edu/~gohlke/pythonlibs/#setuptools)

like image 188
Simon K Bhatta4ya Avatar answered Sep 28 '22 08:09

Simon K Bhatta4ya