@forge/cli-shared 9.3.1-next.1-experimental-0b00ed8 → 9.3.1-next.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.
- package/CHANGELOG.md +2 -8
- package/out/apps/template-module.d.ts.map +1 -1
- package/out/apps/template-module.js +5 -4
- package/out/apps/template.d.ts.map +1 -1
- package/out/apps/template.js +10 -4
- package/out/graphql/graphql-types.d.ts +66 -0
- package/out/graphql/graphql-types.d.ts.map +1 -1
- package/out/graphql/graphql-types.js +52 -30
- package/out/graphql/minimal-graphql-runner.d.ts +2 -1
- package/out/graphql/minimal-graphql-runner.d.ts.map +1 -1
- package/out/http-client/feedback-post-client.d.ts +1 -0
- package/out/http-client/feedback-post-client.d.ts.map +1 -1
- package/out/http-client/feedback-post-client.js +3 -1
- package/out/http-client/file-uploader.d.ts.map +1 -1
- package/out/http-client/file-uploader.js +9 -36
- package/out/http-client/global-edge-http-client.d.ts +1 -0
- package/out/http-client/global-edge-http-client.d.ts.map +1 -1
- package/out/http-client/trace.d.ts +2 -3
- package/out/http-client/trace.d.ts.map +1 -1
- package/out/service/statsig-service.d.ts.map +1 -1
- package/out/service/statsig-service.js +4 -2
- package/out/shared/error-handling.d.ts.map +1 -1
- package/out/shared/error-handling.js +4 -30
- package/package.json +2 -2
|
@@ -11,40 +11,14 @@ const assistant_cli_1 = require("./assistant-cli");
|
|
|
11
11
|
function isErrorWithAnalytics(e) {
|
|
12
12
|
return e.getAttributes !== undefined;
|
|
13
13
|
}
|
|
14
|
-
const NETWORK_CONNECTIVITY_ERROR_CODES = new Set([
|
|
15
|
-
'ENOTFOUND',
|
|
16
|
-
'ECONNRESET',
|
|
17
|
-
'ECONNREFUSED',
|
|
18
|
-
'ECONNABORTED',
|
|
19
|
-
'ENETUNREACH',
|
|
20
|
-
'EHOSTUNREACH',
|
|
21
|
-
'EAI_AGAIN',
|
|
22
|
-
'ETIMEDOUT',
|
|
23
|
-
'UND_ERR_CONNECT_TIMEOUT',
|
|
24
|
-
'UND_ERR_HEADERS_TIMEOUT',
|
|
25
|
-
'UND_ERR_SOCKET'
|
|
26
|
-
]);
|
|
27
|
-
function isLikelyNetworkError(e) {
|
|
28
|
-
if (!(e instanceof Error)) {
|
|
29
|
-
return false;
|
|
30
|
-
}
|
|
31
|
-
if (e instanceof TypeError && e.message === 'fetch failed') {
|
|
32
|
-
const causeCode = e.cause && typeof e.cause === 'object' && typeof e.cause.code === 'string'
|
|
33
|
-
? e.cause.code
|
|
34
|
-
: undefined;
|
|
35
|
-
return causeCode ? NETWORK_CONNECTIVITY_ERROR_CODES.has(causeCode) : false;
|
|
36
|
-
}
|
|
37
|
-
if (e.constructor?.name === 'FetchError' && e.type === 'system') {
|
|
38
|
-
return true;
|
|
39
|
-
}
|
|
40
|
-
return false;
|
|
41
|
-
}
|
|
42
14
|
function isUserError(e) {
|
|
43
15
|
if (isErrorWithAnalytics(e)) {
|
|
44
16
|
return e.getAttributes().isUserError ?? false;
|
|
45
17
|
}
|
|
46
|
-
if (
|
|
47
|
-
|
|
18
|
+
if (e.constructor?.name === 'FetchError') {
|
|
19
|
+
if (e.type === 'system') {
|
|
20
|
+
return true;
|
|
21
|
+
}
|
|
48
22
|
}
|
|
49
23
|
return false;
|
|
50
24
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forge/cli-shared",
|
|
3
|
-
"version": "9.3.1-next.
|
|
3
|
+
"version": "9.3.1-next.2",
|
|
4
4
|
"description": "Common functionality for Forge CLI",
|
|
5
5
|
"author": "Atlassian",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"generate-graphql-types": "graphql-codegen --config src/graphql/codegen.yml"
|
|
13
13
|
},
|
|
14
14
|
"dependencies": {
|
|
15
|
-
"@forge/manifest": "13.3.0
|
|
15
|
+
"@forge/manifest": "13.3.1-next.0",
|
|
16
16
|
"@forge/util": "3.0.0",
|
|
17
17
|
"@forge/i18n": "1.0.0",
|
|
18
18
|
"@sentry/node": "7.106.0",
|