bugsnag 2.8.8 → 2.8.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 45e5633d92f40d5a0bd96fbf03cbbe5c808ce7ec
4
- data.tar.gz: 4566d88616c540a6d668cf290416869fdc8af516
3
+ metadata.gz: 6a4355f21bf9008d297e35d34cc61f55dc81fa59
4
+ data.tar.gz: e4ec78028b2663e00af67c98f6dc981f1318da20
5
5
  SHA512:
6
- metadata.gz: de54715b8e69a6c6ce464548d46638e5433561373d59e8efb8c2d1a9149bb07e35767c357ad8eee118af34d307a240116b43eb05fd63c452f0e1798204c4e428
7
- data.tar.gz: 7548655948694c82aecdc957639e993526c94cf0b0c64c0f51f6831d17080f076a6429f2d9816a36e62da5da55b2cce6488c2552c5b49b785855f8f920a88343
6
+ metadata.gz: d36182fbcc0795a923fb056a1e73401ba00906efc883b2d2903dd972d43c4b5333a80f926f163df75ef311816493f37a4d942b73030e35db8f398b7be679ed12
7
+ data.tar.gz: 3b3303f7f494422f88482f775b5de0b736e987aaeb62c62310e75c5408058119209286cb7d0868ace835d70fb7a83cd9e745cbfeffe8a54112c1aa7da6480d7d
data/CHANGELOG.md CHANGED
@@ -1,6 +1,11 @@
1
1
  Changelog
2
2
  =========
3
3
 
4
+ 2.8.9
5
+ -----
6
+
7
+ - Remove dependency on `multi_json`, fall back to the `json` gem for Ruby < 1.9
8
+
4
9
  2.8.8
5
10
  -----
6
11
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.8.8
1
+ 2.8.9
data/bugsnag.gemspec CHANGED
@@ -17,7 +17,7 @@ Gem::Specification.new do |s|
17
17
  ]
18
18
  s.require_paths = ["lib"]
19
19
 
20
- s.add_runtime_dependency 'multi_json', ["~> 1.0"]
20
+ s.add_dependency 'json', '~> 1.7', '>= 1.7.7'
21
21
 
22
22
  if RUBY_VERSION < "1.9"
23
23
  s.add_development_dependency "rake", "~> 10.1.1"
@@ -46,15 +46,18 @@ module Bugsnag
46
46
  ].freeze
47
47
 
48
48
  DEFAULT_IGNORE_CLASSES = [
49
- "ActiveRecord::RecordNotFound",
50
- "ActionController::RoutingError",
49
+ "AbstractController::ActionNotFound",
51
50
  "ActionController::InvalidAuthenticityToken",
52
- "CGI::Session::CookieStore::TamperedWithCookie",
51
+ "ActionController::ParameterMissing",
52
+ "ActionController::RoutingError",
53
53
  "ActionController::UnknownAction",
54
- "AbstractController::ActionNotFound",
54
+ "ActionController::UnknownFormat",
55
+ "ActionController::UnknownHttpMethod",
56
+ "ActiveRecord::RecordNotFound",
57
+ "CGI::Session::CookieStore::TamperedWithCookie",
55
58
  "Mongoid::Errors::DocumentNotFound",
59
+ "SignalException",
56
60
  "SystemExit",
57
- "SignalException"
58
61
  ].freeze
59
62
 
60
63
  DEFAULT_IGNORE_USER_AGENTS = [].freeze
@@ -27,7 +27,7 @@ module Bugsnag
27
27
 
28
28
  raise RuntimeError.new("No API key found when notifying of deploy") if !parameters["apiKey"] || parameters["apiKey"].empty?
29
29
 
30
- payload_string = Bugsnag::Helpers.dump_json(parameters)
30
+ payload_string = ::JSON.dump(parameters)
31
31
  Bugsnag::Delivery::Synchronous.deliver(endpoint, payload_string, configuration)
32
32
  end
33
33
  end
@@ -123,22 +123,5 @@ module Bugsnag
123
123
  overrides
124
124
  end
125
125
  end
126
-
127
- # Helper functions to work around MultiJson changes in 1.3+
128
- def self.dump_json(object, options={})
129
- if MultiJson.respond_to?(:adapter)
130
- MultiJson.dump(object, options)
131
- else
132
- MultiJson.encode(object, options)
133
- end
134
- end
135
-
136
- def self.load_json(json, options={})
137
- if MultiJson.respond_to?(:adapter)
138
- MultiJson.load(json, options)
139
- else
140
- MultiJson.decode(json, options)
141
- end
142
- end
143
126
  end
144
127
  end
@@ -1,4 +1,4 @@
1
- require "multi_json"
1
+ require "json"
2
2
 
3
3
  if RUBY_VERSION =~ /^1\.8/
4
4
  begin
@@ -39,10 +39,10 @@ module Bugsnag
39
39
 
40
40
  # If the payload is going to be too long, we trim the hashes to send
41
41
  # a minimal payload instead
42
- payload_string = Bugsnag::Helpers.dump_json(payload)
42
+ payload_string = ::JSON.dump(payload)
43
43
  if payload_string.length > 128000
44
44
  payload[:events].each {|e| e[:metaData] = Bugsnag::Helpers.reduce_hash_size(e[:metaData])}
45
- payload_string = Bugsnag::Helpers.dump_json(payload)
45
+ payload_string = ::JSON.dump(payload)
46
46
  end
47
47
 
48
48
  Bugsnag::Delivery[delivery_method || configuration.delivery_method].deliver(url, payload_string, configuration)
@@ -268,7 +268,7 @@ describe Bugsnag::Notification do
268
268
  expect(Bugsnag).to have_sent_notification{ |payload|
269
269
  # Truncated body should be no bigger than
270
270
  # 2 truncated hashes (4096*2) + rest of payload (20000)
271
- expect(Bugsnag::Helpers.dump_json(payload).length).to be < 4096*2 + 20000
271
+ expect(::JSON.dump(payload).length).to be < 4096*2 + 20000
272
272
  }
273
273
  end
274
274
 
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bugsnag
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.8.8
4
+ version: 2.8.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Smith
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-16 00:00:00.000000000 Z
11
+ date: 2015-07-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: multi_json
14
+ name: json
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.0'
19
+ version: '1.7'
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 1.7.7
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
27
  - - "~>"
25
28
  - !ruby/object:Gem::Version
26
- version: '1.0'
29
+ version: '1.7'
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 1.7.7
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: rake
29
35
  requirement: !ruby/object:Gem::Requirement