Undefined method 'to_doc' for Ferret

Hi,
Sporadically I am getting the following error:

NoMethodError (undefined method to_doc' for #<Ferret::Document:0xb71c9724>): (druby://localhost:9010) /usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li b/local_index.rb:153:inadd’
(druby://localhost:9010)
/usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li
b/ferret_server.rb:102:in method_missing' (druby://localhost:9010) /usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li b/ferret_server.rb:170:inreconnect_when_needed’
(druby://localhost:9010)
/usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li
b/ferret_server.rb:97:in method_missing' (druby://localhost:9010) /usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li b/ferret_server.rb:164:inwith_class’
(druby://localhost:9010)
/usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li
b/ferret_server.rb:96:in method_missing' (druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1552:inperform_witho
ut_block’
(druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1512:in
perform' (druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1586:inmain_loop’
(druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1582:in
main_loop' (druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1578:inmain_loop’
(druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1427:in run' (druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1424:inrun’
(druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1344:in
initialize' (druby://localhost:9010) /usr/lib/ruby/1.8/drb/drb.rb:1624:instart_service

(druby://localhost:9010)
/usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li
b/ferret_server.rb:79:in start' (druby://localhost:9010) /usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li b/unix_daemon.rb:18:inplatform_daemon’
(druby://localhost:9010)
/usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li
b/unix_daemon.rb:41:in safefork' (druby://localhost:9010) /usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li b/unix_daemon.rb:11:inplatform_daemon’
(druby://localhost:9010)
/usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li
b/ferret_server.rb:77:in start' (druby://localhost:9010) /usr/lib/ruby/gems/1.8/gems/acts_as_ferret-0.4.3/li b/server_manager.rb:41 (druby://localhost:9010) /usr/local/lib/site_ruby/1.8/rubygems/custom_requir e.rb:27:inrequire’

And then if I work on something else, the error goes away. I think it
has to do with the database that Ferret creates to do its searches
getting
corrupted.
Does anyone know what is causing this error and how to fix it?

Thanks,

Jim