On 03/24/2010 01:25 PM, Charles R Harris wrote:

On Wed, Mar 24, 2010 at 8:17 AM, Bruce Southey <bsouthey@gmail.com> wrote:
Wow, this is really impressive!
I installed the svn numpy version '2.0.0.dev8300' with the latest Python
3.1.2 and it works!

All the tests pass except:

I am guessing that it is this line as the other io imports do not have
the period.
from .io import StringIO

I went ahead and renamed lib/io.py to lib/npyio.py in r8302. Can you give it a try? you might need to rm the build/py3k directory first to make it work.



_______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion
I get a different error because it also has 'import collections'.

$ python3.1
Python 3.1.2 (r312:79147, Mar 24 2010, 10:44:23)
[GCC 4.4.3 20100127 (Red Hat 4.4.3-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import numpy
>>> numpy.__version__
>>> numpy.test()
Running unit tests for numpy
NumPy version 2.0.0.dev8302
NumPy is installed in /usr/local/lib/python3.1/site-packages/numpy
Python version 3.1.2 (r312:79147, Mar 24 2010, 10:44:23) [GCC 4.4.3 20100127 (Red Hat 4.4.3-4)]
nose version 0.11.0

ERROR: test_utils.test_lookfor
Traceback (most recent call last):
  File "/usr/local/lib/python3.1/site-packages/nose/case.py", line 177, in runTest
  File "/usr/local/lib/python3.1/site-packages/numpy/lib/tests/test_utils.py", line 10, in test_lookfor
  File "/usr/local/lib/python3.1/site-packages/numpy/lib/utils.py", line 751, in lookfor
    cache = _lookfor_generate_cache(module, import_modules, regenerate)
  File "/usr/local/lib/python3.1/site-packages/numpy/lib/utils.py", line 945, in _lookfor_generate_cache
    elif isinstance(item, collections.Callable):
  File "/usr/local/lib/python3.1/abc.py", line 121, in __instancecheck__
    subclass = instance.__class__
AttributeError: 'PyCapsule' object has no attribute '__class__'

Ran 2898 tests in 21.738s

FAILED (KNOWNFAIL=5, errors=1)
<nose.result.TextTestResult run=2898 errors=1 failures=0>

$ diff build/py3k/build/lib.linux-x86_64-3.1/numpy/lib/utils.py build311/py3k/build/lib.linux-x86_64-3.1/numpy/lib/utils.py
< import collections
<         elif isinstance(item, collections.Callable):
>         elif hasattr(item, '__call__'):