Message261437
I tried to run numpy test suite on Python 3.6 compiled in debug mode. I got an assertion error. Then I wanted to try the Git version of numpy, but the "Cythonizing sources" step of the numpy installer fails with:
---
Traceback (most recent call last):
File "bin/cython", line 9, in <module>
load_entry_point('Cython==0.23.4', 'console_scripts', 'cython')()
(...)
File "lib/python3.6/site-packages/Cython/Compiler/Nodes.py", line 6585, in generate_execution_code
self.body.generate_execution_code(code)
File "lib/python3.6/site-packages/Cython/Compiler/Nodes.py", line 7026, in generate_execution_code
fresh_finally_clause().generate_execution_code(code)
File "lib/python3.6/site-packages/Cython/Compiler/Nodes.py", line 7013, in fresh_finally_clause
node_copy = copy.deepcopy(node)
File "/home/haypo/prog/python/default/Lib/copy.py", line 182, in deepcopy
y = _reconstruct(x, rv, 1, memo)
(...)
File "/home/haypo/prog/python/default/Lib/copy.py", line 314, in _reconstruct
item = deepcopy(item, memo)
File "/home/haypo/prog/python/default/Lib/copy.py", line 174, in deepcopy
rv = reductor(4)
TypeError: can't pickle Argument objects
---
Argument class indirectly comes from Cython.Compiler.Nodes.ExprStatNode.
Command to reproduce the bug:
---
tar -xf mtrand.tar.gz # download mtrand.tar.gz attached to this issue
python -m venv ENV
ENV/bin/python -m pip install cython
ENV/bin/python ENV/bin/cython --fast-fail -o mtrand.c mtrand.pyx
---
It looks like cython behaviour failed after this change:
---
changeset: 99677:b8d108a2a38e
parent: 99675:80d1faa9735d
parent: 99676:0cd2de69fb66
user: Serhiy Storchaka <storchaka@gmail.com>
date: Fri Dec 25 21:05:35 2015 +0200
files: Lib/test/test_csv.py Misc/NEWS Objects/typeobject.c
description:
Issue #22995: Instances of extension types with a state that aren't
subclasses of list or dict and haven't implemented any pickle-related
methods (__reduce__, __reduce_ex__, __getnewargs__, __getnewargs_ex__,
or __getstate__), can no longer be pickled. Including memoryview.
---
Sorry, I don't understand yet if it's a regression in Python 3.6 or a real bug in Cython. |
|
Date |
User |
Action |
Args |
2016-03-09 16:01:57 | vstinner | set | recipients:
+ vstinner, serhiy.storchaka |
2016-03-09 16:01:57 | vstinner | set | messageid: <1457539317.39.0.81348046338.issue26519@psf.upfronthosting.co.za> |
2016-03-09 16:01:57 | vstinner | link | issue26519 messages |
2016-03-09 16:01:56 | vstinner | create | |
|