@hydranium/core 1.0.0-next.367 → 1.0.0-next.369
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.
|
@@ -29,8 +29,8 @@ export declare function isConnectionGoneError(err: unknown): boolean;
|
|
|
29
29
|
/**
|
|
30
30
|
* Whether `err` means the client a connection serves has gone: what
|
|
31
31
|
* {@link isConnectionGoneError} recognises, or a write to a socket the client
|
|
32
|
-
* closed (`EPIPE`, `ECONNRESET`), matched by code or, for a
|
|
33
|
-
* code's name in the message.
|
|
32
|
+
* closed (`EPIPE`, `ECONNRESET`, `ECONNABORTED`), matched by code or, for a
|
|
33
|
+
* request, by the code's name in the message.
|
|
34
34
|
*
|
|
35
35
|
* Only for a call whose errors can come from that connection alone. A socket
|
|
36
36
|
* error names no peer, so where a file system or another socket can fail the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connection-liveness.d.ts","sourceRoot":"","sources":["../../src/util/connection-liveness.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAkDlF;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAO3D;
|
|
1
|
+
{"version":3,"file":"connection-liveness.d.ts","sourceRoot":"","sources":["../../src/util/connection-liveness.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAkDlF;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAO3D;AAQD;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAUvD"}
|
|
@@ -77,14 +77,15 @@ export function isConnectionGoneError(err) {
|
|
|
77
77
|
const normalized = message.toLowerCase();
|
|
78
78
|
return CONNECTION_GONE_PATTERNS.some(pattern => pattern.test(normalized));
|
|
79
79
|
}
|
|
80
|
-
|
|
80
|
+
// Windows reports a write to a socket the peer aborted as `ECONNABORTED`.
|
|
81
|
+
const SOCKET_GONE_CODES = new Set(['EPIPE', 'ECONNRESET', 'ECONNABORTED']);
|
|
81
82
|
/** `write EPIPE` / `read ECONNRESET`, as a request's `ResponseError` copies the message. */
|
|
82
|
-
const SOCKET_GONE_PATTERN = /\b(epipe|econnreset)\b/;
|
|
83
|
+
const SOCKET_GONE_PATTERN = /\b(epipe|econnreset|econnaborted)\b/;
|
|
83
84
|
/**
|
|
84
85
|
* Whether `err` means the client a connection serves has gone: what
|
|
85
86
|
* {@link isConnectionGoneError} recognises, or a write to a socket the client
|
|
86
|
-
* closed (`EPIPE`, `ECONNRESET`), matched by code or, for a
|
|
87
|
-
* code's name in the message.
|
|
87
|
+
* closed (`EPIPE`, `ECONNRESET`, `ECONNABORTED`), matched by code or, for a
|
|
88
|
+
* request, by the code's name in the message.
|
|
88
89
|
*
|
|
89
90
|
* Only for a call whose errors can come from that connection alone. A socket
|
|
90
91
|
* error names no peer, so where a file system or another socket can fail the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connection-liveness.js","sourceRoot":"","sources":["../../src/util/connection-liveness.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,wBAAwB,GAAG;IAC9B,wBAAwB;IACxB,sBAAsB;IACtB,yBAAyB;IACzB,uBAAuB;IACvB,8BAA8B;CAChC,CAAC;AAEF,MAAM,qBAAqB,GAAG,sBAAsB,CAAC;AAErD,SAAS,sBAAsB,CAAC,GAAY;IACzC,OAAO,SAAS,CAAC,GAAG,CAAC,KAAK,qBAAqB,CAAC;AACnD,CAAC;AAED,wHAAwH;AACxH,SAAS,SAAS,CAAC,GAAY;IAC5B,IAAI,CAAC;QACF,OAAO,GAAG,YAAY,KAAK,IAAI,MAAM,IAAI,GAAG,CAAC,CAAC,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3
|
+
"version": "1.0.0-next.369",
|
|
4
4
|
"description": "Foundational runtime of the hydranium framework: AST coordination layer (services, integrity, AST extension, serialization, multi-client documents) plus the LSP textual head at the /lsp subpath. Consumed by protocol-head packages (@hydranium/data-server, @hydranium/glsp-server).",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ast",
|
|
@@ -87,8 +87,8 @@
|
|
|
87
87
|
"diff": "^5.2.0"
|
|
88
88
|
},
|
|
89
89
|
"devDependencies": {
|
|
90
|
-
"@hydranium/langium": "1.0.0-next.
|
|
91
|
-
"@hydranium/protocol": "1.0.0-next.
|
|
90
|
+
"@hydranium/langium": "1.0.0-next.369",
|
|
91
|
+
"@hydranium/protocol": "1.0.0-next.369",
|
|
92
92
|
"@playwright/test": "^1.55.0",
|
|
93
93
|
"@types/diff": "^5.2.0",
|
|
94
94
|
"fake-indexeddb": "^6.2.5",
|
|
@@ -101,8 +101,8 @@
|
|
|
101
101
|
"vscode-languageserver-types": "3.18.0"
|
|
102
102
|
},
|
|
103
103
|
"peerDependencies": {
|
|
104
|
-
"@hydranium/langium": "1.0.0-next.
|
|
105
|
-
"@hydranium/protocol": "1.0.0-next.
|
|
104
|
+
"@hydranium/langium": "1.0.0-next.369",
|
|
105
|
+
"@hydranium/protocol": "1.0.0-next.369",
|
|
106
106
|
"@playwright/test": "^1.40.0",
|
|
107
107
|
"vscode-jsonrpc": "^9.0.0",
|
|
108
108
|
"vscode-languageserver": "~10.0.1",
|
|
@@ -83,16 +83,17 @@ export function isConnectionGoneError(err: unknown): boolean {
|
|
|
83
83
|
return CONNECTION_GONE_PATTERNS.some(pattern => pattern.test(normalized));
|
|
84
84
|
}
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
// Windows reports a write to a socket the peer aborted as `ECONNABORTED`.
|
|
87
|
+
const SOCKET_GONE_CODES = new Set(['EPIPE', 'ECONNRESET', 'ECONNABORTED']);
|
|
87
88
|
|
|
88
89
|
/** `write EPIPE` / `read ECONNRESET`, as a request's `ResponseError` copies the message. */
|
|
89
|
-
const SOCKET_GONE_PATTERN = /\b(epipe|econnreset)\b/;
|
|
90
|
+
const SOCKET_GONE_PATTERN = /\b(epipe|econnreset|econnaborted)\b/;
|
|
90
91
|
|
|
91
92
|
/**
|
|
92
93
|
* Whether `err` means the client a connection serves has gone: what
|
|
93
94
|
* {@link isConnectionGoneError} recognises, or a write to a socket the client
|
|
94
|
-
* closed (`EPIPE`, `ECONNRESET`), matched by code or, for a
|
|
95
|
-
* code's name in the message.
|
|
95
|
+
* closed (`EPIPE`, `ECONNRESET`, `ECONNABORTED`), matched by code or, for a
|
|
96
|
+
* request, by the code's name in the message.
|
|
96
97
|
*
|
|
97
98
|
* Only for a call whose errors can come from that connection alone. A socket
|
|
98
99
|
* error names no peer, so where a file system or another socket can fail the
|