On 11/8/06, Stefan van der Walt <[EMAIL PROTECTED]> wrote: > This looks very interesting. It works for me on simple scripts, but > whenever I include the lines > > from numpy.testing import set_local_path > set_local_path('../../..') > > in the input, pycachegrind aborts with > > File > "/home/stefan//lib/python2.4/site-packages/numpy/testing/numpytest.py", line > 68, in set_local_path > if f.f_locals['__name__']=='__main__': > KeyError: '__name__' > > I guess this is because the script is run in a separate namespace. > I've managed to work around the problem by changing the definition of > 'run' to:
Good catch, thanks, I've fixed the public version with your changes. Best, f ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Numpy-discussion mailing list Numpy-discussion@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/numpy-discussion