mirror of
https://github.com/czhu12/canine.git
synced 2025-12-19 09:49:58 -06:00
Merge pull request #455 from CanineHQ/chriszhu__clean_errors
clean up errors in sentry
This commit is contained in:
@@ -2,5 +2,6 @@ if ENV['SENTRY_DSN'].present?
|
|||||||
Sentry.init do |config|
|
Sentry.init do |config|
|
||||||
config.dsn = ENV['SENTRY_DSN']
|
config.dsn = ENV['SENTRY_DSN']
|
||||||
config.breadcrumbs_logger = [ :active_support_logger, :http_logger ]
|
config.breadcrumbs_logger = [ :active_support_logger, :http_logger ]
|
||||||
|
config.excluded_exceptions += [ 'ActionDispatch::RemoteIp::IpSpoofAttackError' ]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ module Portainer
|
|||||||
end
|
end
|
||||||
rescue Socket::ResolutionError
|
rescue Socket::ResolutionError
|
||||||
raise ConnectionError, "Portainer URL is not resolvable"
|
raise ConnectionError, "Portainer URL is not resolvable"
|
||||||
rescue Net::ReadTimeout
|
rescue Net::ReadTimeout, Net::OpenTimeout
|
||||||
raise ConnectionError, "Connection to Portainer timed out"
|
raise ConnectionError, "Connection to Portainer timed out"
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -131,7 +131,7 @@ module Portainer
|
|||||||
end
|
end
|
||||||
rescue Socket::ResolutionError
|
rescue Socket::ResolutionError
|
||||||
raise ConnectionError, "Portainer URL is not resolvable"
|
raise ConnectionError, "Portainer URL is not resolvable"
|
||||||
rescue Net::ReadTimeout
|
rescue Net::ReadTimeout, Net::OpenTimeout
|
||||||
raise ConnectionError, "Connection to Portainer timed out"
|
raise ConnectionError, "Connection to Portainer timed out"
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -141,7 +141,7 @@ module Portainer
|
|||||||
end
|
end
|
||||||
rescue Socket::ResolutionError
|
rescue Socket::ResolutionError
|
||||||
raise ConnectionError, "Portainer URL is not resolvable"
|
raise ConnectionError, "Portainer URL is not resolvable"
|
||||||
rescue Net::ReadTimeout
|
rescue Net::ReadTimeout, Net::OpenTimeout
|
||||||
raise ConnectionError, "Connection to Portainer timed out"
|
raise ConnectionError, "Connection to Portainer timed out"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user