[Numpy-discussion] Trouble using f2py on successful numpy build from SVN (1.0.5 dev4951)

Robert Kern robert.kern at gmail.com
Mon Mar 31 05:10:31 EDT 2008


On Mon, Mar 31, 2008 at 12:45 AM, Joshua Lippai <discerptor at gmail.com> wrote:
> I am using Mac OS X 10.5.2, with Python 2.5.2. My build output for
>  NumPy is clean and successful and my numpy.test produces no errors or
>  failures, but when I type f2py from Terminal, I get the following:
>
>  $ f2py
>  Traceback (most recent call last):
>   File "/Library/Frameworks/Python.framework/Versions/Current/bin/f2py",
>  line 5, in <module>
>     pkg_resources.run_script('numpy==1.0.5.dev4951', 'f2py')
>   File "build/bdist.macosx-10.3-i386/egg/pkg_resources.py", line 448,
>  in run_script
>   File "build/bdist.macosx-10.3-i386/egg/pkg_resources.py", line 1160,
>  in run_script
>  pkg_resources.ResolutionError: No script named 'f2py'
>
>  Any ideas what could be up here?

Exactly how did you install numpy? Did you use easy_install? What does
the egg directory look like? For example inside my egg, there is a
subdirectory called EGG-INFO/ which has another subdirectory called
scripts/ which has the actual f2py script.

[scripts]$ pwd
/Library/Frameworks/Python.framework/Versions/Current/lib/python2.5/site-packages/numpy-1.0.5.dev4951-py2.5-macosx-10.3-fat.egg/EGG-INFO/scripts
[scripts]$ ls
f2py

This is what the bootstrap script installed to /Library/.../bin/f2py
is looking for.

If you did not intend to install an egg of numpy, this might be a
leftover from a previous try. Delete the /Library/.../bin/f2py script
and install numpy again.

-- 
Robert Kern

"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 NumPy-Discussion mailing list