I need to get a stack trace object in Ruby; not to print it, just to get it to do some recording and dumping for later analysis. Is that possible? How?
Try
Thread.current.backtrace.join("\n")