appmap 0.90.0 → 0.91.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +1 -1
- data/CHANGELOG.md +19 -0
- data/lib/appmap/class_map.rb +1 -4
- data/lib/appmap/cucumber.rb +2 -1
- data/lib/appmap/middleware/remote_recording.rb +4 -2
- data/lib/appmap/minitest.rb +2 -1
- data/lib/appmap/record.rb +2 -1
- data/lib/appmap/rspec.rb +2 -1
- data/lib/appmap/trace.rb +20 -2
- data/lib/appmap/version.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4d721301c87647a2778b1019519a7ada3fc225761b32149070ee38d8e47c5643
|
4
|
+
data.tar.gz: b4a130739d8974a3adbe44a9020618e9f88530174de19e8aaa0713dad23336c4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9f0778dc18e12f668bc072b94f21f61f1310c6d0163531e7e8407fd5e45d64d9a2e1b2a9d4c0cf98c1ba3f31697ca38ee50461f55b293893442a7b19f515ac3a
|
7
|
+
data.tar.gz: 9469680e79ccf0e8a43967c1c6d0104c48d35399fd39b205bfc9d3c41f32f2469d527989f38e965f80e00f320cfce9026c124ed775f27ba773bf58d449083d6c
|
data/.rubocop.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,22 @@
|
|
1
|
+
# [0.91.0](https://github.com/applandinc/appmap-ruby/compare/v0.90.1...v0.91.0) (2022-09-19)
|
2
|
+
|
3
|
+
|
4
|
+
### Features
|
5
|
+
|
6
|
+
* Emit metadata.recorder.type ([6358669](https://github.com/applandinc/appmap-ruby/commit/6358669d5dc5123a613b18301519dac709614406))
|
7
|
+
|
8
|
+
## [0.90.1](https://github.com/applandinc/appmap-ruby/compare/v0.90.0...v0.90.1) (2022-09-19)
|
9
|
+
|
10
|
+
|
11
|
+
### Bug Fixes
|
12
|
+
|
13
|
+
* Faster comment extraction ([f6199a6](https://github.com/applandinc/appmap-ruby/commit/f6199a607fadd58500d9cdc9394b39413e6b2930))
|
14
|
+
|
15
|
+
|
16
|
+
### Performance Improvements
|
17
|
+
|
18
|
+
* Don't save comment and source in classmap. ([c3c8e75](https://github.com/applandinc/appmap-ruby/commit/c3c8e755677d169610bfa7e55c12f0d418120eb7))
|
19
|
+
|
1
20
|
# [0.90.0](https://github.com/applandinc/appmap-ruby/compare/v0.89.0...v0.90.0) (2022-09-15)
|
2
21
|
|
3
22
|
|
data/lib/appmap/class_map.rb
CHANGED
@@ -50,7 +50,7 @@ module AppMap
|
|
50
50
|
end
|
51
51
|
end
|
52
52
|
Function = Struct.new(:name) do
|
53
|
-
attr_accessor :static, :location, :labels
|
53
|
+
attr_accessor :static, :location, :labels
|
54
54
|
|
55
55
|
def type
|
56
56
|
'function'
|
@@ -63,8 +63,6 @@ module AppMap
|
|
63
63
|
location: location,
|
64
64
|
static: static,
|
65
65
|
labels: labels,
|
66
|
-
comment: comment,
|
67
|
-
source: source
|
68
66
|
}.delete_if { |_, v| v.nil? || v == [] }
|
69
67
|
end
|
70
68
|
end
|
@@ -126,7 +124,6 @@ module AppMap
|
|
126
124
|
end
|
127
125
|
|
128
126
|
comment = method.comment
|
129
|
-
function_info[:comment] = comment unless Util.blank?(comment)
|
130
127
|
|
131
128
|
function_info[:labels] = parse_labels(comment) + (method.labels || [])
|
132
129
|
object_infos << function_info
|
data/lib/appmap/cucumber.rb
CHANGED
@@ -63,7 +63,8 @@ module AppMap
|
|
63
63
|
|
64
64
|
metadata = AppMap.detect_metadata
|
65
65
|
metadata[:recorder] = {
|
66
|
-
name: 'remote_recording'
|
66
|
+
name: 'remote_recording',
|
67
|
+
type: 'remote'
|
67
68
|
}
|
68
69
|
|
69
70
|
response = JSON.generate \
|
@@ -103,7 +104,8 @@ module AppMap
|
|
103
104
|
metadata[:name] = appmap_name
|
104
105
|
metadata[:timestamp] = start_time.to_f
|
105
106
|
metadata[:recorder] = {
|
106
|
-
name: '
|
107
|
+
name: 'rack',
|
108
|
+
type: 'requests'
|
107
109
|
}
|
108
110
|
|
109
111
|
appmap = {
|
data/lib/appmap/minitest.rb
CHANGED
data/lib/appmap/record.rb
CHANGED
data/lib/appmap/rspec.rb
CHANGED
data/lib/appmap/trace.rb
CHANGED
@@ -21,8 +21,11 @@ module AppMap
|
|
21
21
|
end
|
22
22
|
|
23
23
|
def comment
|
24
|
-
|
25
|
-
|
24
|
+
return nil if source_location.nil? || source_location.first.start_with?('<')
|
25
|
+
|
26
|
+
# Do not use method_source's comment method because it's slow
|
27
|
+
@comment ||= RubyMethod.last_comment *source_location
|
28
|
+
rescue Errno::EINVAL, Errno::ENOENT
|
26
29
|
nil
|
27
30
|
end
|
28
31
|
|
@@ -37,6 +40,21 @@ module AppMap
|
|
37
40
|
def labels
|
38
41
|
@package.labels
|
39
42
|
end
|
43
|
+
|
44
|
+
private
|
45
|
+
|
46
|
+
# Read file and get last comment before line.
|
47
|
+
def self.last_comment(file, line_number)
|
48
|
+
File.open(file) do |f|
|
49
|
+
buffer = []
|
50
|
+
f.each_line.lazy.take(line_number - 1).reverse_each do |line|
|
51
|
+
break unless (line =~ /^\s*#/) || (line =~ /^\s*$/)
|
52
|
+
|
53
|
+
buffer << line.lstrip
|
54
|
+
end
|
55
|
+
buffer.reverse.join
|
56
|
+
end
|
57
|
+
end
|
40
58
|
end
|
41
59
|
|
42
60
|
class Tracing
|
data/lib/appmap/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: appmap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.91.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kevin Gilpin
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-09-
|
11
|
+
date: 2022-09-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: method_source
|