hardhat 3.4.3 → 3.4.4
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 +8 -0
- package/dist/src/internal/builtin-plugins/coverage/coverage-manager.d.ts +1 -1
- package/dist/src/internal/builtin-plugins/coverage/coverage-manager.d.ts.map +1 -1
- package/dist/src/internal/builtin-plugins/coverage/coverage-manager.js +9 -9
- package/dist/src/internal/builtin-plugins/coverage/coverage-manager.js.map +1 -1
- package/dist/src/internal/cli/telemetry/error-classification/classifier.d.ts +58 -0
- package/dist/src/internal/cli/telemetry/error-classification/classifier.d.ts.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/classifier.js +402 -0
- package/dist/src/internal/cli/telemetry/error-classification/classifier.js.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.d.ts +67 -0
- package/dist/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.d.ts.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.js +140 -0
- package/dist/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.js.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/filter.d.ts +15 -0
- package/dist/src/internal/cli/telemetry/error-classification/filter.d.ts.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/filter.js +114 -0
- package/dist/src/internal/cli/telemetry/error-classification/filter.js.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/helpers.d.ts +52 -0
- package/dist/src/internal/cli/telemetry/error-classification/helpers.d.ts.map +1 -0
- package/dist/src/internal/cli/telemetry/error-classification/helpers.js +163 -0
- package/dist/src/internal/cli/telemetry/error-classification/helpers.js.map +1 -0
- package/dist/src/internal/cli/telemetry/error-reporter/reporter.d.ts.map +1 -1
- package/dist/src/internal/cli/telemetry/error-reporter/reporter.js +14 -0
- package/dist/src/internal/cli/telemetry/error-reporter/reporter.js.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/anonymizer.d.ts +0 -2
- package/dist/src/internal/cli/telemetry/sentry/anonymizer.d.ts.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/anonymizer.js +0 -117
- package/dist/src/internal/cli/telemetry/sentry/anonymizer.js.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/init.d.ts.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/init.js +14 -9
- package/dist/src/internal/cli/telemetry/sentry/init.js.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/reporter.d.ts.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/reporter.js +1 -27
- package/dist/src/internal/cli/telemetry/sentry/reporter.js.map +1 -1
- package/dist/src/internal/cli/telemetry/sentry/subprocess.js +11 -17
- package/dist/src/internal/cli/telemetry/sentry/subprocess.js.map +1 -1
- package/package.json +1 -1
- package/src/internal/builtin-plugins/coverage/coverage-manager.ts +14 -10
- package/src/internal/cli/telemetry/error-classification/classifier.ts +636 -0
- package/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.ts +200 -0
- package/src/internal/cli/telemetry/error-classification/filter.ts +140 -0
- package/src/internal/cli/telemetry/error-classification/helpers.ts +235 -0
- package/src/internal/cli/telemetry/error-reporter/reporter.ts +21 -0
- package/src/internal/cli/telemetry/sentry/anonymizer.ts +0 -168
- package/src/internal/cli/telemetry/sentry/init.ts +42 -33
- package/src/internal/cli/telemetry/sentry/reporter.ts +1 -44
- package/src/internal/cli/telemetry/sentry/subprocess.ts +11 -19
- package/templates/hardhat-3/01-node-test-runner-viem/package.json +2 -2
- package/templates/hardhat-3/02-mocha-ethers/package.json +1 -1
- package/templates/hardhat-3/03-minimal/package.json +1 -1
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file This file has a set of helpers that depend on the codebase. They
|
|
3
|
+
* inspect the stack frames to look for known folders, files, or function names.
|
|
4
|
+
*
|
|
5
|
+
* As such, they are somewhat fragile and need to be periodically reevaluated,
|
|
6
|
+
* especially after large refactors to Hardhat's core.
|
|
7
|
+
*/
|
|
8
|
+
import { type StackFrame } from "./helpers.js";
|
|
9
|
+
/**
|
|
10
|
+
* Returns true when this package is being executed from the Hardhat monorepo
|
|
11
|
+
* source tree instead of from an installed `node_modules/hardhat` package.
|
|
12
|
+
*/
|
|
13
|
+
export declare function isRunningInsideHardhatMonorepo(): boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Matches the Hardhat frame that imports the user's config file.
|
|
16
|
+
*/
|
|
17
|
+
export declare function isConfigLoadingBoundaryFrame(frame: StackFrame): boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Matches the builtin console task frame that evaluates user input.
|
|
20
|
+
*/
|
|
21
|
+
export declare function isConsoleEvaluationBoundaryFrame(frame: StackFrame): boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Matches the builtin run task frame that executes a user script.
|
|
24
|
+
*/
|
|
25
|
+
export declare function isScriptExecutionBoundaryFrame(frame: StackFrame): boolean;
|
|
26
|
+
/**
|
|
27
|
+
* Matches the node:test runner task frame that executes user tests.
|
|
28
|
+
*/
|
|
29
|
+
export declare function isNodeTestExecutionBoundaryFrame(frame: StackFrame): boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Matches the Mocha runner task frame that executes user tests.
|
|
32
|
+
*/
|
|
33
|
+
export declare function isMochaTestExecutionBoundaryFrame(frame: StackFrame): boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Matches the resolved-task frame that calls into a task action.
|
|
36
|
+
*/
|
|
37
|
+
export declare function isTaskActionBoundaryFrame(frame: StackFrame): boolean;
|
|
38
|
+
/**
|
|
39
|
+
* Matches the hook-manager frame that calls into hook handlers.
|
|
40
|
+
*/
|
|
41
|
+
export declare function isHookHandlerBoundaryFrame(frame: StackFrame): boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Finds the task action frame immediately above the resolved-task boundary.
|
|
44
|
+
*/
|
|
45
|
+
export declare function getTaskExecutionFrame(frames: StackFrame[]): StackFrame | undefined;
|
|
46
|
+
/**
|
|
47
|
+
* Finds the hook handler frame immediately above the hook-manager boundary.
|
|
48
|
+
*/
|
|
49
|
+
export declare function getHookExecutionFrame(frames: StackFrame[]): StackFrame | undefined;
|
|
50
|
+
/**
|
|
51
|
+
* Returns true for stack locations owned by packages outside Hardhat.
|
|
52
|
+
*/
|
|
53
|
+
export declare function isThirdPartyFrame(location: string): boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Returns true for stack locations owned by Hardhat or first-party packages.
|
|
56
|
+
*/
|
|
57
|
+
export declare function isFirstPartyPluginFrame(location: string): boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Returns true when the error stack appears to come from workspace
|
|
60
|
+
* initialization.
|
|
61
|
+
*/
|
|
62
|
+
export declare function isWorkspaceInitFilesystemFrame(error: Error): boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Returns true for stack frames owned by EDR provider or stack-trace code.
|
|
65
|
+
*/
|
|
66
|
+
export declare function isEdrFrame(frame: StackFrame): boolean;
|
|
67
|
+
//# sourceMappingURL=codebase-dependent-helpers.d.ts.map
|
package/dist/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"codebase-dependent-helpers.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,KAAK,UAAU,EAAe,MAAM,cAAc,CAAC;AAE5D;;;GAGG;AACH,wBAAgB,8BAA8B,IAAI,OAAO,CAIxD;AAYD;;GAEG;AACH,wBAAgB,4BAA4B,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAKvE;AAED;;GAEG;AACH,wBAAgB,gCAAgC,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAK3E;AAED;;GAEG;AACH,wBAAgB,8BAA8B,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAKzE;AAED;;GAEG;AACH,wBAAgB,gCAAgC,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAK3E;AAED;;GAEG;AACH,wBAAgB,iCAAiC,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAK5E;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAKpE;AAED;;GAEG;AACH,wBAAgB,0BAA0B,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAUrE;AASD;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,UAAU,EAAE,GACnB,UAAU,GAAG,SAAS,CAgBxB;AAED;;GAEG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,UAAU,EAAE,GACnB,UAAU,GAAG,SAAS,CAexB;AAMD;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAK3D;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAMjE;AAED;;;GAGG;AACH,wBAAgB,8BAA8B,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAEpE;AAED;;GAEG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAMrD"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file This file has a set of helpers that depend on the codebase. They
|
|
3
|
+
* inspect the stack frames to look for known folders, files, or function names.
|
|
4
|
+
*
|
|
5
|
+
* As such, they are somewhat fragile and need to be periodically reevaluated,
|
|
6
|
+
* especially after large refactors to Hardhat's core.
|
|
7
|
+
*/
|
|
8
|
+
import { includesAny } from "./helpers.js";
|
|
9
|
+
/**
|
|
10
|
+
* Returns true when this package is being executed from the Hardhat monorepo
|
|
11
|
+
* source tree instead of from an installed `node_modules/hardhat` package.
|
|
12
|
+
*/
|
|
13
|
+
export function isRunningInsideHardhatMonorepo() {
|
|
14
|
+
// If this file is in `/packages/hardhat/`, as opposed to
|
|
15
|
+
// `node_modules/hardhat/`, then we're running inside the monorepo.
|
|
16
|
+
return import.meta.url.includes("/packages/hardhat/");
|
|
17
|
+
}
|
|
18
|
+
// ---------------------------------------------------------------------------
|
|
19
|
+
// Boundary frame predicates
|
|
20
|
+
//
|
|
21
|
+
// These identify the first-party frames that mark the boundary between
|
|
22
|
+
// Hardhat-controlled code and the user/plugin code that ultimately ran. Both
|
|
23
|
+
// the classifier (to assign a category) and the filter (to find the frame
|
|
24
|
+
// above the boundary) need to agree on what those frames look like, so they
|
|
25
|
+
// share a single definition here.
|
|
26
|
+
// ---------------------------------------------------------------------------
|
|
27
|
+
/**
|
|
28
|
+
* Matches the Hardhat frame that imports the user's config file.
|
|
29
|
+
*/
|
|
30
|
+
export function isConfigLoadingBoundaryFrame(frame) {
|
|
31
|
+
return (frame.location.includes("internal/config-loading.") &&
|
|
32
|
+
frame.functionName?.includes("importUserConfig") === true);
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Matches the builtin console task frame that evaluates user input.
|
|
36
|
+
*/
|
|
37
|
+
export function isConsoleEvaluationBoundaryFrame(frame) {
|
|
38
|
+
return (frame.location.includes("/internal/builtin-plugins/console/task-action.") &&
|
|
39
|
+
frame.functionName?.includes("consoleAction") === true);
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Matches the builtin run task frame that executes a user script.
|
|
43
|
+
*/
|
|
44
|
+
export function isScriptExecutionBoundaryFrame(frame) {
|
|
45
|
+
return (frame.location.includes("/internal/builtin-plugins/run/task-action.") &&
|
|
46
|
+
frame.functionName?.includes("runScriptWithHardhat") === true);
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Matches the node:test runner task frame that executes user tests.
|
|
50
|
+
*/
|
|
51
|
+
export function isNodeTestExecutionBoundaryFrame(frame) {
|
|
52
|
+
return (frame.location.includes("/hardhat-node-test-runner/src/task-action.") &&
|
|
53
|
+
frame.functionName?.includes("testWithHardhat") === true);
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Matches the Mocha runner task frame that executes user tests.
|
|
57
|
+
*/
|
|
58
|
+
export function isMochaTestExecutionBoundaryFrame(frame) {
|
|
59
|
+
return (frame.location.includes("/hardhat-mocha/src/task-action.") &&
|
|
60
|
+
frame.functionName?.includes("testWithHardhat") === true);
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Matches the resolved-task frame that calls into a task action.
|
|
64
|
+
*/
|
|
65
|
+
export function isTaskActionBoundaryFrame(frame) {
|
|
66
|
+
return (frame.location.includes("/internal/core/tasks/resolved-task.") &&
|
|
67
|
+
frame.functionName?.includes(".run") === true);
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Matches the hook-manager frame that calls into hook handlers.
|
|
71
|
+
*/
|
|
72
|
+
export function isHookHandlerBoundaryFrame(frame) {
|
|
73
|
+
return (frame.location.includes("/internal/core/hook-manager.") &&
|
|
74
|
+
includesAny(frame.functionName, ".runHandlerChain", ".runSequentialHandlers", ".runParallelHandlers"));
|
|
75
|
+
}
|
|
76
|
+
// ---------------------------------------------------------------------------
|
|
77
|
+
// Execution frame finders
|
|
78
|
+
//
|
|
79
|
+
// These locate the stack frame that identifies who the actual task action or
|
|
80
|
+
// hook handler is, relative to the boundary frame.
|
|
81
|
+
// ---------------------------------------------------------------------------
|
|
82
|
+
/**
|
|
83
|
+
* Finds the task action frame immediately above the resolved-task boundary.
|
|
84
|
+
*/
|
|
85
|
+
export function getTaskExecutionFrame(frames) {
|
|
86
|
+
const resolvedTaskRunIndex = frames.findIndex(isTaskActionBoundaryFrame);
|
|
87
|
+
if (resolvedTaskRunIndex === -1) {
|
|
88
|
+
return;
|
|
89
|
+
}
|
|
90
|
+
// The frames between `task.run` calls may include other resolved-task.ts
|
|
91
|
+
// helpers; we want the last frame that does not belong to that file.
|
|
92
|
+
return frames
|
|
93
|
+
.slice(0, resolvedTaskRunIndex)
|
|
94
|
+
.findLast((frame) => frame.location.includes("/internal/core/tasks/resolved-task.") ===
|
|
95
|
+
false);
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Finds the hook handler frame immediately above the hook-manager boundary.
|
|
99
|
+
*/
|
|
100
|
+
export function getHookExecutionFrame(frames) {
|
|
101
|
+
const hookManagerIndex = frames.findIndex(isHookHandlerBoundaryFrame);
|
|
102
|
+
if (hookManagerIndex === -1) {
|
|
103
|
+
return;
|
|
104
|
+
}
|
|
105
|
+
// The frames between hook-manager calls may include other hook-manager
|
|
106
|
+
// helpers; we want the last frame that does not belong to that file.
|
|
107
|
+
return frames
|
|
108
|
+
.slice(0, hookManagerIndex)
|
|
109
|
+
.findLast((frame) => frame.location.includes("/internal/core/hook-manager.") === false);
|
|
110
|
+
}
|
|
111
|
+
// ---------------------------------------------------------------------------
|
|
112
|
+
// Frame origin / ownership helpers
|
|
113
|
+
// ---------------------------------------------------------------------------
|
|
114
|
+
/**
|
|
115
|
+
* Returns true for stack locations owned by packages outside Hardhat.
|
|
116
|
+
*/
|
|
117
|
+
export function isThirdPartyFrame(location) {
|
|
118
|
+
return (location.includes("/node_modules/") &&
|
|
119
|
+
isFirstPartyPluginFrame(location) === false);
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Returns true for stack locations owned by Hardhat or first-party packages.
|
|
123
|
+
*/
|
|
124
|
+
export function isFirstPartyPluginFrame(location) {
|
|
125
|
+
return includesAny(location, "/node_modules/hardhat/", "/node_modules/@nomicfoundation/");
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Returns true when the error stack appears to come from workspace
|
|
129
|
+
* initialization.
|
|
130
|
+
*/
|
|
131
|
+
export function isWorkspaceInitFilesystemFrame(error) {
|
|
132
|
+
return error.stack?.includes("/internal/cli/init") ?? false;
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* Returns true for stack frames owned by EDR provider or stack-trace code.
|
|
136
|
+
*/
|
|
137
|
+
export function isEdrFrame(frame) {
|
|
138
|
+
return includesAny(frame.location, "/builtin-plugins/network-manager/edr/", "/edr-provider.");
|
|
139
|
+
}
|
|
140
|
+
//# sourceMappingURL=codebase-dependent-helpers.js.map
|
package/dist/src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"codebase-dependent-helpers.js","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-classification/codebase-dependent-helpers.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAmB,WAAW,EAAE,MAAM,cAAc,CAAC;AAE5D;;;GAGG;AACH,MAAM,UAAU,8BAA8B;IAC5C,yDAAyD;IACzD,mEAAmE;IACnE,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,oBAAoB,CAAC,CAAC;AACxD,CAAC;AAED,8EAA8E;AAC9E,4BAA4B;AAC5B,EAAE;AACF,uEAAuE;AACvE,6EAA6E;AAC7E,0EAA0E;AAC1E,4EAA4E;AAC5E,kCAAkC;AAClC,8EAA8E;AAE9E;;GAEG;AACH,MAAM,UAAU,4BAA4B,CAAC,KAAiB;IAC5D,OAAO,CACL,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,0BAA0B,CAAC;QACnD,KAAK,CAAC,YAAY,EAAE,QAAQ,CAAC,kBAAkB,CAAC,KAAK,IAAI,CAC1D,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,gCAAgC,CAAC,KAAiB;IAChE,OAAO,CACL,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,gDAAgD,CAAC;QACzE,KAAK,CAAC,YAAY,EAAE,QAAQ,CAAC,eAAe,CAAC,KAAK,IAAI,CACvD,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,8BAA8B,CAAC,KAAiB;IAC9D,OAAO,CACL,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,4CAA4C,CAAC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AO,WAAW,CAChB,KAAK,CAAC,QAAQ,EACd,uCAAuC,EACvC,gBAAgB,CACjB,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ErrorCategory } from "./classifier.js";
|
|
2
|
+
/**
|
|
3
|
+
* Decides if an error should be reported to Sentry or not, based on the
|
|
4
|
+
* category returned by `classifyError(error)`.
|
|
5
|
+
*
|
|
6
|
+
* This first version intentionally uses a permissive policy: it drops clear
|
|
7
|
+
* noise, reports categories that are likely to be Hardhat bugs, and only uses a
|
|
8
|
+
* simple stack-shape heuristic for errors coming from user/plugin execution.
|
|
9
|
+
*
|
|
10
|
+
* @param error The error.
|
|
11
|
+
* @param category The result of calling `classifyError(error)`.
|
|
12
|
+
* @returns `true` if the error should be reported.
|
|
13
|
+
*/
|
|
14
|
+
export declare function shouldBeReported(error: Error, category: ErrorCategory): boolean;
|
|
15
|
+
//# sourceMappingURL=filter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filter.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-classification/filter.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,aAAa,EAEd,MAAM,iBAAiB,CAAC;AAGzB;;;;;;;;;;;GAWG;AACH,wBAAgB,gBAAgB,CAC9B,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,aAAa,GACtB,OAAO,CA0BT"}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { HardhatError } from "@nomicfoundation/hardhat-errors";
|
|
2
|
+
import { ErrorCategory, USER_CODE_BOUNDARY_FRAME_MATCHERS, } from "./classifier.js";
|
|
3
|
+
import { FrameOrigin, createErrorContext } from "./helpers.js";
|
|
4
|
+
/**
|
|
5
|
+
* Decides if an error should be reported to Sentry or not, based on the
|
|
6
|
+
* category returned by `classifyError(error)`.
|
|
7
|
+
*
|
|
8
|
+
* This first version intentionally uses a permissive policy: it drops clear
|
|
9
|
+
* noise, reports categories that are likely to be Hardhat bugs, and only uses a
|
|
10
|
+
* simple stack-shape heuristic for errors coming from user/plugin execution.
|
|
11
|
+
*
|
|
12
|
+
* @param error The error.
|
|
13
|
+
* @param category The result of calling `classifyError(error)`.
|
|
14
|
+
* @returns `true` if the error should be reported.
|
|
15
|
+
*/
|
|
16
|
+
export function shouldBeReported(error, category) {
|
|
17
|
+
switch (category) {
|
|
18
|
+
case ErrorCategory.CJS_TO_ESM_MIGRATION_ERROR:
|
|
19
|
+
case ErrorCategory.HH2_TO_HH3_MIGRATION_ERROR:
|
|
20
|
+
case ErrorCategory.TYPESCRIPT_SUPPORT_ERROR:
|
|
21
|
+
case ErrorCategory.DEVELOPMENT_TIME_ERROR:
|
|
22
|
+
case ErrorCategory.PROVIDER_INTERACTION_ERROR:
|
|
23
|
+
case ErrorCategory.NETWORK_INTERACTION_ERROR:
|
|
24
|
+
case ErrorCategory.RUNTIME_ENVIRONMENT_ERROR:
|
|
25
|
+
return false;
|
|
26
|
+
case ErrorCategory.HARDHAT_ERROR:
|
|
27
|
+
case ErrorCategory.TASK_ACTION_ERROR:
|
|
28
|
+
case ErrorCategory.EDR_ERROR:
|
|
29
|
+
case ErrorCategory.FILESYSTEM_INTERACTION_ERROR:
|
|
30
|
+
case ErrorCategory.UNEXPECTED_ERROR:
|
|
31
|
+
return shouldReportNonUserCodeBoundaryError(error);
|
|
32
|
+
case ErrorCategory.CONFIG_LOADING_ERROR:
|
|
33
|
+
case ErrorCategory.CONSOLE_EVALUATION_ERROR:
|
|
34
|
+
case ErrorCategory.SCRIPT_EXECUTION_ERROR:
|
|
35
|
+
case ErrorCategory.NODE_TEST_EXECUTION_ERROR:
|
|
36
|
+
case ErrorCategory.MOCHA_TEST_EXECUTION_ERROR:
|
|
37
|
+
case ErrorCategory.PLUGIN_TASK_ACTION_ERROR:
|
|
38
|
+
case ErrorCategory.USER_TASK_ACTION_ERROR:
|
|
39
|
+
case ErrorCategory.PLUGIN_HOOK_HANDLER_ERROR:
|
|
40
|
+
return shouldReportUserCodeBoundaryError(error, category);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Applies the HardhatError descriptor reporting policy for categories that
|
|
45
|
+
* don't need user-code boundary inspection.
|
|
46
|
+
*/
|
|
47
|
+
function shouldReportNonUserCodeBoundaryError(error) {
|
|
48
|
+
if (HardhatError.isHardhatError(error)) {
|
|
49
|
+
return error.descriptor.shouldBeReported ?? false;
|
|
50
|
+
}
|
|
51
|
+
return true;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Applies the HardhatError descriptor policy before using stack shape to decide
|
|
55
|
+
* whether a user-code-boundary category should be reported.
|
|
56
|
+
*/
|
|
57
|
+
function shouldReportUserCodeBoundaryError(error, category) {
|
|
58
|
+
if (HardhatError.isHardhatError(error)) {
|
|
59
|
+
return error.descriptor.shouldBeReported ?? false;
|
|
60
|
+
}
|
|
61
|
+
return hasHardhatFrameBeforeBoundary(error, category);
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* User-code-boundary categories mean Hardhat called into user or plugin code.
|
|
65
|
+
* We don't want to report every plain user script/test/config/plugin failure,
|
|
66
|
+
* but we do want to report when the stack shows user/plugin code calling back
|
|
67
|
+
* into Hardhat and then Hardhat, or one of its dependencies, failing.
|
|
68
|
+
*
|
|
69
|
+
* To approximate that, this looks for a stack segment before the category's
|
|
70
|
+
* boundary frame with this shape, from the throw site down:
|
|
71
|
+
*
|
|
72
|
+
* dependency frames, optional
|
|
73
|
+
* Hardhat frame, at least one
|
|
74
|
+
* external frames, optional
|
|
75
|
+
* boundary frame
|
|
76
|
+
*
|
|
77
|
+
* In stack-array order, that means scanning from the throw site down to the
|
|
78
|
+
* boundary and looking for a first-party Hardhat frame. If a user project frame
|
|
79
|
+
* appears before that Hardhat frame, we treat the failure as user-owned and
|
|
80
|
+
* don't report it.
|
|
81
|
+
*
|
|
82
|
+
* If no boundary frame is found in the error chain, we report the error. The
|
|
83
|
+
* classifier has already assigned one of these boundary categories, so a
|
|
84
|
+
* missing boundary frame means the filter couldn't validate the expected stack
|
|
85
|
+
* shape. For this initial permissive filter, that should fail open to avoid
|
|
86
|
+
* underreporting due to async stacks, wrapping, or parser limitations.
|
|
87
|
+
*
|
|
88
|
+
* We may reconsider making the external frames required in the future, as this
|
|
89
|
+
* may be too much noise.
|
|
90
|
+
*/
|
|
91
|
+
function hasHardhatFrameBeforeBoundary(error, category) {
|
|
92
|
+
const context = createErrorContext(error);
|
|
93
|
+
const boundaryMatcher = USER_CODE_BOUNDARY_FRAME_MATCHERS[category];
|
|
94
|
+
let boundaryFrameFound = false;
|
|
95
|
+
for (const candidate of context.errorChain) {
|
|
96
|
+
const frames = context.stackFramesByError.get(candidate) ?? [];
|
|
97
|
+
const boundaryIndex = frames.findIndex(boundaryMatcher);
|
|
98
|
+
if (boundaryIndex === -1) {
|
|
99
|
+
continue;
|
|
100
|
+
}
|
|
101
|
+
boundaryFrameFound = true;
|
|
102
|
+
for (let i = 0; i < boundaryIndex; i++) {
|
|
103
|
+
const frame = frames[i];
|
|
104
|
+
if (frame.origin === FrameOrigin.USER_PROJECT) {
|
|
105
|
+
return false;
|
|
106
|
+
}
|
|
107
|
+
if (frame.origin === FrameOrigin.FIRST_PARTY) {
|
|
108
|
+
return true;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
return !boundaryFrameFound;
|
|
113
|
+
}
|
|
114
|
+
//# sourceMappingURL=filter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filter.js","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-classification/filter.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAE/D,OAAO,EAEL,aAAa,EACb,iCAAiC,GAClC,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAE/D;;;;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B,CAAC"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
export declare enum FrameOrigin {
|
|
2
|
+
FIRST_PARTY = "FIRST_PARTY",
|
|
3
|
+
THIRD_PARTY = "THIRD_PARTY",
|
|
4
|
+
USER_PROJECT = "USER_PROJECT",
|
|
5
|
+
NODE_INTERNAL = "NODE_INTERNAL",
|
|
6
|
+
OTHER = "OTHER"
|
|
7
|
+
}
|
|
8
|
+
export interface StackFrame {
|
|
9
|
+
functionName?: string;
|
|
10
|
+
location: string;
|
|
11
|
+
origin: FrameOrigin;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* The error context encapsulates the shared derived data used by classification
|
|
15
|
+
* and filtering.
|
|
16
|
+
*/
|
|
17
|
+
export interface ErrorContext {
|
|
18
|
+
error: Error;
|
|
19
|
+
errorChain: Error[];
|
|
20
|
+
lowercaseMessageByError: Map<Error, string>;
|
|
21
|
+
stackFramesByError: Map<Error, StackFrame[]>;
|
|
22
|
+
allStackFrames: StackFrame[];
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Builds the shared derived data used by classification and filtering.
|
|
26
|
+
*
|
|
27
|
+
* This keeps stack parsing and cause-chain traversal consistent across
|
|
28
|
+
* matchers, and avoids recomputing them for every category heuristic.
|
|
29
|
+
*/
|
|
30
|
+
export declare function createErrorContext(error: Error): ErrorContext;
|
|
31
|
+
/**
|
|
32
|
+
* This function should be used instead of instanceof because it is robust
|
|
33
|
+
* under the presence of multiple installations of the same package (e.g.
|
|
34
|
+
* multiple hardhat-utils versions).
|
|
35
|
+
*
|
|
36
|
+
* @param error The error
|
|
37
|
+
* @param errorClass The error class
|
|
38
|
+
* @returns true if the error has the same name as the error class
|
|
39
|
+
*/
|
|
40
|
+
export declare function hasErrorClassName(error: Error, errorClass: abstract new (...args: never[]) => Error): boolean;
|
|
41
|
+
/**
|
|
42
|
+
* Returns true when `value` contains any of the supplied substrings.
|
|
43
|
+
*/
|
|
44
|
+
export declare function includesAny(value: string | undefined, ...substrings: string[]): boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Returns a Node-style `code` string from an error or any Error cause.
|
|
47
|
+
*
|
|
48
|
+
* Traversal stops when a cause is not an Error, a cycle is detected, or
|
|
49
|
+
* `maxCauseDepth` is reached.
|
|
50
|
+
*/
|
|
51
|
+
export declare function getNodeErrorCode(error: Error, maxCauseDepth?: number): string | undefined;
|
|
52
|
+
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-classification/helpers.ts"],"names":[],"mappings":"AAAA,oBAAY,WAAW;IACrB,WAAW,gBAAgB;IAC3B,WAAW,gBAAgB;IAC3B,YAAY,iBAAiB;IAC7B,aAAa,kBAAkB;IAC/B,KAAK,UAAU;CAChB;AAED,MAAM,WAAW,UAAU;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,WAAW,CAAC;CACrB;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,KAAK,CAAC;IACb,UAAU,EAAE,KAAK,EAAE,CAAC;IACpB,uBAAuB,EAAE,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;IAC5C,kBAAkB,EAAE,GAAG,CAAC,KAAK,EAAE,UAAU,EAAE,CAAC,CAAC;IAC7C,cAAc,EAAE,UAAU,EAAE,CAAC;CAC9B;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,KAAK,GAAG,YAAY,CAoB7D;AAED;;;;;;;;GAQG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,KAAK,EACZ,UAAU,EAAE,QAAQ,MAAM,GAAG,IAAI,EAAE,KAAK,EAAE,KAAK,KAAK,GACnD,OAAO,CAET;AAED;;GAEG;AACH,wBAAgB,WAAW,CACzB,KAAK,EAAE,MAAM,GAAG,SAAS,EACzB,GAAG,UAAU,EAAE,MAAM,EAAE,GACtB,OAAO,CAKT;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAC9B,KAAK,EAAE,KAAK,EACZ,aAAa,SAAK,GACjB,MAAM,GAAG,SAAS,CAcpB"}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
export var FrameOrigin;
|
|
2
|
+
(function (FrameOrigin) {
|
|
3
|
+
FrameOrigin["FIRST_PARTY"] = "FIRST_PARTY";
|
|
4
|
+
FrameOrigin["THIRD_PARTY"] = "THIRD_PARTY";
|
|
5
|
+
FrameOrigin["USER_PROJECT"] = "USER_PROJECT";
|
|
6
|
+
FrameOrigin["NODE_INTERNAL"] = "NODE_INTERNAL";
|
|
7
|
+
FrameOrigin["OTHER"] = "OTHER";
|
|
8
|
+
})(FrameOrigin || (FrameOrigin = {}));
|
|
9
|
+
/**
|
|
10
|
+
* Builds the shared derived data used by classification and filtering.
|
|
11
|
+
*
|
|
12
|
+
* This keeps stack parsing and cause-chain traversal consistent across
|
|
13
|
+
* matchers, and avoids recomputing them for every category heuristic.
|
|
14
|
+
*/
|
|
15
|
+
export function createErrorContext(error) {
|
|
16
|
+
const errorChain = getErrorChain(error);
|
|
17
|
+
const stackFramesByError = new Map(errorChain.map((candidate) => [candidate, parseStackFrames(candidate)]));
|
|
18
|
+
return {
|
|
19
|
+
error,
|
|
20
|
+
errorChain,
|
|
21
|
+
lowercaseMessageByError: new Map(errorChain.map((candidate) => [
|
|
22
|
+
candidate,
|
|
23
|
+
candidate.message.toLowerCase(),
|
|
24
|
+
])),
|
|
25
|
+
stackFramesByError,
|
|
26
|
+
allStackFrames: errorChain.flatMap((candidate) => stackFramesByError.get(candidate) ?? []),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* This function should be used instead of instanceof because it is robust
|
|
31
|
+
* under the presence of multiple installations of the same package (e.g.
|
|
32
|
+
* multiple hardhat-utils versions).
|
|
33
|
+
*
|
|
34
|
+
* @param error The error
|
|
35
|
+
* @param errorClass The error class
|
|
36
|
+
* @returns true if the error has the same name as the error class
|
|
37
|
+
*/
|
|
38
|
+
export function hasErrorClassName(error, errorClass) {
|
|
39
|
+
return error.name === errorClass.name;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Returns true when `value` contains any of the supplied substrings.
|
|
43
|
+
*/
|
|
44
|
+
export function includesAny(value, ...substrings) {
|
|
45
|
+
return (value !== undefined &&
|
|
46
|
+
substrings.some((substring) => value.includes(substring)));
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Returns a Node-style `code` string from an error or any Error cause.
|
|
50
|
+
*
|
|
51
|
+
* Traversal stops when a cause is not an Error, a cycle is detected, or
|
|
52
|
+
* `maxCauseDepth` is reached.
|
|
53
|
+
*/
|
|
54
|
+
export function getNodeErrorCode(error, maxCauseDepth = 10) {
|
|
55
|
+
const seen = new Set();
|
|
56
|
+
let current = error;
|
|
57
|
+
let depth = 0;
|
|
58
|
+
while (current !== undefined && depth < maxCauseDepth && !seen.has(current)) {
|
|
59
|
+
if ("code" in current && typeof current.code === "string") {
|
|
60
|
+
return current.code;
|
|
61
|
+
}
|
|
62
|
+
seen.add(current);
|
|
63
|
+
current = getCause(current);
|
|
64
|
+
depth++;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Returns the error and its nested causes in outer-to-inner order.
|
|
69
|
+
*
|
|
70
|
+
* Traversal stops when a cause is not an Error, a cycle is detected, or
|
|
71
|
+
* `maxCauseDepth` is reached.
|
|
72
|
+
*/
|
|
73
|
+
function getErrorChain(error, maxCauseDepth = 10) {
|
|
74
|
+
const errors = [];
|
|
75
|
+
const seen = new Set();
|
|
76
|
+
let current = error;
|
|
77
|
+
while (current !== undefined &&
|
|
78
|
+
errors.length < maxCauseDepth &&
|
|
79
|
+
seen.has(current) === false) {
|
|
80
|
+
errors.push(current);
|
|
81
|
+
seen.add(current);
|
|
82
|
+
if (current.cause !== undefined && !(current.cause instanceof Error)) {
|
|
83
|
+
break;
|
|
84
|
+
}
|
|
85
|
+
current = getCause(current);
|
|
86
|
+
}
|
|
87
|
+
return errors;
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Parses V8-style stack lines into normalized stack frames.
|
|
91
|
+
*
|
|
92
|
+
* Unrecognized lines are ignored, and path separators are normalized to `/`
|
|
93
|
+
* before the frame origin is inferred.
|
|
94
|
+
*/
|
|
95
|
+
function parseStackFrames(error) {
|
|
96
|
+
if (error.stack === undefined) {
|
|
97
|
+
return [];
|
|
98
|
+
}
|
|
99
|
+
return error.stack
|
|
100
|
+
.split("\n")
|
|
101
|
+
.slice(1)
|
|
102
|
+
.map((line) => line.trim())
|
|
103
|
+
.map(parseStackFrameLine)
|
|
104
|
+
.filter((frame) => frame !== undefined);
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Parses a single V8 stack frame line.
|
|
108
|
+
*/
|
|
109
|
+
function parseStackFrameLine(line) {
|
|
110
|
+
const match = line.match(/^at (?:(.+?) \()?(.+?):\d+:\d+\)?$/) ??
|
|
111
|
+
line.match(/^at (?:(.+?) \()?(.+?)\)?$/);
|
|
112
|
+
if (match === null || match[2] === undefined) {
|
|
113
|
+
return;
|
|
114
|
+
}
|
|
115
|
+
const functionName = match[1] === undefined ? undefined : match[1].trim();
|
|
116
|
+
const location = normalizeLocation(match[2]);
|
|
117
|
+
return {
|
|
118
|
+
functionName,
|
|
119
|
+
location,
|
|
120
|
+
origin: getFrameOrigin(location),
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* Returns the Error-valued cause of an error, ignoring non-Error causes.
|
|
125
|
+
*/
|
|
126
|
+
function getCause(error) {
|
|
127
|
+
if ("cause" in error && error.cause instanceof Error) {
|
|
128
|
+
return error.cause;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* Normalizes Windows paths and file URLs enough for substring-based matchers.
|
|
133
|
+
*/
|
|
134
|
+
function normalizeLocation(location) {
|
|
135
|
+
return location.replaceAll("\\", "/");
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Infers who owns a stack frame from its normalized location.
|
|
139
|
+
*/
|
|
140
|
+
function getFrameOrigin(location) {
|
|
141
|
+
if (startsWithAny(location, "node:", "internal/") ||
|
|
142
|
+
includesAny(location, "node:internal/")) {
|
|
143
|
+
return FrameOrigin.NODE_INTERNAL;
|
|
144
|
+
}
|
|
145
|
+
if (location.includes("/node_modules/")) {
|
|
146
|
+
if (includesAny(location, "/node_modules/hardhat/", "/node_modules/@nomicfoundation/")) {
|
|
147
|
+
return FrameOrigin.FIRST_PARTY;
|
|
148
|
+
}
|
|
149
|
+
return FrameOrigin.THIRD_PARTY;
|
|
150
|
+
}
|
|
151
|
+
if (startsWithAny(location, "/", "file://", "[eval]") ||
|
|
152
|
+
/^[A-Za-z]:\//.test(location)) {
|
|
153
|
+
return FrameOrigin.USER_PROJECT;
|
|
154
|
+
}
|
|
155
|
+
return FrameOrigin.OTHER;
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Returns true when `value` starts with any of the supplied prefixes.
|
|
159
|
+
*/
|
|
160
|
+
function startsWithAny(value, ...prefixes) {
|
|
161
|
+
return prefixes.some((prefix) => value.startsWith(prefix));
|
|
162
|
+
}
|
|
163
|
+
//# sourceMappingURL=helpers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-classification/helpers.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,WAMX;AAND,WAAY,WAAW;IACrB,0CAA2B,CAAA;IAC3B,0CAA2B,CAAA;IAC3B,4CAA6B,CAAA;IAC7B,8CAA+B,CAAA;IAC/B,8BAAe,CAAA;AACjB,CAAC,EANW,WAAW,KAAX,WAAW,QAMtB;AAoBD;;;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,QAAQ,EAAE,gBAAgB,CAAC,EACvC,CAAC;QACD,OAAO,WAAW,CAAC,aAAa,CAAC;IACnC,CAAC;IAED,IAAI,QAAQ,CAAC,QAAQ,CAAC,gBAAgB,CAAC,EAAE,CAAC;QACxC,IACE,WAAW,CACT,QAAQ,EACR,wBAAwB,EACxB,iCAAiC,CAClC,EACD,CAAC;YACD,OAAO,WAAW,CAAC,WAAW,CAAC;QACjC,CAAC;QAED,OAAO,WAAW,CAAC,WAAW,CAAC;IACjC,CAAC;IAED,IACE,aAAa,CAAC,QAAQ,EAAE,GAAG,EAAE,SAAS,EAAE,QAAQ,CAAC;QACjD,cAAc,CAAC,IAAI,CAAC,QAAQ,CAAC,EAC7B,CAAC;QACD,OAAO,WAAW,CAAC,YAAY,CAAC;IAClC,CAAC;IAED,OAAO,WAAW,CAAC,KAAK,CAAC;AAC3B,CAAC;AAED;;GAEG;AACH,SAAS,aAAa,CAAC,KAAa,EAAE,GAAG,QAAkB;IACzD,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;AAC7D,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reporter.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-reporter/reporter.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"reporter.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-reporter/reporter.ts"],"names":[],"mappings":"AAiBA;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,kBAAkB,CACtC,KAAK,EAAE,KAAK,EACZ,IAAI,CAAC,EAAE;IAAE,SAAS,CAAC,EAAE,OAAO,CAAC;IAAC,aAAa,CAAC,EAAE,MAAM,CAAA;CAAE,GACrD,OAAO,CAAC,IAAI,CAAC,CAwBf;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,UAAU,EAAE,MAAM,GAAG,IAAI,CAEhE"}
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
// Sentry's reporter loads a large number of modules, so we only load it if
|
|
2
2
|
// needed.
|
|
3
3
|
let sentryReporterModule;
|
|
4
|
+
// The classifier and filter modules are small, but they may import many
|
|
5
|
+
// unrelated things top-level to do their job, so we also load them lazily.
|
|
6
|
+
let classifierModule;
|
|
7
|
+
let filterModule;
|
|
4
8
|
// We cache the `setCliHardhatConfigPath` to avoid loading the reporter just
|
|
5
9
|
// for this setting. We load it and set the config path if needed.
|
|
6
10
|
let cliHardhatConfigPath;
|
|
@@ -22,6 +26,16 @@ let cliHardhatConfigPath;
|
|
|
22
26
|
* `"instrument"`, and `"generic"`. Defaults to `"generic"`.
|
|
23
27
|
*/
|
|
24
28
|
export async function sendErrorTelemetry(error, hint) {
|
|
29
|
+
if (classifierModule === undefined) {
|
|
30
|
+
classifierModule = await import("../error-classification/classifier.js");
|
|
31
|
+
}
|
|
32
|
+
if (filterModule === undefined) {
|
|
33
|
+
filterModule = await import("../error-classification/filter.js");
|
|
34
|
+
}
|
|
35
|
+
const category = classifierModule.classifyError(error);
|
|
36
|
+
if (!filterModule.shouldBeReported(error, category)) {
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
25
39
|
if (sentryReporterModule === undefined) {
|
|
26
40
|
sentryReporterModule = await import("../sentry/reporter.js");
|
|
27
41
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reporter.js","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-reporter/reporter.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"reporter.js","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/error-reporter/reporter.ts"],"names":[],"mappings":"AAIA,2EAA2E;AAC3E,UAAU;AACV,IAAI,oBAAwD,CAAC;AAE7D,wEAAwE;AACxE,2EAA2E;AAC3E,IAAI,gBAAgD,CAAC;AACrD,IAAI,YAAwC,CAAC;AAE7C,4EAA4E;AAC5E,kEAAkE;AAClE,IAAI,oBAAwC,CAAC;AAE7C;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,KAAY,EACZ,IAAsD;IAEtD,IAAI,gBAAgB,KAAK,SAAS,EAAE,CAAC;QACnC,gBAAgB,GAAG,MAAM,MAAM,CAAC,uCAAuC,CAAC,CAAC;IAC3E,CAAC;IAED,IAAI,YAAY,KAAK,SAAS,EAAE,CAAC;QAC/B,YAAY,GAAG,MAAM,MAAM,CAAC,mCAAmC,CAAC,CAAC;IACnE,CAAC;IAED,MAAM,QAAQ,GAAG,gBAAgB,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IAEvD,IAAI,CAAC,YAAY,CAAC,gBAAgB,CAAC,KAAK,EAAE,QAAQ,CAAC,EAAE,CAAC;QACpD,OAAO;IACT,CAAC;IAED,IAAI,oBAAoB,KAAK,SAAS,EAAE,CAAC;QACvC,oBAAoB,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,CAAC;IAC/D,CAAC;IAED,IAAI,oBAAoB,KAAK,SAAS,EAAE,CAAC;QACvC,oBAAoB,CAAC,uBAAuB,CAAC,oBAAoB,CAAC,CAAC;IACrE,CAAC;IAED,MAAM,oBAAoB,CAAC,kBAAkB,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;AAC7D,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,uBAAuB,CAAC,UAAkB;IACxD,oBAAoB,GAAG,UAAU,CAAC;AACpC,CAAC"}
|
|
@@ -35,7 +35,5 @@ export declare class Anonymizer {
|
|
|
35
35
|
anonymizeContent: boolean;
|
|
36
36
|
}>;
|
|
37
37
|
anonymizeErrorMessage(errorMessage: string): string;
|
|
38
|
-
filterOutEventsWithExceptionsNotRaisedByHardhat(envelope: Envelope): Envelope;
|
|
39
|
-
raisedByHardhat(event: Event): boolean;
|
|
40
38
|
}
|
|
41
39
|
//# sourceMappingURL=anonymizer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"anonymizer.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/sentry/anonymizer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,QAAQ,EACR,KAAK,EAKN,MAAM,cAAc,CAAC;AAwBtB,MAAM,MAAM,uBAAuB,GAC/B;IAAE,OAAO,EAAE,IAAI,CAAC;IAAC,QAAQ,EAAE,QAAQ,CAAA;CAAE,GACrC;IAAE,OAAO,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAEtC,MAAM,MAAM,oBAAoB,GAC5B;IAAE,OAAO,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,KAAK,CAAA;CAAE,GAC/B;IAAE,OAAO,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAMtC,qBAAa,UAAU;;gBAGT,UAAU,CAAC,EAAE,MAAM;IAI/B;;OAEG;IACU,2BAA2B,CACtC,QAAQ,EAAE,QAAQ,GACjB,OAAO,CAAC,uBAAuB,CAAC;IAmBnC;;;;OAIG;IACU,cAAc,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC,oBAAoB,CAAC;IA0BxE;;;OAGG;IACU,iBAAiB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC;QACxD,kBAAkB,EAAE,MAAM,CAAC;QAC3B,gBAAgB,EAAE,OAAO,CAAC;KAC3B,CAAC;IAsBK,qBAAqB,CAAC,YAAY,EAAE,MAAM,GAAG,MAAM;
|
|
1
|
+
{"version":3,"file":"anonymizer.d.ts","sourceRoot":"","sources":["../../../../../../src/internal/cli/telemetry/sentry/anonymizer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,QAAQ,EACR,KAAK,EAKN,MAAM,cAAc,CAAC;AAwBtB,MAAM,MAAM,uBAAuB,GAC/B;IAAE,OAAO,EAAE,IAAI,CAAC;IAAC,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