airbrake 13.0.1 → 13.0.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:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 553d46f184e67e783a37345e049d4f7bb429520d27d732d2b732ab42ea4a5314
|
|
4
|
+
data.tar.gz: e162a0342478e68ec608faf5c3c8d033dd9c41a0956da1a08d26a040281fff2d
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0452b7f7d9acb6af56babd7b44cf3bc741de12d218c3d07e25be4de67ab3576ab8ba88a30a620abe9a3b419a9d24d86428583ddcb3858a2755f5b20ad0020b89
|
|
7
|
+
data.tar.gz: fba302f11402c2c066d2d909b5c5cb2988f4071940fdb4a32e32e30f4b62fce4b683f322c72736fff0e24df64af603953ec32b9ed01941be658ca322ab6ee499
|
|
@@ -9,10 +9,6 @@ module Airbrake
|
|
|
9
9
|
#
|
|
10
10
|
# @since v8.0.0
|
|
11
11
|
class ActionControllerNotifySubscriber
|
|
12
|
-
def initialize(rails_vsn)
|
|
13
|
-
@rails_7_or_above = rails_vsn.to_i >= 7
|
|
14
|
-
end
|
|
15
|
-
|
|
16
12
|
def call(*args)
|
|
17
13
|
return unless Airbrake::Config.instance.performance_stats
|
|
18
14
|
|
|
@@ -27,16 +23,7 @@ module Airbrake
|
|
|
27
23
|
route: route,
|
|
28
24
|
status_code: event.status_code,
|
|
29
25
|
timing: event.duration,
|
|
30
|
-
|
|
31
|
-
# On Rails 7+ `ActiveSupport::Notifications::Event#time` returns an
|
|
32
|
-
# instance of Float. It represents monotonic time in milliseconds.
|
|
33
|
-
# Airbrake Ruby expects that the provided time is in seconds. Hence,
|
|
34
|
-
# we need to convert it from milliseconds to seconds. In the
|
|
35
|
-
# versions below Rails 7, time is an instance of Time.
|
|
36
|
-
#
|
|
37
|
-
# Relevant commit:
|
|
38
|
-
# https://github.com/rails/rails/commit/81d0dc90becfe0b8e7f7f26beb66c25d84b8ec7f
|
|
39
|
-
time: @rails_7_or_above ? event.time / 1000 : event.time,
|
|
26
|
+
time: event.time,
|
|
40
27
|
)
|
|
41
28
|
end
|
|
42
29
|
end
|
data/lib/airbrake/rails/event.rb
CHANGED
|
@@ -10,10 +10,14 @@ module Airbrake
|
|
|
10
10
|
# @see https://github.com/rails/rails/issues/8987
|
|
11
11
|
HTML_RESPONSE_WILDCARD = "*/*"
|
|
12
12
|
|
|
13
|
+
# @return [Integer]
|
|
14
|
+
MILLISECOND = 1000
|
|
15
|
+
|
|
13
16
|
include Airbrake::Loggable
|
|
14
17
|
|
|
15
18
|
def initialize(*args)
|
|
16
19
|
@event = ActiveSupport::Notifications::Event.new(*args)
|
|
20
|
+
@rails_7_or_greater = ::Rails::VERSION::MAJOR >= 7
|
|
17
21
|
end
|
|
18
22
|
|
|
19
23
|
def method
|
|
@@ -42,7 +46,15 @@ module Airbrake
|
|
|
42
46
|
end
|
|
43
47
|
|
|
44
48
|
def time
|
|
45
|
-
|
|
49
|
+
# On Rails 7+ `ActiveSupport::Notifications::Event#time` returns an
|
|
50
|
+
# instance of Float. It represents monotonic time in milliseconds.
|
|
51
|
+
# Airbrake Ruby expects that the provided time is in seconds. Hence,
|
|
52
|
+
# we need to convert it from milliseconds to seconds. In the
|
|
53
|
+
# versions below Rails 7, time is an instance of Time.
|
|
54
|
+
#
|
|
55
|
+
# Relevant commit:
|
|
56
|
+
# https://github.com/rails/rails/commit/81d0dc90becfe0b8e7f7f26beb66c25d84b8ec7f
|
|
57
|
+
@rails_7_or_greater ? @event.time / MILLISECOND : @event.time
|
|
46
58
|
end
|
|
47
59
|
|
|
48
60
|
def groups
|
|
@@ -15,9 +15,7 @@ module Airbrake
|
|
|
15
15
|
class ActionControllerTie
|
|
16
16
|
def initialize
|
|
17
17
|
@route_subscriber = Airbrake::Rails::ActionControllerRouteSubscriber.new
|
|
18
|
-
@notify_subscriber = Airbrake::Rails::ActionControllerNotifySubscriber.new
|
|
19
|
-
::Rails.version,
|
|
20
|
-
)
|
|
18
|
+
@notify_subscriber = Airbrake::Rails::ActionControllerNotifySubscriber.new
|
|
21
19
|
@performance_breakdown_subscriber =
|
|
22
20
|
Airbrake::Rails::ActionControllerPerformanceBreakdownSubscriber.new
|
|
23
21
|
end
|
data/lib/airbrake/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: airbrake
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 13.0.
|
|
4
|
+
version: 13.0.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Airbrake Technologies, Inc.
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2022-05-
|
|
11
|
+
date: 2022-05-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: airbrake-ruby
|
|
@@ -369,7 +369,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
369
369
|
- !ruby/object:Gem::Version
|
|
370
370
|
version: '0'
|
|
371
371
|
requirements: []
|
|
372
|
-
rubygems_version: 3.
|
|
372
|
+
rubygems_version: 3.3.3
|
|
373
373
|
signing_key:
|
|
374
374
|
specification_version: 4
|
|
375
375
|
summary: Airbrake is an online tool that provides robust exception tracking in any
|