Ticket #333 (assigned defect)

Opened 13 months ago

Last modified 12 months ago

Ferret segfaults when specific method is called on a LazyDoc

Reported by: ej.finneran@… Owned by: dbalmain
Priority: major Milestone:
Component: component1 Version:
Keywords: Cc:

Description

I have a ContentTranslation? model that I index via acts_as_ferret in rails.

If I call this: ContentTranslation?.query("class_name:ArticleTranslation").first.first[:brand_guid]

it returns the proper field fine. Calling this: ContentTranslation?.query("class_name:ArticleTranslation").first.first[:master_brand_guid]

segfaults ruby. Both are indexed fields of the model so I don't know why one fails and the other doesn't. I've included a backtrace using gdb on Linux.

Attachments

backtrace.txt (6.8 KB) - added by ej.finneran@… 13 months ago.
backtace of the segfault
example_test.rb (320 bytes) - added by dbalmain 12 months ago.
A sample test to play around with to try to reproduce the error.

Change History

Changed 13 months ago by ej.finneran@…

backtace of the segfault

Changed 13 months ago by dbalmain

  • owner changed from somebody to dbalmain
  • status changed from new to assigned

Hey, I can't work out what is going wrong from the stack trace. I've attached a sample test file. If you could modify it to reproduce the problem that would be great. Otherwise, if you could email me your index (dbalmain@…) I might be able to work out the problem from there.

Changed 12 months ago by ej.finneran@…

I don't see a sample test attached to this bug. Could you attach it here or email it to me? ej.finneran@…

Thanks.

Changed 12 months ago by anonymous

After some experimenting, I found one thing that might be of use: If I add the fields that cause the segfault to the list of lazy loading fields, it no longer segfaults. So it seems like the pattern is fields that aren't actually columns in the database but rather the output of instance methods that are not listed as lazy loading fields cause a segfault.

I'll also run that test once I get it.

Changed 12 months ago by dbalmain

A sample test to play around with to try to reproduce the error.

Add/Change #333 (Ferret segfaults when specific method is called on a LazyDoc)

Author



Change Properties
<Author field>
Action
as assigned
as The resolution will be set. Next status will be 'closed'
to The owner will change from dbalmain. Next status will be 'new'
 
Note: See TracTickets for help on using tickets.