@appland/appmap 3.94.0 → 3.96.1
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.
- package/CHANGELOG.md +22 -0
- package/built/cmds/archive/analyzeWorker.js +7 -3
- package/built/cmds/archive/analyzeWorker.js.map +1 -1
- package/built/cmds/archive/index.js +11 -1
- package/built/cmds/archive/index.js.map +1 -1
- package/built/cmds/compare-report/MarkdownReport.js +11 -0
- package/built/cmds/compare-report/MarkdownReport.js.map +1 -1
- package/built/cmds/compare-report/compareReport.js +44 -5
- package/built/cmds/compare-report/compareReport.js.map +1 -1
- package/built/cmds/stats/stats.js +11 -25
- package/built/cmds/stats/stats.js.map +1 -1
- package/built/html/appmap.js +8 -4
- package/built/html/appmap.js.map +3 -3
- package/built/html/sequenceDiagram.js +8 -4
- package/built/html/sequenceDiagram.js.map +3 -3
- package/built/lib/emitUsage.js +16 -13
- package/built/lib/emitUsage.js.map +1 -1
- package/package.json +1 -1
- package/resources/change-report.hbs +29 -13
package/built/lib/emitUsage.js
CHANGED
|
@@ -3,10 +3,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const client_1 = require("@appland/client");
|
|
7
6
|
const telemetry_1 = require("../telemetry");
|
|
8
7
|
const repositoryInfo_1 = __importDefault(require("./repositoryInfo"));
|
|
9
|
-
const
|
|
8
|
+
const promises_1 = require("node:fs/promises");
|
|
9
|
+
const node_path_1 = require("node:path");
|
|
10
10
|
async function buildMetadata(appmapDir, metadata) {
|
|
11
11
|
const repository = await telemetry_1.Git.repository(appmapDir);
|
|
12
12
|
const branch = await telemetry_1.Git.branch(appmapDir);
|
|
@@ -25,24 +25,27 @@ async function buildMetadata(appmapDir, metadata) {
|
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
async function emitUsage(appmapDir, numEvents, numAppMaps, sampleMetadata) {
|
|
28
|
-
const contributors = await telemetry_1.Git.contributors(90);
|
|
29
28
|
const dto = {
|
|
30
29
|
events: numEvents,
|
|
31
30
|
appmaps: numAppMaps,
|
|
32
|
-
contributors: contributors.length,
|
|
33
31
|
metadata: await buildMetadata(appmapDir, sampleMetadata),
|
|
34
32
|
ci: process.env.CI !== undefined,
|
|
35
33
|
};
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
34
|
+
try {
|
|
35
|
+
const stats = await (0, promises_1.stat)('.appmap');
|
|
36
|
+
if (stats.isDirectory()) {
|
|
37
|
+
const runStatsDirectory = (0, node_path_1.join)('.appmap', 'run-stats');
|
|
38
|
+
await (0, promises_1.mkdir)(runStatsDirectory, { recursive: true });
|
|
39
|
+
const statsFilePath = (0, node_path_1.join)(runStatsDirectory, `${Date.now().toString()}.json`);
|
|
40
|
+
await (0, promises_1.writeFile)(statsFilePath, JSON.stringify(dto));
|
|
41
|
+
return statsFilePath;
|
|
43
42
|
}
|
|
44
|
-
}
|
|
45
|
-
|
|
43
|
+
}
|
|
44
|
+
catch (e) {
|
|
45
|
+
if (e instanceof Error && 'code' in e && e.code !== 'ENOENT') {
|
|
46
|
+
console.warn(`Unable to write run stats: ${e}`);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
46
49
|
}
|
|
47
50
|
exports.default = emitUsage;
|
|
48
51
|
//# sourceMappingURL=emitUsage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emitUsage.js","sourceRoot":"","sources":["../../src/lib/emitUsage.ts"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"emitUsage.js","sourceRoot":"","sources":["../../src/lib/emitUsage.ts"],"names":[],"mappings":";;;;;AAEA,4CAAmC;AAEnC,sEAA2C;AAC3C,+CAA0D;AAC1D,yCAAiC;AAEjC,KAAK,UAAU,aAAa,CA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GAAG,IAAA,gBAAI,EAAC,SAAS,EAAE,WAAW,CAAC,CAAC;YACvD,MAAM,IAAA,gBAAK,EAAC,iBAAiB,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;YAEpD,MAAM,aAAa,GAAG,IAAA,gBAAI,EAAC,iBAAiB,EAAE,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;YAC/E,MAAM,IAAA,oBAAS,EAAC,aAAa,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC;YACpD,OAAO,aAAa,CAAC;SACtB;KACF;IAAC,OAAO,CAAC,EAAE;QACV,IAAI,CAAC,YAAY,KAAK,IAAI,MAAM,IAAI,CAAC,IAAI,CAAC,CAAC,IAAI,KAAK,QAAQ,EAAE;YAC5D,OAAO,CAAC,IAAI,CAAC,8BAA8B,CAAC,EAAE,CAAC,CAAC;SACjD;KACF;AACH,CAAC;AA5BD,4BA4BC"}
|
package/package.json
CHANGED
|
@@ -26,9 +26,9 @@ No relevant code changes found.
|
|
|
26
26
|
{{#with stack }}
|
|
27
27
|
{{#each this }}
|
|
28
28
|
{{#if (source_url this)}}
|
|
29
|
-
|
|
29
|
+
- [{{this}}]({{ source_url this }})
|
|
30
30
|
{{else}}
|
|
31
|
-
|
|
31
|
+
- {{ this }}
|
|
32
32
|
{{/if}}
|
|
33
33
|
{{/each}}
|
|
34
34
|
{{/with}}
|
|
@@ -62,8 +62,10 @@ No relevant code changes found.
|
|
|
62
62
|
|
|
63
63
|
| Summary | Status |
|
|
64
64
|
| --- | --- |
|
|
65
|
-
|
|
66
|
-
{{#if
|
|
65
|
+
{{#if (enabled 'failed-tests') }}
|
|
66
|
+
| [Failed tests](#failed-tests) | {{#if testFailures.length}}:warning: {{testFailures.length}} failed{{else}}:white_check_mark: All tests passed{{/if}} |
|
|
67
|
+
{{~/if}}
|
|
68
|
+
{{~#if (enabled 'openapi-diff')}}{{~#if (defined apiDiff) }}
|
|
67
69
|
| [API changes](#api-changes) |
|
|
68
70
|
{{~#unless apiDiff.differenceCount }}
|
|
69
71
|
:white_check_mark: No API changes
|
|
@@ -73,8 +75,8 @@ No relevant code changes found.
|
|
|
73
75
|
{{~#if apiDiff.nonBreakingDifferenceCount }}{{#if apiDiff.breakingDifferenceCount }}, {{~/if}}:wrench: {{apiDiff.nonBreakingDifferenceCount}} non-breaking{{~/if}}
|
|
74
76
|
{{~/if}}
|
|
75
77
|
|
|
|
76
|
-
{{
|
|
77
|
-
{{
|
|
78
|
+
{{~/if}}{{~/if}}
|
|
79
|
+
{{~#if (enabled 'findings')}}{{~#if (defined findingDiff) }}
|
|
78
80
|
| [Findings](#findings) |
|
|
79
81
|
{{~#with findingDiff}}
|
|
80
82
|
{{~#unless (length new resolved) }}
|
|
@@ -88,7 +90,8 @@ No relevant code changes found.
|
|
|
88
90
|
{{~/if}}
|
|
89
91
|
{{~/with}}
|
|
90
92
|
|
|
|
91
|
-
{{
|
|
93
|
+
{{~/if}}{{~/if}}
|
|
94
|
+
{{#if (enabled 'new-appmaps')}}
|
|
92
95
|
| [New AppMaps](#new-appmaps) |
|
|
93
96
|
{{~#unless newAppMaps.length }}
|
|
94
97
|
:white_check_mark: None
|
|
@@ -96,16 +99,20 @@ No relevant code changes found.
|
|
|
96
99
|
:star: {{newAppMaps.length}} new
|
|
97
100
|
{{~/unless}}
|
|
98
101
|
|
|
|
99
|
-
|
|
102
|
+
{{/if}}
|
|
103
|
+
{{#if (enabled 'changed-appmaps')}}
|
|
104
|
+
| [Changed AppMaps](#changed-appmaps) |
|
|
100
105
|
{{~#unless sequenceDiagramDiffSnippetCount }}
|
|
101
106
|
:white_check_mark: No changes
|
|
102
107
|
{{~else}}
|
|
103
108
|
:twisted_rightwards_arrows: {{sequenceDiagramDiffSnippetCount}} changes
|
|
104
109
|
{{~/unless}}
|
|
105
110
|
|
|
|
111
|
+
{{~/if}}
|
|
106
112
|
|
|
113
|
+
{{#if (enabled 'failed-tests')}}
|
|
107
114
|
{{#if testFailures.length}}
|
|
108
|
-
## :warning:
|
|
115
|
+
## :warning: Failed tests
|
|
109
116
|
|
|
110
117
|
{{#each testFailures}}
|
|
111
118
|
|
|
@@ -159,7 +166,9 @@ No relevant code changes found.
|
|
|
159
166
|
|
|
160
167
|
{{/each}}
|
|
161
168
|
{{/if}}
|
|
169
|
+
{{/if}}
|
|
162
170
|
|
|
171
|
+
{{#if (enabled 'openapi-diff')}}
|
|
163
172
|
{{#if apiDiff.differenceCount }}
|
|
164
173
|
|
|
165
174
|
## 🔄 API changes
|
|
@@ -168,7 +177,7 @@ No relevant code changes found.
|
|
|
168
177
|
### 🚧 Breaking changes
|
|
169
178
|
|
|
170
179
|
{{#each apiDiff.breakingDifferences}}
|
|
171
|
-
|
|
180
|
+
- {{> api-change }}
|
|
172
181
|
{{/each}}
|
|
173
182
|
{{/if}}
|
|
174
183
|
|
|
@@ -176,7 +185,7 @@ No relevant code changes found.
|
|
|
176
185
|
### :wrench: Non-breaking changes
|
|
177
186
|
|
|
178
187
|
{{#each apiDiff.nonBreakingDifferences}}
|
|
179
|
-
|
|
188
|
+
- {{> api-change }}
|
|
180
189
|
{{/each}}
|
|
181
190
|
{{/if}}
|
|
182
191
|
|
|
@@ -198,8 +207,10 @@ No relevant code changes found.
|
|
|
198
207
|
```
|
|
199
208
|
</details>
|
|
200
209
|
|
|
210
|
+
{{/if}}
|
|
201
211
|
{{/if}}
|
|
202
212
|
|
|
213
|
+
{{#if (enabled 'findings') }}
|
|
203
214
|
{{#with findingDiff}}
|
|
204
215
|
{{#if (length new resolved)}}
|
|
205
216
|
|
|
@@ -225,7 +236,9 @@ No relevant code changes found.
|
|
|
225
236
|
|
|
226
237
|
{{/if}}
|
|
227
238
|
{{/with}}
|
|
239
|
+
{{/if}}
|
|
228
240
|
|
|
241
|
+
{{#if (enabled 'new-appmaps')}}
|
|
229
242
|
{{#if newAppMaps.length }}
|
|
230
243
|
|
|
231
244
|
<h2 id="new-appmaps">New AppMaps</h2>
|
|
@@ -236,10 +249,12 @@ No relevant code changes found.
|
|
|
236
249
|
|
|
237
250
|
{{/each}}
|
|
238
251
|
|
|
252
|
+
{{/if}}
|
|
239
253
|
{{/if}}
|
|
240
254
|
|
|
255
|
+
{{#if (enabled 'changed-appmaps')}}
|
|
241
256
|
{{#if sequenceDiagramDiffSnippetCount }}
|
|
242
|
-
## :twisted_rightwards_arrows: Changed
|
|
257
|
+
## :twisted_rightwards_arrows: Changed AppMaps
|
|
243
258
|
|
|
244
259
|
<details>
|
|
245
260
|
|
|
@@ -260,4 +275,5 @@ Review {{ sequenceDiagramDiffSnippetCount }} changes
|
|
|
260
275
|
{{/each}}
|
|
261
276
|
|
|
262
277
|
</details>
|
|
263
|
-
{{/if}}
|
|
278
|
+
{{/if}}
|
|
279
|
+
{{/if}}
|