@introspection-ai/recipes 0.19.2 → 0.20.0
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/dist/agents.d.ts +17 -1
- package/dist/agents.d.ts.map +1 -1
- package/dist/agents.js +15 -1
- package/dist/agents.js.map +1 -1
- package/dist/child-agent.d.ts +3 -1
- package/dist/child-agent.d.ts.map +1 -1
- package/dist/child-agent.js +1 -0
- package/dist/child-agent.js.map +1 -1
- package/dist/mcp-chunks/{auth-command-3K7V3VCW.js → auth-command-IQ4J332A.js} +26 -38
- package/dist/mcp-chunks/call-arguments-MCCBPJMY.js +15 -0
- package/dist/mcp-chunks/{call-command-OFPHPFM5.js → call-command-WPQ3MDOE.js} +74 -40
- package/dist/mcp-chunks/{chunk-LNSUME65.js → chunk-24FKKIXI.js} +29 -13
- package/dist/mcp-chunks/{chunk-HTZ2URXW.js → chunk-2CTVPSHF.js} +3 -3
- package/dist/mcp-chunks/{chunk-NCXEJ35U.js → chunk-3FB4ZJ4Z.js} +4 -4
- package/dist/mcp-chunks/{chunk-P3RN22HQ.js → chunk-3MIFROM7.js} +3 -2
- package/dist/mcp-chunks/{chunk-GFYTST6N.js → chunk-54UGGTOX.js} +1 -1
- package/dist/mcp-chunks/{chunk-L4VKBFYI.js → chunk-5HQYKAE7.js} +101 -16
- package/dist/mcp-chunks/{chunk-E6RVTWJY.js → chunk-5YBCGQA7.js} +1 -1
- package/dist/mcp-chunks/{chunk-6D6KPSXN.js → chunk-AJPFOQLF.js} +1 -1
- package/dist/mcp-chunks/{chunk-C2PQFLWS.js → chunk-B4XFULJ6.js} +15 -6
- package/dist/mcp-chunks/{chunk-HAO6PL7Z.js → chunk-DIIFWDZ7.js} +7 -7
- package/dist/mcp-chunks/{chunk-55JIHDU3.js → chunk-EEYUPDRX.js} +1 -1
- package/dist/mcp-chunks/{chunk-7A63PAGP.js → chunk-ETYYCEQF.js} +21 -5
- package/dist/mcp-chunks/{chunk-E6T37ED6.js → chunk-FNQV2ONG.js} +2 -2
- package/dist/mcp-chunks/{chunk-2JHHONW4.js → chunk-FW5QVG6V.js} +1 -1
- package/dist/mcp-chunks/{chunk-YCYSQA5V.js → chunk-FZ7K5EGL.js} +5 -5
- package/dist/mcp-chunks/{chunk-KSMY7PXI.js → chunk-G5C4WVDQ.js} +1 -1
- package/dist/mcp-chunks/{chunk-XRGLP3Z2.js → chunk-GPCLDF6U.js} +1 -1
- package/dist/mcp-chunks/{chunk-KSGYBW3F.js → chunk-GQHTGV5E.js} +72 -22
- package/dist/mcp-chunks/{chunk-64EP2BVO.js → chunk-HULRE4D2.js} +1 -1
- package/dist/mcp-chunks/{chunk-UENXT3NE.js → chunk-ILSK6AWI.js} +1 -1
- package/dist/mcp-chunks/{chunk-RBVYCKCD.js → chunk-ILULMM2E.js} +2 -2
- package/dist/mcp-chunks/{chunk-NZOIX6XW.js → chunk-ITJWLDF5.js} +2 -2
- package/dist/mcp-chunks/{chunk-XUF6KARU.js → chunk-IUFDFNNP.js} +1 -1
- package/dist/mcp-chunks/chunk-JJG2OEHI.js +12 -0
- package/dist/mcp-chunks/{chunk-YPJ5EHXR.js → chunk-K56RW4HB.js} +4 -4
- package/dist/mcp-chunks/{chunk-H7F5RZXS.js → chunk-KJ3CMHWS.js} +2 -1
- package/dist/mcp-chunks/{chunk-WXBPMFSN.js → chunk-LI4L4FOV.js} +91 -34
- package/dist/mcp-chunks/{chunk-ETWN4IIA.js → chunk-LYZRCACV.js} +6 -6
- package/dist/mcp-chunks/{chunk-ZBFZ5UFE.js → chunk-MDVNQ4HM.js} +3 -1
- package/dist/mcp-chunks/{chunk-3IZQW4H4.js → chunk-MNAVFYYV.js} +212 -18
- package/dist/mcp-chunks/{chunk-7DH57OKF.js → chunk-MWD5PZ4G.js} +2 -2
- package/dist/mcp-chunks/{chunk-YSPT6F7K.js → chunk-N2HVJU7X.js} +1 -1
- package/dist/mcp-chunks/{chunk-WWO5WGH5.js → chunk-NACLB5YH.js} +5 -5
- package/dist/mcp-chunks/{chunk-QJACOI2W.js → chunk-NMF5S5DC.js} +4 -2
- package/dist/mcp-chunks/{chunk-54EWGONA.js → chunk-NPU7EMGE.js} +10 -6
- package/dist/mcp-chunks/{chunk-SFREPU3D.js → chunk-NSZY5WLR.js} +1 -1
- package/dist/mcp-chunks/{chunk-7RDLPFIO.js → chunk-QK6LUI5Q.js} +2 -2
- package/dist/mcp-chunks/{chunk-XTL4MHFH.js → chunk-QONTHFPO.js} +11 -7
- package/dist/mcp-chunks/{chunk-YTKRAHO6.js → chunk-RDOD354S.js} +4 -4
- package/dist/mcp-chunks/{chunk-2MEHGB7D.js → chunk-RXSZ2W6Y.js} +1 -1
- package/dist/mcp-chunks/{chunk-UHOKCTZT.js → chunk-RYAUNXFA.js} +1 -1
- package/dist/mcp-chunks/{chunk-GIF7LOYU.js → chunk-SCD2NAX5.js} +2 -2
- package/dist/mcp-chunks/{chunk-F3LL4EBL.js → chunk-SHZVDY6Z.js} +1 -1
- package/dist/mcp-chunks/{chunk-CNDY7WB4.js → chunk-TAVMVGD5.js} +2 -2
- package/dist/mcp-chunks/{chunk-JAKI24KR.js → chunk-U23EY5DN.js} +1 -1
- package/dist/mcp-chunks/{chunk-SB2UUURE.js → chunk-UAIJZBGL.js} +10 -10
- package/dist/mcp-chunks/{chunk-PKOJCYNA.js → chunk-UDG3RHKX.js} +2 -2
- package/dist/mcp-chunks/{chunk-CA5WFJZA.js → chunk-VC6SKXTI.js} +1 -1
- package/dist/mcp-chunks/chunk-VJ2TSA5R.js +818 -0
- package/dist/mcp-chunks/{chunk-FWP4RACK.js → chunk-VREKED5H.js} +2 -2
- package/dist/mcp-chunks/{chunk-2FSDGCHW.js → chunk-WKUCIR2F.js} +374 -527
- package/dist/mcp-chunks/chunk-XRRT3SZM.js +1931 -0
- package/dist/mcp-chunks/{chunk-GSZOK5TS.js → chunk-YDJ7E2PH.js} +3 -3
- package/dist/mcp-chunks/{chunk-LICH4Q7A.js → chunk-ZI44YPFF.js} +4 -4
- package/dist/mcp-chunks/{chunk-DEUU7WSN.js → chunk-ZNKNF2BV.js} +2 -2
- package/dist/mcp-chunks/{chunk-DXPHJFSA.js → chunk-ZSKQI4TS.js} +4 -4
- package/dist/mcp-chunks/{cli-E4P6SZLQ.js → cli-Z7KV4PCE.js} +70 -69
- package/dist/mcp-chunks/client-B3FMQNGF.js +21 -0
- package/dist/mcp-chunks/{config-command-MWF3RHPQ.js → config-command-XXCDOB3M.js} +27 -27
- package/dist/mcp-chunks/daemon-command-BAREANTC.js +35 -0
- package/dist/mcp-chunks/{dist-ZIPUENTM.js → dist-V4UB7RTR.js} +547 -402
- package/dist/mcp-chunks/{emit-ts-command-GOVJJ64A.js → emit-ts-command-FEHTMXXB.js} +16 -16
- package/dist/mcp-chunks/{generate-cli-runner-L5OQIMEY.js → generate-cli-runner-OA6XL77R.js} +49 -42
- package/dist/mcp-chunks/{inspect-cli-command-7OMMREPE.js → inspect-cli-command-UQKKE5VO.js} +9 -9
- package/dist/mcp-chunks/{launch-BWXPLPB7.js → launch-KMPDJOUH.js} +1 -1
- package/dist/mcp-chunks/{lifecycle-B5UC65PT.js → lifecycle-R3IP22MJ.js} +1 -1
- package/dist/mcp-chunks/{list-command-ZO4HVFQK.js → list-command-7ENYKBF6.js} +31 -31
- package/dist/mcp-chunks/{output-utils-M3TJ2N4M.js → output-utils-N75TOWBX.js} +3 -3
- package/dist/mcp-chunks/{prompt-CH6TK0bC-C7OTKGRD.js → prompt-CH6TK0bC-NSBYYJZH.js} +1 -1
- package/dist/mcp-chunks/{record-command-VD3HUQIC.js → record-command-XHPCL7IG.js} +5 -5
- package/dist/mcp-chunks/{replay-command-AX6IN7YD.js → replay-command-CB56L3ZA.js} +6 -6
- package/dist/mcp-chunks/{resource-command-JEZ2DW2G.js → resource-command-STEBHVT7.js} +9 -9
- package/dist/mcp-chunks/{result-utils-3YHYGS45.js → result-utils-UONY2KNY.js} +3 -3
- package/dist/mcp-chunks/runtime-Z45IVD24.js +39 -0
- package/dist/mcp-chunks/{runtime-wrapper-UREU7GC3.js → runtime-wrapper-SYYAQVO6.js} +6 -6
- package/dist/mcp-chunks/{serve-command-M47YZ6JN.js → serve-command-VYSFRZFE.js} +35 -27
- package/dist/mcp-chunks/{timeouts-THZRYP4B.js → timeouts-T3JP3MUF.js} +5 -3
- package/dist/mcp-chunks/{vault-command-53P7MLCB.js → vault-command-AJ3X7GDI.js} +58 -12
- package/dist/mcp-chunks/{webapi-PHEQZQKH.js → webapi-BLTNWSB2.js} +68 -60
- package/dist/mcp-daemon.js +30 -28
- package/dist/mcp-run-worker.js +30 -28
- package/dist/mcp.d.ts.map +1 -1
- package/dist/mcp.js +2 -1
- package/dist/mcp.js.map +1 -1
- package/dist/pi-extension.d.ts +3 -0
- package/dist/pi-extension.d.ts.map +1 -1
- package/dist/pi-extension.js +27 -0
- package/dist/pi-extension.js.map +1 -1
- package/dist/run-controller.d.ts +3 -1
- package/dist/run-controller.d.ts.map +1 -1
- package/dist/run-controller.js +10 -0
- package/dist/run-controller.js.map +1 -1
- package/dist/session.d.ts +3 -1
- package/dist/session.d.ts.map +1 -1
- package/dist/session.js +4 -1
- package/dist/session.js.map +1 -1
- package/docs/host-api.md +12 -0
- package/docs/pi-extension.md +10 -0
- package/package.json +11 -11
- package/vendor/introspection-recipe-check/win32-x64/introspection-recipe-check.exe +0 -0
- package/dist/mcp-chunks/call-arguments-TX3F2TEE.js +0 -15
- package/dist/mcp-chunks/chunk-SRZZQ6TL.js +0 -266
- package/dist/mcp-chunks/client-2EJC4PLL.js +0 -18
- package/dist/mcp-chunks/daemon-command-6CJ26MKI.js +0 -33
- package/dist/mcp-chunks/runtime-HSYVOME7.js +0 -37
|
@@ -4,31 +4,38 @@ import {
|
|
|
4
4
|
DaemonFrameDecoder,
|
|
5
5
|
isDaemonProgressFrame,
|
|
6
6
|
resolveProgressInterval
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-MDVNQ4HM.js";
|
|
8
|
+
import {
|
|
9
|
+
CHROME_DEVTOOLS_RELAY_RUNTIME_IDENTITY_VERSION,
|
|
10
|
+
resolveChromeDevtoolsRelayRuntimeIdentity
|
|
11
|
+
} from "./chunk-XRRT3SZM.js";
|
|
12
|
+
import {
|
|
13
|
+
suppressBrowserLaunchFromEnv
|
|
14
|
+
} from "./chunk-JJG2OEHI.js";
|
|
8
15
|
import {
|
|
9
16
|
listConfigLayerPaths
|
|
10
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-5HQYKAE7.js";
|
|
11
18
|
import {
|
|
12
19
|
isProcessRunning,
|
|
13
20
|
withFileLock
|
|
14
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-ETYYCEQF.js";
|
|
15
22
|
import {
|
|
16
23
|
mcporterDir
|
|
17
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-VREKED5H.js";
|
|
18
25
|
import {
|
|
19
26
|
expandHome
|
|
20
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-DIIFWDZ7.js";
|
|
21
28
|
import {
|
|
22
29
|
keepAliveIdleTimeout
|
|
23
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-AJPFOQLF.js";
|
|
24
31
|
|
|
25
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
32
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/client.js
|
|
26
33
|
import crypto, { randomUUID } from "node:crypto";
|
|
27
34
|
import fs2 from "node:fs/promises";
|
|
28
35
|
import net from "node:net";
|
|
29
36
|
import path3 from "node:path";
|
|
30
37
|
|
|
31
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
38
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/config-layers.js
|
|
32
39
|
import fs from "node:fs/promises";
|
|
33
40
|
import path from "node:path";
|
|
34
41
|
async function statConfigMtime(configPath) {
|
|
@@ -59,7 +66,7 @@ function normalizeConfigLayers(layers) {
|
|
|
59
66
|
return normalized.toSorted((a, b) => a.path < b.path ? -1 : a.path > b.path ? 1 : 0);
|
|
60
67
|
}
|
|
61
68
|
|
|
62
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
69
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/paths.js
|
|
63
70
|
import path2 from "node:path";
|
|
64
71
|
function resolveBaseDir() {
|
|
65
72
|
const override = process.env.MCPORTER_DAEMON_DIR;
|
|
@@ -85,7 +92,7 @@ function getDaemonLogPath(configKey) {
|
|
|
85
92
|
return path2.join(ensureRunDir(), `daemon-${configKey}.log`);
|
|
86
93
|
}
|
|
87
94
|
|
|
88
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
95
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/request-utils.js
|
|
89
96
|
function delay(ms) {
|
|
90
97
|
return new Promise((resolve) => {
|
|
91
98
|
setTimeout(resolve, ms);
|
|
@@ -150,7 +157,50 @@ function buildErrorResponse(id, code, error) {
|
|
|
150
157
|
};
|
|
151
158
|
}
|
|
152
159
|
|
|
153
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
160
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/startup-readiness.js
|
|
161
|
+
var DAEMON_STARTUP_TIMEOUT_MS = 45e3;
|
|
162
|
+
var DAEMON_STARTUP_SLOW_NOTICE_MS = 5e3;
|
|
163
|
+
var DAEMON_STARTUP_POLL_INTERVAL_MS = 100;
|
|
164
|
+
async function waitForDaemonReady(probe, timing = {}) {
|
|
165
|
+
const now = timing.now ?? Date.now;
|
|
166
|
+
const wait = timing.delay ?? delay2;
|
|
167
|
+
const reportSlowStart = timing.reportSlowStart ?? defaultSlowStartReporter;
|
|
168
|
+
const startedAt = now();
|
|
169
|
+
const deadline = startedAt + DAEMON_STARTUP_TIMEOUT_MS;
|
|
170
|
+
let reportedSlowStart = false;
|
|
171
|
+
while (true) {
|
|
172
|
+
const remainingBeforeProbe = deadline - now();
|
|
173
|
+
if (remainingBeforeProbe <= 0) {
|
|
174
|
+
throw daemonStartupTimeoutError();
|
|
175
|
+
}
|
|
176
|
+
const result = await probe(Math.min(DAEMON_STARTUP_POLL_INTERVAL_MS, remainingBeforeProbe));
|
|
177
|
+
if (result !== null) {
|
|
178
|
+
return result;
|
|
179
|
+
}
|
|
180
|
+
const currentTime = now();
|
|
181
|
+
if (currentTime >= deadline) {
|
|
182
|
+
throw daemonStartupTimeoutError();
|
|
183
|
+
}
|
|
184
|
+
if (!reportedSlowStart && currentTime - startedAt >= DAEMON_STARTUP_SLOW_NOTICE_MS) {
|
|
185
|
+
reportedSlowStart = true;
|
|
186
|
+
reportSlowStart();
|
|
187
|
+
}
|
|
188
|
+
await wait(Math.min(DAEMON_STARTUP_POLL_INTERVAL_MS, deadline - currentTime));
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
function defaultSlowStartReporter() {
|
|
192
|
+
console.error("[mcporter] Daemon startup is taking longer than usual; Chrome relay discovery can take up to 30 seconds.");
|
|
193
|
+
}
|
|
194
|
+
function daemonStartupTimeoutError() {
|
|
195
|
+
return new Error("MCPorter daemon did not become ready within 45 seconds. Run 'mcporter daemon start --foreground --log' to diagnose startup.");
|
|
196
|
+
}
|
|
197
|
+
function delay2(ms) {
|
|
198
|
+
return new Promise((resolve) => {
|
|
199
|
+
setTimeout(resolve, ms);
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/client.js
|
|
154
204
|
var DEFAULT_DAEMON_TIMEOUT_MS = 3e4;
|
|
155
205
|
var MIN_DAEMON_STATUS_TIMEOUT_MS = 1e3;
|
|
156
206
|
function resolveDaemonPaths(configPath) {
|
|
@@ -187,8 +237,8 @@ var DaemonClient = class {
|
|
|
187
237
|
async closeServer(params) {
|
|
188
238
|
await this.invoke("closeServer", params);
|
|
189
239
|
}
|
|
190
|
-
async status() {
|
|
191
|
-
return await this.readVerifiedStatus();
|
|
240
|
+
async status(timeoutMs) {
|
|
241
|
+
return await this.readVerifiedStatus(timeoutMs);
|
|
192
242
|
}
|
|
193
243
|
async stop() {
|
|
194
244
|
try {
|
|
@@ -263,7 +313,7 @@ var DaemonClient = class {
|
|
|
263
313
|
await this.startingPromise;
|
|
264
314
|
}
|
|
265
315
|
async launchDaemonAndWait() {
|
|
266
|
-
const { launchDaemonDetached } = await import("./launch-
|
|
316
|
+
const { launchDaemonDetached } = await import("./launch-KMPDJOUH.js");
|
|
267
317
|
launchDaemonDetached({
|
|
268
318
|
configPath: this.options.configPath,
|
|
269
319
|
configExplicit: this.options.configExplicit,
|
|
@@ -284,14 +334,7 @@ var DaemonClient = class {
|
|
|
284
334
|
throw new Error("Daemon did not stop before restart could begin.");
|
|
285
335
|
}
|
|
286
336
|
async waitForReady() {
|
|
287
|
-
|
|
288
|
-
while (Date.now() < deadline) {
|
|
289
|
-
if (await this.isResponsive()) {
|
|
290
|
-
return;
|
|
291
|
-
}
|
|
292
|
-
await delay(100);
|
|
293
|
-
}
|
|
294
|
-
throw new Error("Timeout while waiting for MCPorter daemon to start.");
|
|
337
|
+
await waitForDaemonReady((timeoutMs) => this.readVerifiedStatus(timeoutMs));
|
|
295
338
|
}
|
|
296
339
|
async isResponsive(timeoutMs) {
|
|
297
340
|
return await this.readVerifiedStatus(timeoutMs) !== null;
|
|
@@ -334,6 +377,12 @@ var DaemonClient = class {
|
|
|
334
377
|
return "stale";
|
|
335
378
|
}
|
|
336
379
|
}
|
|
380
|
+
if (metadata.relayRuntimeIdentityVersion !== CHROME_DEVTOOLS_RELAY_RUNTIME_IDENTITY_VERSION || !metadata.relayEnvironmentKeys || metadata.relayRuntimeIdentity !== await resolveChromeDevtoolsRelayRuntimeIdentity(metadata.relayEnvironmentKeys, process.env, this.options.chromeDevtoolsRelayIdentity)) {
|
|
381
|
+
return "stale";
|
|
382
|
+
}
|
|
383
|
+
if ((metadata.oauthNoBrowser ?? false) !== suppressBrowserLaunchFromEnv()) {
|
|
384
|
+
return "stale";
|
|
385
|
+
}
|
|
337
386
|
return "fresh";
|
|
338
387
|
}
|
|
339
388
|
async sendRequest(method, params, timeoutOverrideMs) {
|
|
@@ -471,6 +520,7 @@ export {
|
|
|
471
520
|
shouldShutdownDaemonForIdle,
|
|
472
521
|
daemonIdleWatcherInterval,
|
|
473
522
|
buildErrorResponse,
|
|
523
|
+
waitForDaemonReady,
|
|
474
524
|
resolveDaemonPaths,
|
|
475
525
|
DaemonClient
|
|
476
526
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
|
|
3
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
3
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/network-family-autoselection.js
|
|
4
4
|
import net from "node:net";
|
|
5
5
|
var NODE_DEFAULT_ATTEMPT_TIMEOUT_MS = 250;
|
|
6
6
|
var MCPORTER_ATTEMPT_TIMEOUT_MS = 1500;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
|
|
3
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
3
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/cli/http-utils.js
|
|
4
4
|
var DOMAIN_WITH_PATH_PATTERN = /^[A-Za-z0-9](?:[A-Za-z0-9.-]*)(?::\d+)?\//;
|
|
5
5
|
function normalizeHttpUrlCandidate(value) {
|
|
6
6
|
if (!value) {
|
|
@@ -2,9 +2,9 @@ import { createRequire as __createRequire } from "node:module"; const require =
|
|
|
2
2
|
import {
|
|
3
3
|
createPrefixedConsoleLogger,
|
|
4
4
|
resolveLogLevelFromEnv
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-54UGGTOX.js";
|
|
6
6
|
|
|
7
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
7
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/cli/logger-context.js
|
|
8
8
|
var activeLogLevel = resolveLogLevelFromEnv();
|
|
9
9
|
var activeLogger = createPrefixedConsoleLogger("mcporter", activeLogLevel);
|
|
10
10
|
function getActiveLogLevel() {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
import {
|
|
3
3
|
analyzeConnectionError
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-ZNKNF2BV.js";
|
|
5
5
|
|
|
6
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
6
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/result-utils.js
|
|
7
7
|
function extractEnvelope(raw) {
|
|
8
8
|
return collectEnvelopeFields(raw, { content: null, structuredContent: null }, 0);
|
|
9
9
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
|
|
3
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
3
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/cli/terminal.js
|
|
4
4
|
var forceColorRaw = process.env.FORCE_COLOR?.toLowerCase();
|
|
5
5
|
var forceDisableColor = forceColorRaw === "0" || forceColorRaw === "false";
|
|
6
6
|
var forceEnableColor = forceColorRaw === "1" || forceColorRaw === "true" || forceColorRaw === "2" || forceColorRaw === "3";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
|
+
|
|
3
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/oauth-browser-suppression.js
|
|
4
|
+
var TRUE_VALUES = /* @__PURE__ */ new Set(["1", "true", "yes"]);
|
|
5
|
+
function suppressBrowserLaunchFromEnv(env = process.env) {
|
|
6
|
+
const raw = env.MCPORTER_OAUTH_NO_BROWSER;
|
|
7
|
+
return raw !== void 0 && TRUE_VALUES.has(raw.trim().toLowerCase());
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export {
|
|
11
|
+
suppressBrowserLaunchFromEnv
|
|
12
|
+
};
|
|
@@ -12765,7 +12765,7 @@ async function pkceChallenge(length) {
|
|
|
12765
12765
|
};
|
|
12766
12766
|
}
|
|
12767
12767
|
|
|
12768
|
-
// node_modules/.pnpm/eventsource-parser@3.1.
|
|
12768
|
+
// node_modules/.pnpm/eventsource-parser@3.1.1/node_modules/eventsource-parser/dist/index.js
|
|
12769
12769
|
var ParseError = class extends Error {
|
|
12770
12770
|
constructor(message, options) {
|
|
12771
12771
|
super(message), this.name = "ParseError", this.type = options.type, this.field = options.field, this.value = options.value, this.line = options.line;
|
|
@@ -12869,7 +12869,7 @@ ${value2}`, dataLines++;
|
|
|
12869
12869
|
}
|
|
12870
12870
|
if (firstCharCode === 105 && chunk.charCodeAt(start + 1) === 100 && chunk.charCodeAt(start + 2) === 58) {
|
|
12871
12871
|
const value2 = chunk.slice(chunk.charCodeAt(start + 3) === SPACE ? start + 4 : start + 3, end);
|
|
12872
|
-
|
|
12872
|
+
value2.includes("\0") || (id = value2);
|
|
12873
12873
|
return;
|
|
12874
12874
|
}
|
|
12875
12875
|
if (firstCharCode === 58) {
|
|
@@ -12897,7 +12897,7 @@ ${value2}`, dataLines++;
|
|
|
12897
12897
|
${value}`, dataLines++;
|
|
12898
12898
|
break;
|
|
12899
12899
|
case "id":
|
|
12900
|
-
|
|
12900
|
+
value.includes("\0") || (id = value);
|
|
12901
12901
|
break;
|
|
12902
12902
|
case "retry":
|
|
12903
12903
|
/^\d+$/.test(value) ? onRetry(parseInt(value, 10)) : onError(
|
|
@@ -13238,7 +13238,7 @@ function getBaseURL() {
|
|
|
13238
13238
|
return doc && typeof doc == "object" && "baseURI" in doc && typeof doc.baseURI == "string" ? doc.baseURI : void 0;
|
|
13239
13239
|
}
|
|
13240
13240
|
|
|
13241
|
-
// node_modules/.pnpm/eventsource-parser@3.1.
|
|
13241
|
+
// node_modules/.pnpm/eventsource-parser@3.1.1/node_modules/eventsource-parser/dist/stream.js
|
|
13242
13242
|
var EventSourceParserStream = class extends TransformStream {
|
|
13243
13243
|
constructor({ onError, onRetry, onComment, maxBufferSize } = {}) {
|
|
13244
13244
|
let parser;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
|
|
3
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
3
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/definition-fields.js
|
|
4
4
|
var SHARED_DEFINITION_FIELDS = [
|
|
5
5
|
"auth",
|
|
6
6
|
"tokenCacheDir",
|
|
7
7
|
"clientName",
|
|
8
8
|
"protocolVersion",
|
|
9
|
+
"chromeDevtoolsRelay",
|
|
9
10
|
"oauthClientId",
|
|
10
11
|
"oauthClientSecretEnv",
|
|
11
12
|
"oauthTokenEndpointAuthMethod",
|
|
@@ -1,31 +1,29 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
import {
|
|
3
3
|
configureAutoSelectFamilyAttemptTimeout
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-HULRE4D2.js";
|
|
5
5
|
import {
|
|
6
6
|
stableJsonStringify
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-RYAUNXFA.js";
|
|
8
8
|
import {
|
|
9
9
|
createRuntime
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-WKUCIR2F.js";
|
|
11
11
|
import {
|
|
12
12
|
NON_INTERACTIVE_ELICITATION_HINT,
|
|
13
13
|
createNonInteractiveElicitationResponder
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-VC6SKXTI.js";
|
|
15
15
|
import {
|
|
16
16
|
OAuthTimeoutError,
|
|
17
|
+
isOAuthFlowError,
|
|
17
18
|
resolveOAuthTimeoutFromEnv
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import {
|
|
20
|
-
raceWithTimeout
|
|
21
|
-
} from "./chunk-ETWN4IIA.js";
|
|
19
|
+
} from "./chunk-VJ2TSA5R.js";
|
|
22
20
|
import {
|
|
23
21
|
DEFAULT_REQUEST_TIMEOUT_MSEC,
|
|
24
22
|
SdkErrorCode
|
|
25
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-K56RW4HB.js";
|
|
26
24
|
import {
|
|
27
25
|
launchDaemonDetached
|
|
28
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-N2HVJU7X.js";
|
|
29
27
|
import {
|
|
30
28
|
DaemonClient,
|
|
31
29
|
buildErrorResponse,
|
|
@@ -39,49 +37,63 @@ import {
|
|
|
39
37
|
normalizeConfigLayers,
|
|
40
38
|
resolveDaemonPaths,
|
|
41
39
|
shouldShutdownDaemonForIdle,
|
|
42
|
-
statConfigMtime
|
|
43
|
-
|
|
40
|
+
statConfigMtime,
|
|
41
|
+
waitForDaemonReady
|
|
42
|
+
} from "./chunk-GQHTGV5E.js";
|
|
44
43
|
import {
|
|
44
|
+
DAEMON_OAUTH_FLOW_ERROR_CODE,
|
|
45
45
|
DAEMON_OPERATION_TIMEOUT_CODE,
|
|
46
46
|
DAEMON_PROGRESS_INTERVAL_MS,
|
|
47
47
|
DAEMON_PROTOCOL_VERSION,
|
|
48
48
|
encodeDaemonFrame
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-MDVNQ4HM.js";
|
|
50
|
+
import {
|
|
51
|
+
CHROME_DEVTOOLS_RELAY_RUNTIME_IDENTITY_VERSION,
|
|
52
|
+
chromeDevtoolsRelayEnvironmentKeys,
|
|
53
|
+
getChromeDevtoolsRelayDecision,
|
|
54
|
+
resolveChromeDevtoolsRelayRuntimeIdentity
|
|
55
|
+
} from "./chunk-XRRT3SZM.js";
|
|
56
|
+
import {
|
|
57
|
+
suppressBrowserLaunchFromEnv
|
|
58
|
+
} from "./chunk-JJG2OEHI.js";
|
|
59
|
+
import {
|
|
60
|
+
raceWithTimeout
|
|
61
|
+
} from "./chunk-LYZRCACV.js";
|
|
50
62
|
import {
|
|
51
63
|
loadConfigSnapshot
|
|
52
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-5HQYKAE7.js";
|
|
53
65
|
import {
|
|
54
66
|
isProcessRunning,
|
|
55
67
|
readJsonFile,
|
|
56
68
|
withFileLock,
|
|
57
69
|
writeJsonFile
|
|
58
|
-
} from "./chunk-
|
|
70
|
+
} from "./chunk-ETYYCEQF.js";
|
|
59
71
|
import {
|
|
60
72
|
expandHome
|
|
61
|
-
} from "./chunk-
|
|
73
|
+
} from "./chunk-DIIFWDZ7.js";
|
|
62
74
|
import {
|
|
63
75
|
isKeepAliveServer
|
|
64
|
-
} from "./chunk-
|
|
76
|
+
} from "./chunk-AJPFOQLF.js";
|
|
65
77
|
|
|
66
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
78
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/cli/daemon-command.js
|
|
67
79
|
import fsPromises from "node:fs/promises";
|
|
68
80
|
import path3 from "node:path";
|
|
69
81
|
|
|
70
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
82
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/host.js
|
|
71
83
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
72
84
|
import { randomUUID } from "node:crypto";
|
|
73
85
|
import fs from "node:fs/promises";
|
|
74
86
|
import net from "node:net";
|
|
75
87
|
import path2 from "node:path";
|
|
76
88
|
|
|
77
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
89
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/definition-hash.js
|
|
78
90
|
import { createHash } from "node:crypto";
|
|
79
91
|
function hashDaemonDefinitions(definitions) {
|
|
80
92
|
const sorted = definitions.toSorted((a, b) => a.name.localeCompare(b.name));
|
|
81
93
|
return createHash("sha256").update(stableJsonStringify(sorted)).digest("hex").slice(0, 16);
|
|
82
94
|
}
|
|
83
95
|
|
|
84
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
96
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/log-context.js
|
|
85
97
|
import fsSync from "node:fs";
|
|
86
98
|
import path from "node:path";
|
|
87
99
|
function createLogContext(options) {
|
|
@@ -94,9 +106,16 @@ function createLogContext(options) {
|
|
|
94
106
|
if (derivedEnabled && options.logPath) {
|
|
95
107
|
try {
|
|
96
108
|
fsSync.mkdirSync(path.dirname(options.logPath), { recursive: true });
|
|
97
|
-
|
|
109
|
+
const writer = fsSync.createWriteStream(options.logPath, {
|
|
98
110
|
flags: "a"
|
|
99
111
|
});
|
|
112
|
+
writer.on("error", (error) => {
|
|
113
|
+
console.warn(`[daemon] Log file write error (${options.logPath}): ${error.message}`);
|
|
114
|
+
if (context.writer === writer) {
|
|
115
|
+
context.writer = void 0;
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
context.writer = writer;
|
|
100
119
|
} catch (error) {
|
|
101
120
|
console.warn(`[daemon] Failed to open log file ${options.logPath}: ${error.message}`);
|
|
102
121
|
}
|
|
@@ -144,7 +163,7 @@ function formatError(error) {
|
|
|
144
163
|
return "unknown";
|
|
145
164
|
}
|
|
146
165
|
|
|
147
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
166
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/host.js
|
|
148
167
|
var daemonRequestNotices = new AsyncLocalStorage();
|
|
149
168
|
async function runDaemonHost(options) {
|
|
150
169
|
configureAutoSelectFamilyAttemptTimeout();
|
|
@@ -159,6 +178,9 @@ async function runDaemonHost(options) {
|
|
|
159
178
|
const { daemonConfig, runtime } = startup;
|
|
160
179
|
const keepAliveDefinitions = runtime.getDefinitions().filter(isKeepAliveServer);
|
|
161
180
|
const definitionHash = hashDaemonDefinitions(keepAliveDefinitions);
|
|
181
|
+
const relayEnvironmentKeys = chromeDevtoolsRelayEnvironmentKeys(keepAliveDefinitions);
|
|
182
|
+
const relayRuntimeIdentity = await resolveChromeDevtoolsRelayRuntimeIdentity(relayEnvironmentKeys);
|
|
183
|
+
const oauthNoBrowser = suppressBrowserLaunchFromEnv();
|
|
162
184
|
if (keepAliveDefinitions.length === 0) {
|
|
163
185
|
throw new Error("No MCP servers require keep-alive; daemon will not start.");
|
|
164
186
|
}
|
|
@@ -250,7 +272,11 @@ async function runDaemonHost(options) {
|
|
|
250
272
|
startedAt,
|
|
251
273
|
logPath: options.logPath ?? null,
|
|
252
274
|
configMtimeMs,
|
|
253
|
-
definitionHash
|
|
275
|
+
definitionHash,
|
|
276
|
+
relayRuntimeIdentityVersion: CHROME_DEVTOOLS_RELAY_RUNTIME_IDENTITY_VERSION,
|
|
277
|
+
relayRuntimeIdentity,
|
|
278
|
+
relayEnvironmentKeys,
|
|
279
|
+
oauthNoBrowser
|
|
254
280
|
}, logContext, shutdown, parsedRequest).finally(() => {
|
|
255
281
|
activeDaemonRequests -= 1;
|
|
256
282
|
lastDaemonActivityAt = Date.now();
|
|
@@ -273,7 +299,7 @@ async function runDaemonHost(options) {
|
|
|
273
299
|
await withFileLock(`${options.metadataPath}.bind`, async () => {
|
|
274
300
|
const live = await probeLiveDaemon(options.socketPath);
|
|
275
301
|
if (live) {
|
|
276
|
-
if (daemonConfigMatches(live, configLayers, options.configPath, configMtimeMs, definitionHash)) {
|
|
302
|
+
if (daemonConfigMatches(live, configLayers, options.configPath, configMtimeMs, definitionHash, CHROME_DEVTOOLS_RELAY_RUNTIME_IDENTITY_VERSION, relayRuntimeIdentity, relayEnvironmentKeys, oauthNoBrowser)) {
|
|
277
303
|
if (!await metadataMatches(options.metadataPath, live)) {
|
|
278
304
|
await writeJsonFile(options.metadataPath, metadataFromStatus(live, configLayers));
|
|
279
305
|
}
|
|
@@ -298,7 +324,11 @@ async function runDaemonHost(options) {
|
|
|
298
324
|
startedAt: Date.now(),
|
|
299
325
|
logPath: options.logPath ?? null,
|
|
300
326
|
configMtimeMs,
|
|
301
|
-
definitionHash
|
|
327
|
+
definitionHash,
|
|
328
|
+
relayRuntimeIdentityVersion: CHROME_DEVTOOLS_RELAY_RUNTIME_IDENTITY_VERSION,
|
|
329
|
+
relayRuntimeIdentity,
|
|
330
|
+
relayEnvironmentKeys,
|
|
331
|
+
oauthNoBrowser
|
|
302
332
|
});
|
|
303
333
|
claimed = true;
|
|
304
334
|
});
|
|
@@ -351,13 +381,29 @@ function metadataFromStatus(status, fallbackConfigLayers) {
|
|
|
351
381
|
startedAt: status.startedAt,
|
|
352
382
|
logPath: status.logPath ?? null,
|
|
353
383
|
configMtimeMs: status.configMtimeMs ?? null,
|
|
354
|
-
definitionHash: status.definitionHash
|
|
384
|
+
definitionHash: status.definitionHash,
|
|
385
|
+
relayRuntimeIdentityVersion: status.relayRuntimeIdentityVersion,
|
|
386
|
+
relayRuntimeIdentity: status.relayRuntimeIdentity,
|
|
387
|
+
relayEnvironmentKeys: status.relayEnvironmentKeys,
|
|
388
|
+
oauthNoBrowser: status.oauthNoBrowser
|
|
355
389
|
};
|
|
356
390
|
}
|
|
357
|
-
function daemonConfigMatches(live, currentLayers, currentConfigPath, currentConfigMtimeMs, currentDefinitionHash) {
|
|
391
|
+
function daemonConfigMatches(live, currentLayers, currentConfigPath, currentConfigMtimeMs, currentDefinitionHash, currentRelayRuntimeIdentityVersion, currentRelayRuntimeIdentity, currentRelayEnvironmentKeys, currentOauthNoBrowser) {
|
|
358
392
|
if (live.definitionHash !== currentDefinitionHash) {
|
|
359
393
|
return false;
|
|
360
394
|
}
|
|
395
|
+
if (live.relayRuntimeIdentityVersion !== currentRelayRuntimeIdentityVersion) {
|
|
396
|
+
return false;
|
|
397
|
+
}
|
|
398
|
+
if (live.relayRuntimeIdentity !== currentRelayRuntimeIdentity) {
|
|
399
|
+
return false;
|
|
400
|
+
}
|
|
401
|
+
if (JSON.stringify(live.relayEnvironmentKeys) !== JSON.stringify(currentRelayEnvironmentKeys)) {
|
|
402
|
+
return false;
|
|
403
|
+
}
|
|
404
|
+
if ((live.oauthNoBrowser ?? false) !== currentOauthNoBrowser) {
|
|
405
|
+
return false;
|
|
406
|
+
}
|
|
361
407
|
const liveLayers = normalizeConfigLayers(live.configLayers && live.configLayers.length > 0 ? live.configLayers : [{ path: live.configPath, mtimeMs: live.configMtimeMs ?? null }]);
|
|
362
408
|
const expectedLayers = normalizeConfigLayers(currentLayers.length > 0 ? currentLayers : [{ path: currentConfigPath, mtimeMs: currentConfigMtimeMs }]);
|
|
363
409
|
if (liveLayers.length !== expectedLayers.length) {
|
|
@@ -529,6 +575,9 @@ function daemonRuntimeErrorCode(error) {
|
|
|
529
575
|
if (error instanceof OAuthTimeoutError || errorCode === SdkErrorCode.RequestTimeout || error instanceof Error && error.message === "Timeout") {
|
|
530
576
|
return DAEMON_OPERATION_TIMEOUT_CODE;
|
|
531
577
|
}
|
|
578
|
+
if (isOAuthFlowError(error)) {
|
|
579
|
+
return DAEMON_OAUTH_FLOW_ERROR_CODE;
|
|
580
|
+
}
|
|
532
581
|
return "runtime_error";
|
|
533
582
|
}
|
|
534
583
|
async function processRequestWithNotices(...args) {
|
|
@@ -706,6 +755,10 @@ async function processRequest(rawPayload, runtime, managedServers, activity, met
|
|
|
706
755
|
configLayers: metadata.configLayers,
|
|
707
756
|
configMtimeMs: metadata.configMtimeMs,
|
|
708
757
|
definitionHash: metadata.definitionHash,
|
|
758
|
+
relayRuntimeIdentityVersion: metadata.relayRuntimeIdentityVersion,
|
|
759
|
+
relayRuntimeIdentity: metadata.relayRuntimeIdentity,
|
|
760
|
+
relayEnvironmentKeys: metadata.relayEnvironmentKeys,
|
|
761
|
+
oauthNoBrowser: metadata.oauthNoBrowser,
|
|
709
762
|
socketPath: metadata.socketPath,
|
|
710
763
|
logPath: metadata.logPath ?? void 0,
|
|
711
764
|
servers: Array.from(managedServers.values()).map((def) => {
|
|
@@ -713,7 +766,8 @@ async function processRequest(rawPayload, runtime, managedServers, activity, met
|
|
|
713
766
|
return {
|
|
714
767
|
name: def.name,
|
|
715
768
|
connected: Boolean(entry?.connected),
|
|
716
|
-
lastUsedAt: entry?.lastUsedAt
|
|
769
|
+
lastUsedAt: entry?.lastUsedAt,
|
|
770
|
+
chromeDevtoolsRelay: getChromeDevtoolsRelayDecision(def.name)
|
|
717
771
|
};
|
|
718
772
|
})
|
|
719
773
|
};
|
|
@@ -746,7 +800,7 @@ function resolveDaemonListToolsAutoAuthorize(params, definition) {
|
|
|
746
800
|
return params.autoAuthorize;
|
|
747
801
|
}
|
|
748
802
|
|
|
749
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
803
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/cli/daemon-command.js
|
|
750
804
|
async function handleDaemonCli(args, options) {
|
|
751
805
|
const subcommand = args.shift();
|
|
752
806
|
if (!subcommand || subcommand === "help" || subcommand === "--help") {
|
|
@@ -845,10 +899,7 @@ async function handleDaemonStart(args, options, client) {
|
|
|
845
899
|
socketPath,
|
|
846
900
|
extraArgs: forwardedArgs
|
|
847
901
|
});
|
|
848
|
-
|
|
849
|
-
if (!ready) {
|
|
850
|
-
throw new Error("Failed to start daemon before timeout expired.");
|
|
851
|
-
}
|
|
902
|
+
await waitForDaemonReady((timeoutMs) => client.status(timeoutMs));
|
|
852
903
|
console.log(`Daemon started for ${keepAlive.length} server(s).`);
|
|
853
904
|
}
|
|
854
905
|
async function handleDaemonRestart(args, options, client) {
|
|
@@ -881,6 +932,12 @@ async function handleDaemonStatus(client) {
|
|
|
881
932
|
const state = server.connected ? "connected" : "idle";
|
|
882
933
|
const lastUsed = server.lastUsedAt ? ` (last used ${new Date(server.lastUsedAt).toISOString()})` : "";
|
|
883
934
|
console.log(`- ${server.name}: ${state}${lastUsed}`);
|
|
935
|
+
if (server.chromeDevtoolsRelay) {
|
|
936
|
+
const relay = server.chromeDevtoolsRelay;
|
|
937
|
+
const endpoint = relay.endpoint ? ` endpoint=${relay.endpoint}` : "";
|
|
938
|
+
const probe = relay.probeDurationMs === void 0 ? "" : ` probe=${relay.probeStatus ?? "no-status"}/${relay.probeDurationMs}ms`;
|
|
939
|
+
console.log(` chrome relay: route=${relay.route} policy=${relay.policy} reason=${relay.reason}${endpoint}${probe}`);
|
|
940
|
+
}
|
|
884
941
|
});
|
|
885
942
|
}
|
|
886
943
|
function consumeFlag(args, flag) {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
import {
|
|
3
3
|
resolveEnvPlaceholders
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-DIIFWDZ7.js";
|
|
5
5
|
|
|
6
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
6
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/runtime/utils.js
|
|
7
7
|
var ENV_PLACEHOLDER_PATTERN = /\$\{[A-Za-z_][A-Za-z0-9_]*(?::-[^}]*)?\}/;
|
|
8
|
-
function resolveCommandArgument(value) {
|
|
8
|
+
function resolveCommandArgument(value, env = process.env) {
|
|
9
9
|
if (!value) {
|
|
10
10
|
return value;
|
|
11
11
|
}
|
|
@@ -16,13 +16,13 @@ function resolveCommandArgument(value) {
|
|
|
16
16
|
if (!needsInterpolation) {
|
|
17
17
|
return value;
|
|
18
18
|
}
|
|
19
|
-
return resolveEnvPlaceholders(value);
|
|
19
|
+
return resolveEnvPlaceholders(value, env);
|
|
20
20
|
}
|
|
21
|
-
function resolveCommandArguments(args) {
|
|
21
|
+
function resolveCommandArguments(args, env = process.env) {
|
|
22
22
|
if (args.length === 0) {
|
|
23
23
|
return [];
|
|
24
24
|
}
|
|
25
|
-
return args.map((arg) => resolveCommandArgument(arg));
|
|
25
|
+
return args.map((arg) => resolveCommandArgument(arg, env));
|
|
26
26
|
}
|
|
27
27
|
function normalizeTimeout(raw) {
|
|
28
28
|
if (raw == null) {
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { createRequire as __createRequire } from "node:module"; const require = __createRequire(import.meta.url);
|
|
2
2
|
|
|
3
|
-
// node_modules/.pnpm/mcporter@0.13.
|
|
3
|
+
// node_modules/.pnpm/mcporter@0.13.6/node_modules/mcporter/dist/daemon/protocol.js
|
|
4
4
|
var DAEMON_PROTOCOL_VERSION = 2;
|
|
5
5
|
var DAEMON_OPERATION_TIMEOUT_CODE = "operation_timeout";
|
|
6
|
+
var DAEMON_OAUTH_FLOW_ERROR_CODE = "oauth_flow_error";
|
|
6
7
|
var DAEMON_PROGRESS_INTERVAL_MS = 250;
|
|
7
8
|
function resolveProgressInterval(idleTimeoutMs) {
|
|
8
9
|
if (!Number.isFinite(idleTimeoutMs) || idleTimeoutMs <= 0) {
|
|
@@ -59,6 +60,7 @@ var DaemonFrameDecoder = class {
|
|
|
59
60
|
export {
|
|
60
61
|
DAEMON_PROTOCOL_VERSION,
|
|
61
62
|
DAEMON_OPERATION_TIMEOUT_CODE,
|
|
63
|
+
DAEMON_OAUTH_FLOW_ERROR_CODE,
|
|
62
64
|
DAEMON_PROGRESS_INTERVAL_MS,
|
|
63
65
|
resolveProgressInterval,
|
|
64
66
|
isDaemonProgressFrame,
|