Message12914
I have stumbled into a test that reasonably-well reproduces what I think is the original problem. I have a test resembling:
from javax.swing.text.Utilities import *
f = getNextWord # May raise NameError
If I invoke this simultaneously from 100 threads, it fails just occasionally.
I attempted to disturb the timing, hoping for more frequent failures, by adding a sleep:
from java.lang import Thread
Thread.sleep(instance*10) # May raise AttributeError
from javax.swing.text.Utilities import *
f = getNextWord # May raise NameError
This second one fails about one time in five, claiming Thread has no sleep. I suspect it is a cache problem, not a construction one, but I don't understand how it arises.
The problem I found 27/12 (that the cache produces classes that originate in the wrong class loader) is real, and I have a test that fails every time, but I think it is not the one reported. |
|
Date |
User |
Action |
Args |
2020-01-24 07:42:02 | jeff.allen | set | messageid: <1579851722.52.0.891540872087.issue2834@roundup.psfhosted.org> |
2020-01-24 07:42:02 | jeff.allen | set | recipients:
+ jeff.allen, zyasoft, FraOrolo |
2020-01-24 07:42:02 | jeff.allen | link | issue2834 messages |
2020-01-24 07:42:02 | jeff.allen | create | |
|