views:

62

answers:

1

I've got code which produces a stack trace at some point:

fileA.rb:1670:in `flow_completed_for'
(eval):58:in `on_success_res_for_register'
fileB:312:in `send'
fileC:312:in `request_specific_response_dispatch'
...

How can I find the source where on_success_res_for_register was defined? The code is called from some timer and I have problems localising the function code. Is there any way I can get the source of that command?

Also - is such stacktrace line generated only by eval(), or is it possible in some other way (some side effects of send()? or something catching all method calls?)

+1  A: 

That means the method was created by eval, so it doesn't have a file associated with it. Your best bet is just to grep for "def flow_completed_for".

Chuck