bugsnag 2.2.1 → 2.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +4 -3
- data/VERSION +1 -1
- data/lib/bugsnag/configuration.rb +3 -1
- data/lib/bugsnag/notification.rb +6 -5
- data/lib/bugsnag/rails/active_record_rescue.rb +3 -1
- data/spec/notification_spec.rb +11 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 786c9d4bd2e5d01b21f0d16ed3740b8144b7d0ff
|
4
|
+
data.tar.gz: 090f55203be5aacae94f59ccbdb5b726b1ed47a4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c8448332a6ffc15e5d12791fa5dbb31c65f3b031e38d0756bc502a866fb4b3e64cc4fd79c23645fa367baf1c85d7e61020639c879795c28685c330ef04f66ff
|
7
|
+
data.tar.gz: 9754284692feff0ed1bee0b61ecace287642e7437295d60a17d5d78e37d75c9c2ea4b1abde8220d45ee33868c5c108ca8f8b675a26c91a5f613e791c034da883
|
data/CHANGELOG.md
CHANGED
@@ -1,8 +1,14 @@
|
|
1
1
|
Changelog
|
2
2
|
=========
|
3
3
|
|
4
|
+
2.2.2
|
5
|
+
-----
|
6
|
+
- Add additional ignored classes
|
7
|
+
- Check all chained exceptions on an error for ignored classes
|
8
|
+
|
4
9
|
2.2.1
|
5
10
|
-----
|
11
|
+
- Fix occasional crash when reading rack params.
|
6
12
|
- Don't strip files with bugsnag in the name.
|
7
13
|
|
8
14
|
2.2.0
|
data/README.md
CHANGED
@@ -117,7 +117,8 @@ end
|
|
117
117
|
|
118
118
|
In other ruby apps, you can provide lambda functions to execute before any
|
119
119
|
`Bugsnag.notify` calls as follows. Don't forget to clear the callbacks at the
|
120
|
-
end of each request or session.
|
120
|
+
end of each request or session. In Rack applications like Sinatra, however, the
|
121
|
+
gem will clear the callbacks for you.
|
121
122
|
|
122
123
|
```ruby
|
123
124
|
# Set a before notify callback
|
@@ -628,8 +629,8 @@ to those projects.
|
|
628
629
|
Demo Applications
|
629
630
|
-----------------
|
630
631
|
|
631
|
-
[There are demo applications that use the Bugsnag Ruby gem](https://github.com/bugsnag/bugsnag-example-apps/tree/master/ruby):
|
632
|
-
examples include Rails, Sinatra, Padrino integrations, etc.
|
632
|
+
[There are demo applications that use the Bugsnag Ruby gem](https://github.com/bugsnag/bugsnag-example-apps/tree/master/apps/ruby):
|
633
|
+
examples include Rails, Sinatra, Rack, Padrino integrations, etc.
|
633
634
|
|
634
635
|
Reporting Bugs or Feature Requests
|
635
636
|
----------------------------------
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.2.
|
1
|
+
2.2.2
|
@@ -42,7 +42,9 @@ module Bugsnag
|
|
42
42
|
"CGI::Session::CookieStore::TamperedWithCookie",
|
43
43
|
"ActionController::UnknownAction",
|
44
44
|
"AbstractController::ActionNotFound",
|
45
|
-
"Mongoid::Errors::DocumentNotFound"
|
45
|
+
"Mongoid::Errors::DocumentNotFound",
|
46
|
+
"SystemExit",
|
47
|
+
"SignalException"
|
46
48
|
].freeze
|
47
49
|
|
48
50
|
DEFAULT_IGNORE_USER_AGENTS = [].freeze
|
data/lib/bugsnag/notification.rb
CHANGED
@@ -284,12 +284,13 @@ module Bugsnag
|
|
284
284
|
private
|
285
285
|
|
286
286
|
def ignore_exception_class?
|
287
|
-
|
288
|
-
|
289
|
-
|
287
|
+
@exceptions.any? do |ex|
|
288
|
+
ex_name = error_class(ex)
|
289
|
+
ancestor_chain = ex.class.ancestors.select { |ancestor| ancestor.is_a?(Class) }.map { |ancestor| error_class(ancestor) }.to_set
|
290
290
|
|
291
|
-
|
292
|
-
|
291
|
+
@configuration.ignore_classes.any? do |to_ignore|
|
292
|
+
to_ignore.is_a?(Proc) ? to_ignore.call(ex) : ancestor_chain.include?(to_ignore)
|
293
|
+
end
|
293
294
|
end
|
294
295
|
end
|
295
296
|
|
data/spec/notification_spec.rb
CHANGED
@@ -502,6 +502,17 @@ describe Bugsnag::Notification do
|
|
502
502
|
Bugsnag.notify_or_ignore(BugsnagSubclassTestException.new("It crashed"))
|
503
503
|
end
|
504
504
|
|
505
|
+
it "does not notify if any caused exception is an ignored class" do
|
506
|
+
Bugsnag.configuration.ignore_classes << "NestedException"
|
507
|
+
|
508
|
+
ex = NestedException.new("Self-referential exception")
|
509
|
+
ex.original_exception = BugsnagTestException.new("It crashed")
|
510
|
+
|
511
|
+
expect(Bugsnag::Notification).not_to receive(:deliver_exception_payload)
|
512
|
+
|
513
|
+
Bugsnag.notify_or_ignore(ex)
|
514
|
+
end
|
515
|
+
|
505
516
|
it "accepts both String and Class instances as an ignored class" do
|
506
517
|
Bugsnag.configuration.ignore_classes << BugsnagTestException
|
507
518
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bugsnag
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.2.
|
4
|
+
version: 2.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Smith
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: multi_json
|