[f2py] crackfortran.py

Gergely Buday <[email protected]> Tue, 5 Mar 2013 15:10:33 +0100
Newsgroups gmane.comp.python.f2py.user
Message-ID <CA+3iOznChffFFU42bSVmFoVXpJoX7oP4Jb6KfssqL8-7-=hnqQ@mail.gmail.com>
Hi there,

I am trying to compile an amateur radio program that uses f2py. I get
the following error message:

Traceback (most recent call last):
  File "/usr/local/bin/f2py", line 3, in <module>
    import f2py2e
  File "/usr/local/lib/python2.7/dist-packages/f2py2e/__init__.py",
line 10, in <module>
    import f2py2e
  File "/usr/local/lib/python2.7/dist-packages/f2py2e/f2py2e.py", line
26, in <module>
    import crackfortran
  File "/usr/local/lib/python2.7/dist-packages/f2py2e/crackfortran.py",
line 1586
    as=b['args']
     ^

Googling a bit I have found that the problem is that 'as' is a
reserved keyword in later Python versions so it is not allowed to use
it as a variable name. What can I do to fix this? My Python version is
Python 2.7.3 and I use Ubuntu 12.04. I tried the built-in python-numpy
and tha latest tgz from the f2py site as well.

Or, is this a known problem and there is a known fix?

- Gergely