Skip to content

Commit a02b881

Browse files
iloveitalyHazAT
authored andcommitted
Only warn for 4xx errors from sentry. Fixes #644 (#862)
1 parent d9f44cd commit a02b881

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/raven/client.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,11 +102,11 @@ def successful_send
102102
def failed_send(e, event)
103103
@state.failure
104104
if e # exception was raised
105-
configuration.logger.error "Unable to record event with remote Sentry server (#{e.class} - #{e.message}):\n#{e.backtrace[0..10].join("\n")}"
105+
configuration.logger.warn "Unable to record event with remote Sentry server (#{e.class} - #{e.message}):\n#{e.backtrace[0..10].join("\n")}"
106106
else
107-
configuration.logger.error "Not sending event due to previous failure(s)."
107+
configuration.logger.warn "Not sending event due to previous failure(s)."
108108
end
109-
configuration.logger.error("Failed to submit event: #{get_log_message(event)}")
109+
configuration.logger.warn("Failed to submit event: #{get_log_message(event)}")
110110
configuration.transport_failure_callback.call(event) if configuration.transport_failure_callback
111111
end
112112
end

0 commit comments

Comments
 (0)