Re: [Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread David Cournapeau
Robert Kern wrote: > > There shouldn't need to be (and also, there shouldn't be, in this > case). That's an odd bug in nose, then. It should be able to import a > module from a package. Nothing needs to be in __init__.py for that to > work. > > FWIW, I just change to a different directory, and the

Re: [Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread Robert Kern
On Fri, Mar 13, 2009 at 01:13, David Cournapeau wrote: > Robert Kern wrote: >>> Is adding additional imports fine too ? Or should we fix those in the >>> unittest instead to avoid more namespace pollution ? >>> >> >> What do you mean? >> >> > > For example, we have: > > ===

Re: [Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread David Cournapeau
Robert Kern wrote: >> Is adding additional imports fine too ? Or should we fix those in the >> unittest instead to avoid more namespace pollution ? >> > > What do you mean? > > For example, we have: == ERROR: Failure: Imp

Re: [Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread Robert Kern
On Fri, Mar 13, 2009 at 01:02, David Cournapeau wrote: > Robert Kern wrote: >> >> When it does work, the reason is because the import mechanism will >> place the "numeric" module into the "numpy.core" namespace as soon as >> it can, so it is usually available in the __init__ after a "from >> numer

Re: [Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread David Cournapeau
Robert Kern wrote: > > When it does work, the reason is because the import mechanism will > place the "numeric" module into the "numpy.core" namespace as soon as > it can, so it is usually available in the __init__ after a "from > numeric import *". nose tries to control imports a little more tight

Re: [Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread Robert Kern
On Fri, Mar 13, 2009 at 00:42, David Cournapeau wrote: > Hi, > >    While making sure in-place builds work, I got the following problem: > > python setup.py build_ext -i > python -c "import numpy as np; np.test()" > -> many errors > > The error are all import errors: > > Traceback (most recent cal

[Numpy-discussion] A question about import in numpy and in place build

2009-03-12 Thread David Cournapeau
Hi, While making sure in-place builds work, I got the following problem: python setup.py build_ext -i python -c "import numpy as np; np.test()" -> many errors The error are all import errors: Traceback (most recent call last): File "/usr/media/src/dsp/numpy/git/numpy/tests/test_ctypeslib.