@forklaunch/express 0.9.30 → 0.9.32
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/lib/index.js +18 -12
- package/lib/index.mjs +18 -12
- package/package.json +4 -4
package/lib/index.js
CHANGED
|
@@ -84,11 +84,11 @@ var BunSocketShim = class extends import_stream.Duplex {
|
|
|
84
84
|
allowHalfOpen: false,
|
|
85
85
|
objectMode: false
|
|
86
86
|
});
|
|
87
|
-
this.remoteAddress = options2.remoteAddress
|
|
88
|
-
this.remotePort = options2.remotePort
|
|
87
|
+
this.remoteAddress = options2.remoteAddress ?? "127.0.0.1";
|
|
88
|
+
this.remotePort = options2.remotePort ?? 0;
|
|
89
89
|
this.remoteFamily = "IPv4";
|
|
90
|
-
this.localAddress = options2.localAddress
|
|
91
|
-
this.localPort = options2.localPort
|
|
90
|
+
this.localAddress = options2.localAddress ?? "localhost";
|
|
91
|
+
this.localPort = options2.localPort ?? 0;
|
|
92
92
|
this.localFamily = "IPv4";
|
|
93
93
|
this._abortController = options2.abortController || new AbortController();
|
|
94
94
|
this._request = options2.request;
|
|
@@ -212,9 +212,9 @@ var BunSocketShim = class extends import_stream.Duplex {
|
|
|
212
212
|
this.localFamily = "IPv4";
|
|
213
213
|
} else if (typeof optionsPortOrPath === "string") {
|
|
214
214
|
this.remoteAddress = optionsPortOrPath;
|
|
215
|
-
this.remotePort =
|
|
215
|
+
this.remotePort = 0;
|
|
216
216
|
this.localAddress = optionsPortOrPath;
|
|
217
|
-
this.localPort =
|
|
217
|
+
this.localPort = 0;
|
|
218
218
|
this.remoteFamily = "Unix";
|
|
219
219
|
this.localFamily = "Unix";
|
|
220
220
|
listener = typeof hostOrConnectionListener === "function" ? hostOrConnectionListener : connectionListener;
|
|
@@ -222,9 +222,9 @@ var BunSocketShim = class extends import_stream.Duplex {
|
|
|
222
222
|
const options2 = optionsPortOrPath;
|
|
223
223
|
if ("path" in options2) {
|
|
224
224
|
this.remoteAddress = options2.path;
|
|
225
|
-
this.remotePort =
|
|
225
|
+
this.remotePort = 0;
|
|
226
226
|
this.localAddress = options2.path;
|
|
227
|
-
this.localPort =
|
|
227
|
+
this.localPort = 0;
|
|
228
228
|
this.remoteFamily = "Unix";
|
|
229
229
|
this.localFamily = "Unix";
|
|
230
230
|
} else {
|
|
@@ -250,8 +250,12 @@ var BunSocketShim = class extends import_stream.Duplex {
|
|
|
250
250
|
this.connecting = false;
|
|
251
251
|
this.pending = false;
|
|
252
252
|
this.readyState = "open";
|
|
253
|
-
|
|
254
|
-
|
|
253
|
+
if (port !== void 0) {
|
|
254
|
+
this.remotePort = port;
|
|
255
|
+
}
|
|
256
|
+
if (host !== void 0) {
|
|
257
|
+
this.remoteAddress = host;
|
|
258
|
+
}
|
|
255
259
|
this.emit("connect");
|
|
256
260
|
});
|
|
257
261
|
return this;
|
|
@@ -2098,7 +2102,8 @@ var Application = class extends import_http3.ForklaunchExpressLikeApplication {
|
|
|
2098
2102
|
path: mcpPath,
|
|
2099
2103
|
version,
|
|
2100
2104
|
additionalTools,
|
|
2101
|
-
contentTypeMapping
|
|
2105
|
+
contentTypeMapping,
|
|
2106
|
+
authenticate
|
|
2102
2107
|
} = this.mcpConfiguration ?? {};
|
|
2103
2108
|
const zodSchemaValidator = this.schemaValidator;
|
|
2104
2109
|
const finalMcpPort = mcpPort ?? port + 2e3;
|
|
@@ -2111,7 +2116,8 @@ var Application = class extends import_http3.ForklaunchExpressLikeApplication {
|
|
|
2111
2116
|
this,
|
|
2112
2117
|
this.mcpConfiguration,
|
|
2113
2118
|
options2,
|
|
2114
|
-
contentTypeMapping
|
|
2119
|
+
contentTypeMapping,
|
|
2120
|
+
authenticate
|
|
2115
2121
|
);
|
|
2116
2122
|
if (additionalTools) {
|
|
2117
2123
|
additionalTools(mcpServer);
|
package/lib/index.mjs
CHANGED
|
@@ -55,11 +55,11 @@ var BunSocketShim = class extends Duplex {
|
|
|
55
55
|
allowHalfOpen: false,
|
|
56
56
|
objectMode: false
|
|
57
57
|
});
|
|
58
|
-
this.remoteAddress = options2.remoteAddress
|
|
59
|
-
this.remotePort = options2.remotePort
|
|
58
|
+
this.remoteAddress = options2.remoteAddress ?? "127.0.0.1";
|
|
59
|
+
this.remotePort = options2.remotePort ?? 0;
|
|
60
60
|
this.remoteFamily = "IPv4";
|
|
61
|
-
this.localAddress = options2.localAddress
|
|
62
|
-
this.localPort = options2.localPort
|
|
61
|
+
this.localAddress = options2.localAddress ?? "localhost";
|
|
62
|
+
this.localPort = options2.localPort ?? 0;
|
|
63
63
|
this.localFamily = "IPv4";
|
|
64
64
|
this._abortController = options2.abortController || new AbortController();
|
|
65
65
|
this._request = options2.request;
|
|
@@ -183,9 +183,9 @@ var BunSocketShim = class extends Duplex {
|
|
|
183
183
|
this.localFamily = "IPv4";
|
|
184
184
|
} else if (typeof optionsPortOrPath === "string") {
|
|
185
185
|
this.remoteAddress = optionsPortOrPath;
|
|
186
|
-
this.remotePort =
|
|
186
|
+
this.remotePort = 0;
|
|
187
187
|
this.localAddress = optionsPortOrPath;
|
|
188
|
-
this.localPort =
|
|
188
|
+
this.localPort = 0;
|
|
189
189
|
this.remoteFamily = "Unix";
|
|
190
190
|
this.localFamily = "Unix";
|
|
191
191
|
listener = typeof hostOrConnectionListener === "function" ? hostOrConnectionListener : connectionListener;
|
|
@@ -193,9 +193,9 @@ var BunSocketShim = class extends Duplex {
|
|
|
193
193
|
const options2 = optionsPortOrPath;
|
|
194
194
|
if ("path" in options2) {
|
|
195
195
|
this.remoteAddress = options2.path;
|
|
196
|
-
this.remotePort =
|
|
196
|
+
this.remotePort = 0;
|
|
197
197
|
this.localAddress = options2.path;
|
|
198
|
-
this.localPort =
|
|
198
|
+
this.localPort = 0;
|
|
199
199
|
this.remoteFamily = "Unix";
|
|
200
200
|
this.localFamily = "Unix";
|
|
201
201
|
} else {
|
|
@@ -221,8 +221,12 @@ var BunSocketShim = class extends Duplex {
|
|
|
221
221
|
this.connecting = false;
|
|
222
222
|
this.pending = false;
|
|
223
223
|
this.readyState = "open";
|
|
224
|
-
|
|
225
|
-
|
|
224
|
+
if (port !== void 0) {
|
|
225
|
+
this.remotePort = port;
|
|
226
|
+
}
|
|
227
|
+
if (host !== void 0) {
|
|
228
|
+
this.remoteAddress = host;
|
|
229
|
+
}
|
|
226
230
|
this.emit("connect");
|
|
227
231
|
});
|
|
228
232
|
return this;
|
|
@@ -2071,7 +2075,8 @@ var Application = class extends ForklaunchExpressLikeApplication {
|
|
|
2071
2075
|
path: mcpPath,
|
|
2072
2076
|
version,
|
|
2073
2077
|
additionalTools,
|
|
2074
|
-
contentTypeMapping
|
|
2078
|
+
contentTypeMapping,
|
|
2079
|
+
authenticate
|
|
2075
2080
|
} = this.mcpConfiguration ?? {};
|
|
2076
2081
|
const zodSchemaValidator = this.schemaValidator;
|
|
2077
2082
|
const finalMcpPort = mcpPort ?? port + 2e3;
|
|
@@ -2084,7 +2089,8 @@ var Application = class extends ForklaunchExpressLikeApplication {
|
|
|
2084
2089
|
this,
|
|
2085
2090
|
this.mcpConfiguration,
|
|
2086
2091
|
options2,
|
|
2087
|
-
contentTypeMapping
|
|
2092
|
+
contentTypeMapping,
|
|
2093
|
+
authenticate
|
|
2088
2094
|
);
|
|
2089
2095
|
if (additionalTools) {
|
|
2090
2096
|
additionalTools(mcpServer);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forklaunch/express",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.32",
|
|
4
4
|
"description": "Forklaunch framework for express.",
|
|
5
5
|
"homepage": "https://github.com/forklaunch/forklaunch-js#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -37,9 +37,9 @@
|
|
|
37
37
|
"qs": "^6.14.0",
|
|
38
38
|
"range-parser": "^1.2.1",
|
|
39
39
|
"swagger-ui-express": "^5.0.1",
|
|
40
|
-
"@forklaunch/common": "0.6.
|
|
41
|
-
"@forklaunch/
|
|
42
|
-
"@forklaunch/
|
|
40
|
+
"@forklaunch/common": "0.6.22",
|
|
41
|
+
"@forklaunch/core": "0.16.0",
|
|
42
|
+
"@forklaunch/validator": "0.10.22"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"@eslint/js": "^9.38.0",
|