Issue #95 resolved

KeyError on delete_document

Lukasz Dziedzia
created an issue

Hi guys,

I have a site which uses django haystack+whoosh. And a following problem: I have a cron job which updates whoosh index by update_index command from django-haystack. It is OK when run for the first and second time but when update_index is executed once again I always see this error in my logs:

File "/.../Whoosh-1.5.0-py2.6.egg/whoosh/filedb/fileindex.py", line 445, in delete_document % (docnum, self.name))

KeyError: "Document 1 in segment '_MAIN_1' is already deleted"

Help is much appreciated. I know this is caused by django-haystack but last error comes from whoosh and that's why I have decided to post this issue here.

Comments (4)

  1. Matt Chaput repo owner

    I think this should not have raised an exception. I've removed the exception raising code. Could you please try again with Whoosh 1.5.3? Thanks!

  2. Log in to comment