[SciPy-user] debugging scipy
Sat Dec 29 15:29:11 CST 2007
Georg Holzmann wrote:
> I have a problem using scipy in the python debugger (I do that with the
> eric4 IDE).
> When I step through the commands, I got the an error (only in debug
> mode!) at the statement:
> "import scipy"
> and the error is:
> The file
> could not be opened.
> and then:
> The debugged program raised the exception OSError
> "[Errno 2] No such file or directory: '/home/holzi/scipytest/test'"
> Line: 1659
> Break here?
> But my setuptools installation seems to be ok and the file
> /usr/lib/python2.5/site-packages/setuptools-0.6c7-py2.5.egg/ is present.
> (my scipy version is 0.6.0, Python 2.5.1)
> Has anyone a hint what I can try to resolve this problem ?
Eric apparently does not know anything about zipped eggs. The setuptools egg is
zipped and pkg_resource.py is inside of it. In debug mode, I imagine it tries to
load the source of every module that gets imported.
Remove the lines in scipy/__init__.py:
import pkg_resources as _pr # activate namespace packages (manipulates __path__)
I'm not really sure why we put them there, though.
"I have come to believe that the whole world is an enigma, a harmless enigma
that is made terrible by our own mad attempt to interpret it as though it had
an underlying truth."
-- Umberto Eco
More information about the SciPy-user