honeybadger 5.25.0 → 5.26.0

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: b68a6aaaacbd4d0dacf73e81dac6927cc89bd1446b91be6d5a51456f3c7b7723
4
- data.tar.gz: c8d46e503b7a562a63b01776f8b14aa98dccd5d81fc7ea02b98bd2ccff23ec7f
3
+ metadata.gz: f7bcdde3f33ab64c1d8e608d169bc05c56e6ed8ec958a11046caa49568c348a5
4
+ data.tar.gz: 036fff2d87563cd2b21155619b32e53b22d1a8afd846d881ae486e557dc81e71
5
5
  SHA512:
6
- metadata.gz: 4bff878d0ea80ad0fc34f9265e7815dc2c9bf922e4f5bb59381a4822b549725fdcce413206c0f48495e56bb283ccdf3f23d4a485541b51fd843563d83f397103
7
- data.tar.gz: 2bf7ff80ed9af1137ba412b51d29e0ae5dc7151f103c2a804dc3edf86f27e756f69c307d1d79d7f084f82c643b76b9049587873a06bfa722a041d425251ba8f6
6
+ metadata.gz: fb6966adaf990948aa62522c52054f45b9bc3adee2bb9b0939c296cd071d0741a714ca4723b83504de0da8958df9e65c79533081a72f6d2eb0a4cecd16927cfc
7
+ data.tar.gz: 831467b1a778c468c1f35f776f4c79561228115ecb610c25769799dc254d25a1eb62135c6b03bd95e1cc0dbb126118f5a0ffa5b37bd306ab36cb16b3ef1389db
data/CHANGELOG.md CHANGED
@@ -1,6 +1,13 @@
1
1
  # Change Log
2
2
 
3
3
 
4
+ ## [5.26.0](https://github.com/honeybadger-io/honeybadger-ruby/compare/v5.25.0...v5.26.0) (2024-11-27)
5
+
6
+
7
+ ### Features
8
+
9
+ * use after_change for context changes ([#651](https://github.com/honeybadger-io/honeybadger-ruby/issues/651)) ([2cfc766](https://github.com/honeybadger-io/honeybadger-ruby/commit/2cfc766660d0462168aded9c34712904f8a1f774))
10
+
4
11
  ## [5.25.0](https://github.com/honeybadger-io/honeybadger-ruby/compare/v5.24.0...v5.25.0) (2024-11-26)
5
12
 
6
13
 
@@ -32,8 +32,6 @@ module Honeybadger
32
32
 
33
33
  class ErrorSubscriber
34
34
  def self.report(exception, handled:, severity:, context: {}, source: nil)
35
- Honeybadger.context(context)
36
-
37
35
  # We only report handled errors (`Rails.error.handle`)
38
36
  # Unhandled errors will be caught by our integrations (eg middleware),
39
37
  # which have richer context than the Rails error reporter
@@ -43,7 +41,7 @@ module Honeybadger
43
41
 
44
42
  tags = ["severity:#{severity}", "handled:#{handled}"]
45
43
  tags << "source:#{source}" if source
46
- Honeybadger.notify(exception, tags: tags)
44
+ Honeybadger.notify(exception, context: context, tags: tags)
47
45
  end
48
46
 
49
47
  def self.source_ignored?(source)
@@ -67,6 +65,12 @@ module Honeybadger
67
65
  end
68
66
 
69
67
  if Honeybadger.config[:'exceptions.enabled'] && defined?(::ActiveSupport::ErrorReporter) # Rails 7
68
+ if defined?(::ActiveSupport::ExecutionContext)
69
+ ::ActiveSupport::ExecutionContext.after_change do
70
+ Honeybadger.context(::ActiveSupport::ExecutionContext.to_h)
71
+ end
72
+ end
73
+
70
74
  ::Rails.error.subscribe(ErrorSubscriber)
71
75
  end
72
76
  end
@@ -1,4 +1,4 @@
1
1
  module Honeybadger
2
2
  # The current String Honeybadger version.
3
- VERSION = '5.25.0'.freeze
3
+ VERSION = '5.26.0'.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: 5.25.0
4
+ version: 5.26.0
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: 2024-11-26 00:00:00.000000000 Z
11
+ date: 2024-11-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logger