From: Vladimir Sizikov Date: 2008-02-19T04:30:32+09:00 Subject: Different stacktraces in 1.8 and 1.9 Hi, I'm writing some regression tests for JRuby, to make sure we provide as close stacktraces to MRI as possible, but it seems that most of my tests written with MRI 1.8 in mind, while passing 100% with MRI 1.8.6, all fail with MRI 1.9. So I'd like to double-check with core team on this one. 1. 1/0 It was producing nice stack trace in MRI 1.8.6: ZeroDivisionError: divided by 0 from (irb):1:in `/' from (irb):1 In MRI 1.9 the stack trace don't even mention the method name! ZeroDivisionError: divided by 0 from (irb):1 from /opt/ruby1.9/lib/ruby/1.9.0/irb.rb:149:in `block (2 levels) in eval_input' from /opt/ruby1.9/lib/ruby/1.9.0/irb.rb:262:in `signal_status' from /opt/ruby1.9/lib/ruby/1.9.0/irb.rb:146:in `block in eval_input' If invoked not from irb, but from a script file, the method name still is not reported: div.rb:1:in `
': divided by 0 (ZeroDivisionError). MRI 1.8.6 produces better output in such case: div.rb:1:in `/': divided by 0 (ZeroDivisionError) from div.rb:1 2. raise RuntimeError, "heh" In MRI 1.8: RuntimeError: heh from (irb):2 In MRI 1.9, one extra line is reported: RuntimeError: heh from (irb):3:in `raise' from (irb):3 Is it really needed to have the extra line with `raise'? Thanks, --Vladimir