From: nobu@... Date: 2015-07-13T14:32:40+00:00 Subject: [ruby-core:69957] [Ruby trunk - Feature #9918] Exception#cause should be shown in output and #inspect Issue #9918 has been updated by Nobuyoshi Nakada. Description updated ---------------------------------------- Feature #9918: Exception#cause should be shown in output and #inspect https://bugs.ruby-lang.org/issues/9918#change-53387 * Author: Benoit Daloze * Status: Open * Priority: Normal * Assignee: ---------------------------------------- Exception#cause has been added in Feature #8257. But the cause is never shown, one needs to inspect exc.cause to know the cause. The cause should be shown by default, for instance: ~~~ruby begin raise "cause" rescue raise "wrapper" end ~~~ Should output: -:4:in `rescue in
': wrapper (RuntimeError) from -:1:in `
' Caused by: -e:1:in `
': org (RuntimeError) And not only the first 2 lines. Logically, #inspect should also include the cause such as: #> What do you think? -- https://bugs.ruby-lang.org/