From abe57873db6d519190ff3570fa3c8705f33e2656 Mon Sep 17 00:00:00 2001 From: Sojan Jose Date: Tue, 14 Mar 2023 17:40:40 +0530 Subject: [PATCH] chore: Disable throwing Webhook exceptions to Sentry (#6663) - There is little value in throwing the third-party webhook-related exceptions to sentry. Let's rather write it to logs instead. --- lib/webhooks/trigger.rb | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/webhooks/trigger.rb b/lib/webhooks/trigger.rb index 517f6862a..228d34b7f 100644 --- a/lib/webhooks/trigger.rb +++ b/lib/webhooks/trigger.rb @@ -7,10 +7,7 @@ class Webhooks::Trigger timeout: 5 ) Rails.logger.info "Performed Request: Code - #{response.code}" - rescue *ExceptionList::REST_CLIENT_EXCEPTIONS, URI::InvalidURIError => e - Rails.logger.error "Exception: invalid webhook url #{url} : #{e.message}" rescue StandardError => e - Rails.logger.error "Exception: invalid webhook url #{url} : #{e.message}" - ChatwootExceptionTracker.new(e).capture_exception + Rails.logger.warn "Exception: invalid webhook url #{url} : #{e.message}" end end