sentry-rails 4.2.1 → 4.2.2

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
  SHA256:
3
- metadata.gz: ab83fdc945ddfb3c5dbd4a38c34c8748acfc9745f5f9bbf39e47c188778760b6
4
- data.tar.gz: 05ac3bde183e9615d292c2c978224b06567347c4b461cd8281d4f308d2b61bdc
3
+ metadata.gz: e22a278e6c74ad09c754d5270c227c1dd0989c90654d2f3f55d3ca06e06ad577
4
+ data.tar.gz: c3bed6941cf8abdc306d20fd6ef7ebcecf08bb246b05921002423ac984a20d2b
5
5
  SHA512:
6
- metadata.gz: 28819d457892ae94280d5f6f5ec44e23eeec4d52f338b68ccc31ccd5f090b63a560eb9b72b626c1bb011288e9beb0e3762eb14229a6b689d8f957aaf7a0ea867
7
- data.tar.gz: 2e095079c8ea3e1f8ad552bbe0c94a0a93a87c199832cb19de2beaa242cacea95383bca18529316133949f4ba807fe0b1898783a36db26aacca74eac8c0fcf79
6
+ metadata.gz: bdda28d73217516a73ffdf82ddc81687649255623a38ebcd3f9aa52d98bdf6ced7882a13c1d9dae8509eda5e1bc82a99c2762c8c5e89cd27153a98e81ba7d691
7
+ data.tar.gz: 396aaacdf3db30251891de7bf4c5e6e5c27f5ce69eb6c9fc157f5fc70dada5c4fa782dac0dcf6050c6a8cf2474f680d801f4a7dac555b20f990aca077e8cfbc9
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 4.2.2
4
+
5
+ - Always define Sentry::SendEventJob to avoid eager load issues [#1286](https://github.com/getsentry/sentry-ruby/pull/1286)
6
+ - Fixes [#1283](https://github.com/getsentry/sentry-ruby/issues/1283)
7
+
3
8
  ## 4.2.1
4
9
 
5
10
  - Add additional checks to SendEventJob's definition [#1275](https://github.com/getsentry/sentry-ruby/pull/1275)
@@ -1,30 +1,34 @@
1
- return unless defined?(ActiveJob)
2
-
3
- module Sentry
4
- parent_job =
5
- if defined?(::ApplicationJob) && ::ApplicationJob.ancestors.include?(::ActiveJob::Base)
6
- ::ApplicationJob
7
- else
8
- ::ActiveJob::Base
9
- end
1
+ if defined?(ActiveJob)
2
+ module Sentry
3
+ parent_job =
4
+ if defined?(::ApplicationJob) && ::ApplicationJob.ancestors.include?(::ActiveJob::Base)
5
+ ::ApplicationJob
6
+ else
7
+ ::ActiveJob::Base
8
+ end
10
9
 
11
- class SendEventJob < parent_job
12
- # the event argument is usually large and creates noise
13
- self.log_arguments = false if respond_to?(:log_arguments=)
10
+ class SendEventJob < parent_job
11
+ # the event argument is usually large and creates noise
12
+ self.log_arguments = false if respond_to?(:log_arguments=)
14
13
 
15
- # this will prevent infinite loop when there's an issue deserializing SentryJob
16
- if respond_to?(:discard_on)
17
- discard_on ActiveJob::DeserializationError
18
- else
19
- # mimic what discard_on does for Rails 5.0
20
- rescue_from ActiveJob::DeserializationError do
21
- logger.error "Discarded #{self.class} due to a #{exception}. The original exception was #{error.cause.inspect}."
14
+ # this will prevent infinite loop when there's an issue deserializing SentryJob
15
+ if respond_to?(:discard_on)
16
+ discard_on ActiveJob::DeserializationError
17
+ else
18
+ # mimic what discard_on does for Rails 5.0
19
+ rescue_from ActiveJob::DeserializationError do
20
+ logger.error "Discarded #{self.class} due to a #{exception}. The original exception was #{error.cause.inspect}."
21
+ end
22
22
  end
23
- end
24
23
 
25
- def perform(event, hint = {})
26
- Sentry.send_event(event, hint)
24
+ def perform(event, hint = {})
25
+ Sentry.send_event(event, hint)
26
+ end
27
27
  end
28
28
  end
29
+ else
30
+ module Sentry
31
+ class SendEventJob; end
32
+ end
29
33
  end
30
34
 
@@ -1,5 +1,5 @@
1
1
  module Sentry
2
2
  module Rails
3
- VERSION = "4.2.1"
3
+ VERSION = "4.2.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sentry-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.1
4
+ version: 4.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sentry Team
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-02-10 00:00:00.000000000 Z
11
+ date: 2021-02-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails