Issue2015

classification
Title: returning itertools.imap() from __iter__ method no longer works
Type: behaviour Severity: normal
Components: Library Versions: Jython 2.7
process
Status: closed Resolution: duplicate
Dependencies: Superseder:
Assigned To: fwierzbicki Nosy List: dsh, fwierzbicki, zyasoft
Priority: high Keywords:

Created on 2013-02-16.20:46:21 by dsh, last changed 2014-06-25.16:05:34 by zyasoft.

Files
File name Uploaded Description Edit Remove
minimal-example.py dsh, 2013-02-16.20:46:20
Messages
msg7688 (view) Author: (dsh) Date: 2013-02-16.20:46:20
In Jython 2.5 and CPython 2.7, a class' __iter__ method can return itertools.imap(f, l) and this object can be processed in a for loop.  In Jython 2.7 the loop does not execute any iterations.  The attached script demonstrates this (and is also compatible with CPython 3 for comparison there).
msg7689 (view) Author: Frank Wierzbicki (fwierzbicki) Date: 2013-02-17.19:48:54
Ouch, thanks for the bug report!
msg8528 (view) Author: Jim Baker (zyasoft) Date: 2014-05-22.00:54:57
Target beta 4

We are still seeing this problem. We should add a variant of the minimal-example.py test to what should be test_itertools_jy.py
msg8652 (view) Author: Jim Baker (zyasoft) Date: 2014-06-17.02:23:52
Duplicate of #1935
msg8653 (view) Author: Jim Baker (zyasoft) Date: 2014-06-17.02:24:43
Make that a duplicate of #1991

(Perhaps fixing #1935 inadvertently introduced this issue.)
msg8659 (view) Author: Jim Baker (zyasoft) Date: 2014-06-17.22:57:41
I added a test for itertools.imap as part of testing the fix in #1991.
History
Date User Action Args
2014-06-25 16:05:34zyasoftsetstatus: pending -> closed
2014-06-17 22:57:41zyasoftsetmessages: + msg8659
2014-06-17 22:56:42zyasoftsetstatus: open -> pending
2014-06-17 02:24:44zyasoftsetmessages: + msg8653
2014-06-17 02:23:53zyasoftsetresolution: accepted -> duplicate
messages: + msg8652
2014-05-22 00:54:57zyasoftsetresolution: accepted
messages: + msg8528
nosy: + zyasoft
2013-02-20 00:28:40fwierzbickisetversions: + Jython 2.7, - 2.7a2
2013-02-17 19:48:54fwierzbickisetpriority: high
assignee: fwierzbicki
messages: + msg7689
nosy: + fwierzbicki
2013-02-16 20:46:21dshcreate