Permalink
Browse files

plugin errors are now reported to scout server as errors

  • Loading branch information...
1 parent 21b1e4e commit 53cc1ad60df476387d970e012e0466b41923b96c Andre Lewis committed Dec 10, 2009
Showing with 5 additions and 1 deletion.
  1. +5 −1 lib/scout/server.rb
View
@@ -188,6 +188,7 @@ def process_plugin(plugin)
rescue Exception
raise if $!.is_a? SystemExit
error "Plugin would not compile: #{$!.message}"
+ @checkin[:errors] << build_report(plugin['id'],:subject => "Plugin would not compile", :body=>$!.message)
return
end
debug "Loading plugin..."
@@ -209,6 +210,9 @@ def process_plugin(plugin)
raise if $!.is_a? SystemExit
error "Plugin failed to run: #{$!.class}: #{$!.message}\n" +
"#{$!.backtrace.join("\n")}"
+ @checkin[:errors] << build_report(plugin['id'],
+ :subject => "Plugin failed to run",
+ :body=>"#{$!.class}: #{$!.message}\n#{$!.backtrace.join("\n")}")
end
info "Plugin completed its run."
@@ -230,7 +234,7 @@ def process_plugin(plugin)
@history["memory"][id_and_name] = data[:memory]
else
@checkin[:errors] << build_report(
- plugin_id['id'],
+ plugin['id'],
:subject => "Plugin would not load."
)
end

0 comments on commit 53cc1ad

Please sign in to comment.