Hi.

We had some empty fields in our records and they caused an error which
I tracked down in search_engine.search_pattern. The problem is that
when searching with an empty search string, search_pattern returns an
infinite bitset. And Python is unable to iterate over such a bitset.

In [1]: from invenio.intbitset import intbitset

In [2]: for i in intbitset(trailing_bits=1):
   ...:     print i
   ...:
   ...:
---------------------------------------------------------------------------
OverflowError                             Traceback (most recent call last)

/home/bthiell/src/invenio/<ipython console>

/usr/lib64/python2.4/site-packages/invenio/intbitset.so in
lib.intbitset.intbitset.__iter__ (intbitset.c:5172)()

OverflowError: It's impossible to iterate over an infinite set.


This caused an error for us in search_engine_summarizer.get_coauthors
when we encountered an empty author field. We cleaned our record but
the problem should also be fixed in the code.

Cheers.

-- 
Benoit Thiell
The SAO/NASA Astrophysics Data System
http://adswww.harvard.edu/

Reply via email to