rookout 0.1.17 → 0.1.22
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rookout/augs/aug_factory.rb +2 -2
- data/lib/rookout/com_ws/pinger.rb +8 -3
- data/lib/rookout/com_ws/websocket_client.rb +6 -2
- data/lib/rookout/commit.rb +1 -1
- data/lib/rookout/exceptions.rb +24 -0
- data/lib/rookout/interface.rb +6 -1
- data/lib/rookout/processor/namespaces/ruby_object_serializer.rb +2 -2
- data/lib/rookout/version.rb +1 -1
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1189352fe3bb2817944ec553c3a658bcd0d677781ffee90190521e1ed55189c3
|
4
|
+
data.tar.gz: 63bf916c9f3140c4bf2be89a3469ffd3f451f37edc4741c39c6336ef1373269c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cace5dbc2f61f8e1987397345061080fecc85cbcaeb065976f8a8ae071621c01b717e46dd98df55a48fd399f7b2f02b467b786b335d9dcf4088e09a3094f1961
|
7
|
+
data.tar.gz: d33370845b6bb7166c93626e74b73a743d5a799f8b69722bae627561fbd747a36542c2a38e7f3135f099e90415d5b5219775407e942a8f3e25c60939a1be9012
|
@@ -45,7 +45,7 @@ module Rookout
|
|
45
45
|
|
46
46
|
def create_location configuration, aug
|
47
47
|
name = configuration["name"]
|
48
|
-
raise Exceptions
|
48
|
+
raise Exceptions::RookObjectNameMissing if name.nil?
|
49
49
|
|
50
50
|
case name
|
51
51
|
when "file_line"
|
@@ -53,7 +53,7 @@ module Rookout
|
|
53
53
|
when "exception_handler"
|
54
54
|
return Locations::LocationExceptionHandler.new configuration, @output, aug
|
55
55
|
else
|
56
|
-
raise Exceptions
|
56
|
+
raise Exceptions::RookUnsupportedLocation if name != "file_line"
|
57
57
|
end
|
58
58
|
end
|
59
59
|
|
@@ -17,9 +17,14 @@ module Rookout
|
|
17
17
|
if Time.now - @last_ping > @interval
|
18
18
|
Logger.instance.debug "Sending Ping"
|
19
19
|
@last_ping = Time.now
|
20
|
-
|
21
|
-
|
22
|
-
|
20
|
+
begin
|
21
|
+
@connection.ping Time.now.to_s do
|
22
|
+
Logger.instance.debug "Got Ping reply"
|
23
|
+
@last_pong = Time.now
|
24
|
+
end
|
25
|
+
rescue RuntimeError, Errno::EPIPE
|
26
|
+
Logger.instance.debug "Failed to send ping"
|
27
|
+
break
|
23
28
|
end
|
24
29
|
end
|
25
30
|
|
@@ -14,7 +14,6 @@ module Rookout
|
|
14
14
|
@connection = WebsocketConnection.new url, proxy
|
15
15
|
@proxy = proxy
|
16
16
|
@driver = nil
|
17
|
-
@last_ping = nil
|
18
17
|
end
|
19
18
|
|
20
19
|
def connect
|
@@ -64,7 +63,12 @@ module Rookout
|
|
64
63
|
def close
|
65
64
|
return if @driver.nil?
|
66
65
|
|
67
|
-
|
66
|
+
begin
|
67
|
+
@driver.close
|
68
|
+
rescue RuntimeError, Errno::EPIPE
|
69
|
+
# Protocol close may fail if the connection is already closed
|
70
|
+
nil
|
71
|
+
end
|
68
72
|
@connection.close
|
69
73
|
end
|
70
74
|
|
data/lib/rookout/commit.rb
CHANGED
data/lib/rookout/exceptions.rb
CHANGED
@@ -144,6 +144,12 @@ module Rookout
|
|
144
144
|
end
|
145
145
|
end
|
146
146
|
|
147
|
+
class RookInvalidLabel < ToolException
|
148
|
+
def initialize label_name
|
149
|
+
super "Invalid label: must not start with the '$' character (#{label_name})"
|
150
|
+
end
|
151
|
+
end
|
152
|
+
|
147
153
|
class RookCrcMismatchException < ToolException
|
148
154
|
def initialize filepath, expected, calculated
|
149
155
|
super "Line CRC32s do not match! path: #{filepath}, expected: #{expected}, calculated:#{calculated}",
|
@@ -195,5 +201,23 @@ module Rookout
|
|
195
201
|
super "Bad protobuf platform: #{platform}"
|
196
202
|
end
|
197
203
|
end
|
204
|
+
|
205
|
+
class RookObjectNameMissing < ToolException
|
206
|
+
def initialize configuration
|
207
|
+
super "Failed to find object name",
|
208
|
+
{
|
209
|
+
"configuration" => configuration
|
210
|
+
}
|
211
|
+
end
|
212
|
+
end
|
213
|
+
|
214
|
+
class RookUnsupportedLocation < ToolException
|
215
|
+
def initialize location
|
216
|
+
super "Unsupported aug location was specified: #{location}",
|
217
|
+
{
|
218
|
+
"location" => location
|
219
|
+
}
|
220
|
+
end
|
221
|
+
end
|
198
222
|
end
|
199
223
|
end
|
data/lib/rookout/interface.rb
CHANGED
@@ -12,12 +12,17 @@ module Rookout
|
|
12
12
|
@start_options = nil
|
13
13
|
end
|
14
14
|
|
15
|
+
def print_debug_messages
|
16
|
+
puts "[Rookout] Running in debug mode"
|
17
|
+
puts "[Rookout] Rookout SDK for ruby: " + Config.rookout_version
|
18
|
+
end
|
19
|
+
|
15
20
|
def start options = {}
|
16
21
|
return unless @rook.nil?
|
17
22
|
throw_errors = options[:throw_errors] == true
|
18
23
|
Config.debug = evaluate_flag options[:debug], "ROOKOUT_DEBUG"
|
19
24
|
|
20
|
-
|
25
|
+
print_debug_messages if Config.debug
|
21
26
|
|
22
27
|
begin
|
23
28
|
verify_env
|
@@ -35,9 +35,9 @@ module Rookout
|
|
35
35
|
dump_string obj, variant, config
|
36
36
|
elsif obj.is_a? Time
|
37
37
|
dump_time obj, variant
|
38
|
-
elsif obj.
|
38
|
+
elsif obj.class == Array
|
39
39
|
dump_array obj, variant, current_depth, config, log_object_errors
|
40
|
-
elsif obj.
|
40
|
+
elsif obj.class == Hash
|
41
41
|
dump_hash obj, variant, current_depth, config, log_object_errors
|
42
42
|
elsif obj.is_a? Exception
|
43
43
|
dump_exception obj, variant, current_depth, config, log_object_errors
|
data/lib/rookout/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rookout
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.22
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Liran Haimovitch
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-05-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: binding_of_caller
|
@@ -84,14 +84,14 @@ dependencies:
|
|
84
84
|
name: google-style
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- -
|
87
|
+
- - '='
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: 1.24.0
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- -
|
94
|
+
- - '='
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: 1.24.0
|
97
97
|
- !ruby/object:Gem::Dependency
|
@@ -253,7 +253,7 @@ licenses:
|
|
253
253
|
- Proprietary
|
254
254
|
metadata:
|
255
255
|
homepage_uri: https://rookout.com
|
256
|
-
post_install_message:
|
256
|
+
post_install_message:
|
257
257
|
rdoc_options: []
|
258
258
|
require_paths:
|
259
259
|
- lib
|
@@ -268,8 +268,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
268
268
|
- !ruby/object:Gem::Version
|
269
269
|
version: '0'
|
270
270
|
requirements: []
|
271
|
-
rubygems_version: 3.1.
|
272
|
-
signing_key:
|
271
|
+
rubygems_version: 3.1.6
|
272
|
+
signing_key:
|
273
273
|
specification_version: 4
|
274
274
|
summary: rookout is the Ruby SDK for the Rookout Debugging Platform
|
275
275
|
test_files: []
|