[Cython] cython-0.9.6.12 4 tests fail

Robert Bradshaw robertwb at math.washington.edu
Tue Feb 26 18:58:13 CET 2008


This is the correct error, but the actual message is different  
depending on the version of Python. In Python 2.3 it is "ValueError:  
unpack tuple of wrong size" but in Python 2.5 it is "ValueError: too  
many values to unpack."

Note sure how to best test for this.

- Robert


On Feb 26, 2008, at 9:53 AM, Neal Becker wrote:

> Is this expected?
>
> FAIL: Doctest: unpacklistcomp
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/usr/lib64/python2.5/doctest.py", line 2112, in runTest
>     raise self.failureException(self.format_failure(new.getvalue()))
> AssertionError: Failed doctest test for unpacklistcomp
>   File "/home/nbecker/Cython-0.9.6.12/BUILD/unpacklistcomp.so",  
> line 80, in unpacklistcomp
>
> ----------------------------------------------------------------------
> File "/home/nbecker/Cython-0.9.6.12/BUILD/unpacklistcomp.so", line  
> 84, in unpacklistcomp
> Failed example:
>     unpack_normal([1,2,3])
> Expected:
>     Traceback (most recent call last):
>     ValueError: too many values to unpack
> Got:
>     Traceback (most recent call last):
>       File "/usr/lib64/python2.5/doctest.py", line 1212, in __run
>         compileflags, 1) in test.globs
>       File "<doctest unpacklistcomp[1]>", line 1, in <module>
>         unpack_normal([1,2,3])
>       File "unpacklistcomp.pyx", line 22, in  
> unpacklistcomp.unpack_normal
>     ValueError: unpack sequence of wrong size
> ----------------------------------------------------------------------
> File "/home/nbecker/Cython-0.9.6.12/BUILD/unpacklistcomp.so", line  
> 90, in unpacklistcomp
> Failed example:
>     unpack_comp([1,2,3])
> Expected:
>     Traceback (most recent call last):
>     ValueError: too many values to unpack
> Got:
>     Traceback (most recent call last):
>       File "/usr/lib64/python2.5/doctest.py", line 1212, in __run
>         compileflags, 1) in test.globs
>       File "<doctest unpacklistcomp[3]>", line 1, in <module>
>         unpack_comp([1,2,3])
>       File "unpacklistcomp.pyx", line 26, in  
> unpacklistcomp.unpack_comp
>     ValueError: unpack sequence of wrong size
> ----------------------------------------------------------------------
> File "/home/nbecker/Cython-0.9.6.12/BUILD/unpacklistcomp.so", line  
> 96, in unpacklistcomp
> Failed example:
>     unpack_expr([1,2,3])
> Expected:
>     Traceback (most recent call last):
>     ValueError: too many values to unpack
> Got:
>     Traceback (most recent call last):
>       File "/usr/lib64/python2.5/doctest.py", line 1212, in __run
>         compileflags, 1) in test.globs
>       File "<doctest unpacklistcomp[5]>", line 1, in <module>
>         unpack_expr([1,2,3])
>       File "unpacklistcomp.pyx", line 30, in  
> unpacklistcomp.unpack_expr
>     ValueError: unpack sequence of wrong size
>
>
> ----------------------------------------------------------------------
> Ran 303 tests in 0.382s
>
> FAILED (failures=4)
>
>
> _______________________________________________
> Cython-dev mailing list
> Cython-dev at codespeak.net
> http://codespeak.net/mailman/listinfo/cython-dev



More information about the Cython-dev mailing list