diff --git a/kernel/common/exception.rb b/kernel/common/exception.rb index 3744a5479a..3ebcbec211 100644 --- a/kernel/common/exception.rb +++ b/kernel/common/exception.rb @@ -10,6 +10,16 @@ def initialize(message = nil) @custom_backtrace = nil end + # This is here rather than in yaml.rb because it contains "private" + # information, ie, the list of ivars. Putting it over in the yaml + # sounce means it's easy to forget about. + def to_yaml_properties + list = super + list.delete "@backtrace" + list.delete "@custom_backtrace" + return list + end + def message @reason_message end