Bill Janssen <jans...@parc.com> wrote: > What's crashing with PyLucene 2.9.3 is this code: > > for field in x.getFields(): > > where "x" is an instance of org.apache.lucene.document.Document. I can > print x and it looks OK, but an attempt to iterate over the list of > fields seems broken. Is this another iterator change?
I see that I also can't iterate over x.getFields().listIterator(), presumably because, in the Java 1.4 that Lucene 2.9.x uses, java.util.Iterator doesn't "implement" java.lang.Iterable. A tad ridiculous. Certainly java.util.List should be a sequence of some sort. Bill > > Bill > > Thread 14 Crashed: > 0 libjvm.dylib 0x0198a1cb 0x18e7000 + 668107 > 1 libjvm.dylib 0x01af5c47 JNI_CreateJavaVM_Impl + 96759 > 2 libjcc.dylib 0x007a168d > JCCEnv::callObjectMethod(_jobject*, _jmethodID*, ...) const + 73 > 3 libjcc.dylib 0x007a1254 JCCEnv::iterator(_jobject*) > const + 34 > 4 _lucene.so 0x013c0e83 _object* > get_iterator<java::util::t_List>(java::util::t_List*) + 59 > 5 org.python.python 0x00121dfd PyObject_GetIter + 107