On Thursday, January 29, 2015 at 4:39:20 PM UTC-6, Nels Nelson wrote:
>
> On Thursday, January 29, 2015 at 3:41:27 PM UTC-6, Jeremy Evans wrote:
>>
>> Could you try adding the :instance_specific => true option when defining
>> the tags association and see if the problem still occurs?
>>
> Yes, I will definitely try that. Code is running now with those editions.
>
Yes, it still occurs.
I let the program run for 48 hours, and it only occurred once.
In the method which attempts to access thing.tags, I am doing this:
def get_tag_names
log.error "Why is #{self}.tags nil?" if tags.nil?
tags.compact.map(&:to_s)
end
This code gets invoked at least once every second. I may try to invoke it
more often, to see if I can coax the error to occur more frequently.
Oddly, the second tags invocation almost never returns nil, only the first
invocation in the conditional. Of course, without the pre-check for
tags.nil?, that second invocation would fail with a NoMethodError since
NilClass hasn't defined #compact().
I'm not sure why two threads would ever be accessing the same model
instance. Is it possible that a navigation with rcte_tree might return the
exact same object in memory as a different tree navigation in another
thread?
--
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.