honeybadger 4.5.5 → 4.5.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d10b44dcc496d25ac018e8b636886a72bf143ab354a63e65f72a01ac93012c48
4
- data.tar.gz: 823b72ff2411d1432eef6a7350b1f0eea6b0419a75e76c978ac4c4fa517b0444
3
+ metadata.gz: baff304bc3d7912d3643efbc651829441b80b52d7a48d8c2ecb7bc9ab35aac81
4
+ data.tar.gz: 3892040a92da339c9f41960c61a2ad30d16597f984f630e595cc2b9fd1c7e31a
5
5
  SHA512:
6
- metadata.gz: fac043a475c0bec627d4596e9668a05abdb32da750cfa77d5c2bd1e2d9abce479f7d3a1126c7ac8ff09edec7bec3a03c4ad70b728d643617ad7712647cd2f424
7
- data.tar.gz: 302b5d830b45cb93b0592aee5d8d75ad33af920b3e020746ba881dfa8392ac324ebe60b681b970c9e05eb36b5c2dbe3de3f67701a9a7c12f3c9a4c9424b8a7cd
6
+ metadata.gz: e29645665a943c5e9055bd0ecd481f289ffb230c113a776311317b6d3ce65f6003bfa0cc7dd2e7461b1ca0b226e36fa73288d27dda124832051b059d090ef7e5
7
+ data.tar.gz: 834c71bf1fd0d35512025d73c39485bb95fb513001acec616c342d2a4a42b4c297690415c2a2e4e00098f4d890646bc0427ff4b6f05552d94e44f77de7e6894c
@@ -5,6 +5,10 @@ adheres to [Semantic Versioning](http://semver.org/).
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [4.5.6] - 2020-01-08
9
+ ### Fixed
10
+ - Fix remaining Ruby 2.7 deprecation warnings
11
+
8
12
  ## [4.5.5] - 2020-01-06
9
13
  ### Fixed
10
14
  - Replace empty `Proc.new` with explicit block param to suppress warnings
@@ -278,7 +278,7 @@ module Honeybadger
278
278
  metadata: metadata
279
279
  })
280
280
 
281
- breadcrumbs.add!(Breadcrumbs::Breadcrumb.new(params))
281
+ breadcrumbs.add!(Breadcrumbs::Breadcrumb.new(**params))
282
282
 
283
283
  self
284
284
  end
@@ -42,6 +42,10 @@ module Honeybadger
42
42
  # @api private
43
43
  MAX_EXCEPTION_CAUSES = 5
44
44
 
45
+ # @api private
46
+ # Binding#source_location was added in Ruby 2.6.
47
+ BINDING_HAS_SOURCE_LOCATION = Binding.method_defined?(:source_location)
48
+
45
49
  class Notice
46
50
  extend Forwardable
47
51
 
@@ -444,7 +448,13 @@ module Honeybadger
444
448
  return {} if exception.__honeybadger_bindings_stack.empty?
445
449
 
446
450
  if config[:root]
447
- binding = exception.__honeybadger_bindings_stack.find { |b| b.eval('__FILE__') =~ /^#{Regexp.escape(config[:root].to_s)}/ }
451
+ binding = exception.__honeybadger_bindings_stack.find { |b|
452
+ if BINDING_HAS_SOURCE_LOCATION
453
+ b.source_location[0]
454
+ else
455
+ b.eval('__FILE__')
456
+ end =~ /^#{Regexp.escape(config[:root].to_s)}/
457
+ }
448
458
  end
449
459
 
450
460
  binding ||= exception.__honeybadger_bindings_stack[0]
@@ -187,7 +187,7 @@ module Honeybadger
187
187
 
188
188
  def valid_encoding(string)
189
189
  return string if valid_encoding?(string)
190
- string.encode(Encoding::UTF_8, ENCODE_OPTS)
190
+ string.encode(Encoding::UTF_8, **ENCODE_OPTS)
191
191
  end
192
192
 
193
193
  def recursive?(data)
@@ -1,4 +1,4 @@
1
1
  module Honeybadger
2
2
  # The current String Honeybadger version.
3
- VERSION = '4.5.5'.freeze
3
+ VERSION = '4.5.6'.freeze
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: honeybadger
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.5.5
4
+ version: 4.5.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Honeybadger Industries LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-01-07 00:00:00.000000000 Z
11
+ date: 2020-01-08 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Make managing application errors a more pleasant experience.
14
14
  email:
@@ -152,7 +152,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
152
152
  - !ruby/object:Gem::Version
153
153
  version: '0'
154
154
  requirements: []
155
- rubygems_version: 3.0.3
155
+ rubyforge_project:
156
+ rubygems_version: 2.7.6.2
156
157
  signing_key:
157
158
  specification_version: 4
158
159
  summary: Error reports you can be happy about.