[pylucene-dev] ArrayIndexOutOfBoundsException with Field.TermVector.WITH_OFFSETS

Steven Bethard steven.bethard at gmail.com
Tue Aug 29 15:25:43 PDT 2006


On 8/18/06, Steven Bethard <steven.bethard at gmail.com> wrote:
> On 8/18/06, Andi Vajda <vajda at osafoundation.org> wrote:
> >
> > On Thu, 17 Aug 2006, Steven Bethard wrote:
> >
> > > I'm getting ArrayIndexOutOfBoundsExceptions thrown whenever I use
> > > Field.TermVector.WITH_OFFSETS, Field.TermVector.WITH_POSITIONS or
> > > Field.TermVector.WITH_POSITIONS_OFFSETS, though the errors show up
> > > somewhat sporadically.  Here's an interactive session where I was able
> > > to provoke one:
> >
> > Given that the error seems to come from inside Java Lucene, it could be
> > either:
> >    - a gcj compilation error: please give us your gcj version and OS details
>
> Sorry, should've included that the first time:
>
> Red Hat Enterprise Linux WS release 3 (Taroon Update 8)
> gcj (GCC) 3.4.4
> Python 2.4.3

For anyone else who runs into this, there was a bug in libgcj that was causing
PyLucene to fail whenever java garbage collection was instigated. When PyLucene
was rebuilt with the patched libgcj, the problems went away.  Here's
the details:

$ ./gcj -v
Using built-in specs.
Reading specs from
/usr/local/gcc/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../libgcj.spec
rename spec lib to liborig
Target: i686-pc-linux-gnu
Configured with: ./configure --disable-nls --disable-shared
--prefix=/usr/local/gcc --
with-as=/usr/local/gcc/bin/as --with-gnu-as --with-gnu-ld
--with-ld=/usr/local/gcc/bin
/ld
Thread model: posix
gcc version 4.1.1

The patch applied before rebuilding gcc 4.1.1 was:

http://gcc.gnu.org/bugzilla/attachment.cgi?id=11161

Hope that helps!

Steve
-- 
I'm not *in*-sane. Indeed, I am so far *out* of sane that you appear a
tiny blip on the distant coast of sanity.
        --- Bucky Katt, Get Fuzzy


More information about the pylucene-dev mailing list