Issue1323
Created on 2009-04-22.12:30:55 by MrMeanie, last changed 2014-05-22.02:10:16 by zyasoft.
msg4566 (view) |
Author: Geoffrey French (MrMeanie) |
Date: 2009-04-22.12:30:54 |
|
In Python code, create some Java objects (eg java.awt.Color). Place them
in a python list.
Pass this list as a parameter to a method of a Java object (as a
java.util.list), which iterates over the contents of the list, using an
iterator obtained from the iterator() method.
The objects received by the Java code are not unwrapped; you get
PyObjectDerived instances.
Problem:
The PyList.iterator() method returns an iterator obtained from the
underlying list. This is different from the implementation of
PyList.listIterator() which wraps the underlying iterator so that value
objects are wrapped and unwrapped as appropriate.
|
msg4567 (view) |
Author: Geoffrey French (MrMeanie) |
Date: 2009-04-22.12:43:16 |
|
Please find attached a unit test to demonstrate this bug.
A list of Java objects, created in Python, is passed to a java method,
which returns a list of their class names; this can be checked.
|
msg4568 (view) |
Author: Geoffrey French (MrMeanie) |
Date: 2009-04-22.12:48:06 |
|
Please find attached a patch that fixes this issue, by modifying the
PyList.iterator() method.
This patch also enhances Lib/test/test_java_list_delegate.py, so that test
failures give more info about the cause of the failure.
|
msg4580 (view) |
Author: Jim Baker (zyasoft) |
Date: 2009-04-23.07:40:20 |
|
Fixed in r6257, pending until a suitable unit test is added (something
based on the attached test should be fine).
|
msg4669 (view) |
Author: Jim Baker (zyasoft) |
Date: 2009-05-10.20:05:01 |
|
Changing to normal (not blocking RC), we have a couple of possible tests
here from MrMeanie, Josh Juneau, just need to integrate into regrtest
|
msg8551 (view) |
Author: Jim Baker (zyasoft) |
Date: 2014-05-22.02:10:16 |
|
This has been pending for the last 5 years. Someone should close it out :)
Apparently the test patch submitted by MrMeanie was applied as part of the overall fix in 6031:1890b51547ed
|
|
Date |
User |
Action |
Args |
2014-05-22 02:10:16 | zyasoft | set | status: pending -> closed messages:
+ msg8551 |
2013-02-26 19:09:12 | fwierzbicki | set | versions:
+ Jython 2.5, - 25rc4 |
2009-08-05 21:31:10 | fwierzbicki | set | nosy:
+ fwierzbicki |
2009-05-10 20:05:01 | zyasoft | set | priority: high -> normal messages:
+ msg4669 |
2009-04-23 07:40:32 | zyasoft | set | priority: high |
2009-04-23 07:40:22 | zyasoft | set | status: open -> pending assignee: zyasoft resolution: fixed messages:
+ msg4580 nosy:
+ zyasoft |
2009-04-22 12:48:07 | MrMeanie | set | files:
+ Issue1323_list_iterator_fix_v1_20090422.patch keywords:
+ patch messages:
+ msg4568 |
2009-04-22 12:43:16 | MrMeanie | set | files:
+ Bug1323_test_20090422.zip messages:
+ msg4567 |
2009-04-22 12:30:55 | MrMeanie | create | |
|