Skip to content
This repository

DistributionNotFound on running ipython 0.11 on Windows XP x86 #866

Closed
ruidc opened this Issue October 13, 2011 · 12 comments

2 participants

ruidc Thomas Kluyver
ruidc
Traceback (most recent call last):
  File "C:\Python27\Scripts\ipython-script.py", line 5, in <module>
    from pkg_resources import load_entry_point
  File "C:\Python27\lib\site-packages\pkg_resources.py", line 2607, in <module>
    parse_requirements(__requires__), Environment()
  File "C:\Python27\lib\site-packages\pkg_resources.py", line 565, in resolve
    raise DistributionNotFound(req)  # XXX put more info here
pkg_resources.DistributionNotFound: ipython==0.11

Any ideas?

Thomas Kluyver
Collaborator

If you do import IPython, does it succeed, and could it be importing an older version of IPython you already had installed?

ruidc

sorry, I realise now that I did not make it obvious: this was on running ipython from the command line.
Importing from python succeeds:
``

import IPython
IPython.version
'0.11'
``

Thomas Kluyver
Collaborator

Hmm, that's odd. How did you install IPython, and did you have any version of IPython installed before?

ruidc

Installed from the official binary windows installer (.MSI).
I did have 0.10 installed and working fine, but I removed that by deleting both the IPython and the .egg-info directory first.

The only other potential problem or red herring is that I also have python 3.2 installed, and the installer brought that up as the default directory, but it also found the 2.7 in the registry and that is what I selected.

Thomas Kluyver
Collaborator

When you start it, are you sure it's Python 2.7 being used to run the startup script? E.g. could the python.exe on your PATH be Python 3.2?

ruidc

my path env variable includes C:\Python27 and no reference to 3.2

which ipython

returns

C:\Python27\Scripts\ipython
C:\Python27\Scripts\ipython.exe
C:\Python27\Scripts\ipython.bat

which python

returns

C:\Python27\python.exe

Thomas Kluyver
Collaborator

Hmm, beats me. I didn't even know we created an ipython.exe file. What command do you use to start it up?

ruidc

just typing: ipython from the command line,
i.e. from an open cmd.exe window, although results are also the same from start > run > ipython

running ipython.bat

returns:

Traceback (most recent call last):
  File "C:\Python27\scripts\ipython.py", line 26, in <module>
    import IPython.Shell
ImportError: No module named Shell

and also in python, importing:

>>> import IPython.Shell
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named Shell
Thomas Kluyver
Collaborator

IPython.Shell is a module from 0.10 that's not in 0.11, so at least C:\Python27\scripts\ipython.py must be a leftover from 0.10.

ruidc

Indeed, I was looking for that class without luck. I removed anything ipython related (and ran the uninstaller - which is probably what I should have done to begin with) and reran the installer and it works fine.

Thanks for your help and sorry for the noise.

ruidc ruidc closed this October 13, 2011
Thomas Kluyver
Collaborator

Great - glad you got it sorted out. We'd love to make it an easier experience, but most of the core developers are on Linux or Mac, so we don't see the friction on Windows so much. Many of our Windows users get it through a Python distribution like EPD or Python(x,y), which I think makes life a bit easier.

ruidc

Lucky them! I wish I could be too :) but unfortunately, we have win users to support and so try to be on the same platform as them, and use the base distributions. Still - was my own fault for not cleaning up previous install, and I agree with the FOSS ethos of "if there's something missing, it's because you (consumer) didn't do it", so it's my fault twice over :) thanks again for your persistence, it's proof that checking back over the basics can lead you down a path to identifying and resolving the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.