commit 893f66f0601c415f5daee95eda8835eb2b31d5f3
parent b0c19ff7d2b7fa706a078c83b478f107b2a09e9f
Author: Gaute Hope <eg@gaute.vetsj.com>
Date: Wed, 17 Sep 2014 09:38:09 +0200
message: output message id and locations on all exceptions when loading message
Diffstat:
1 file changed, 8 insertions(+), 0 deletions(-)
diff --git a/lib/sup/message.rb b/lib/sup/message.rb
@@ -268,6 +268,14 @@ class Message
debug "could not load message: #{location.inspect}, exception: #{e.inspect}"
[Chunk::Text.new(error_message.split("\n"))]
+
+ rescue Exception => e
+
+ warn "problem reading message #{id}"
+ debug "could not load message: #{location.inspect}, exception: #{e.inspect}"
+
+ raise e
+
end
end