Enable errbit/hoptoad, update rake
This commit is contained in:
parent
2831ccdde0
commit
4592802411
4 changed files with 35 additions and 1 deletions
|
|
@ -5,6 +5,9 @@ defaults: &defaults
|
|||
url_for_emails: localhost:3000
|
||||
# A secret key. You can generate one with 'rake secret'
|
||||
devise_secret_key: 12345
|
||||
# errbit configuration, get your own instance: https://github.com/errbit/errbit
|
||||
#errbit_key: 123456789101112131415
|
||||
#errbit_host: errbit.exmaple.com
|
||||
|
||||
development:
|
||||
<<: *defaults
|
||||
|
|
|
|||
24
config/initializers/hoptoad.rb
Normal file
24
config/initializers/hoptoad.rb
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
HoptoadNotifier.configure do |config|
|
||||
# Change this to some sensible data for your errbit instance
|
||||
config.api_key = CONFIG["errbit_key"] || ""
|
||||
config.host = CONFIG["errbit_host"] || ""
|
||||
if config.api_key.blank? || config.host.blank?
|
||||
config.development_environments = "production development test"
|
||||
else
|
||||
config.development_environments = "development test"
|
||||
end
|
||||
|
||||
config.ignore_only = %w{
|
||||
Some::ExceptionName
|
||||
}
|
||||
|
||||
config.ignore_by_filter do |exception_data|
|
||||
ret=false
|
||||
if exception_data[:error_class] == "ActionController::RoutingError"
|
||||
message = exception_data[:error_message]
|
||||
ret=true if message =~ %r{\[GET\]}
|
||||
end
|
||||
ret
|
||||
end
|
||||
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue