poe-code 17.0.38 → 17.0.40
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/README.md +1 -1
- package/dist/agent.js +0 -3
- package/dist/{chunk-SGMFFL57.js → chunk-2GGWYM5C.js} +5 -5
- package/dist/{chunk-NBD2QUZU.js → chunk-4DP4GOVF.js} +9 -1
- package/dist/{chunk-MP2ZN45M.js → chunk-4ZBE6ANW.js} +6 -6
- package/dist/{chunk-ESDPNFK7.js → chunk-7T6WKXT5.js} +6 -6
- package/dist/{chunk-5LEKGHKB.js → chunk-BN5KYLDI.js} +3 -3
- package/dist/{chunk-UKB4PH3Q.js → chunk-HKQ7ZHZA.js} +2 -2
- package/dist/{chunk-7LYL6372.js → chunk-IDRDSIOP.js} +3 -3
- package/dist/{chunk-JRZIA6G4.js → chunk-JVMHBAZW.js} +2 -2
- package/dist/{chunk-ROLXI55L.js → chunk-K4MLQWL6.js} +3 -3
- package/dist/{chunk-OIIB3M4A.js → chunk-NT4FTHR4.js} +3 -3
- package/dist/{chunk-AARUTDF3.js → chunk-OY52WCN2.js} +19 -18
- package/dist/{chunk-CKB7K5UU.js → chunk-QVJA76GB.js} +2 -2
- package/dist/{chunk-Q5UFHZBH.js → chunk-VNSPEKB3.js} +4 -4
- package/dist/{chunk-C5DKZUMH.js → chunk-WGSSARPT.js} +5 -5
- package/dist/{chunk-VPER5WBJ.js → chunk-Z2WKAT24.js} +4 -4
- package/dist/cli-entry.js +1 -1
- package/dist/{core-E763OJ6K.js → core-IC47O6D5.js} +5 -5
- package/dist/{ensure-isolated-config-XXVV7SPC.js → ensure-isolated-config-DP3OWAO5.js} +5 -5
- package/dist/{gh-TBXFLS7Q.js → gh-4NV3GGL7.js} +2 -2
- package/dist/index.js +8 -8
- package/dist/metafile.json +1 -1
- package/dist/{node-PE54ZYII.js → node-KLOI6VAC.js} +4 -4
- package/dist/{poe-agent-VQTC5F2H.js → poe-agent-3TNLVOGW.js} +4 -4
- package/dist/{program-7KSXQLUA.js → program-FEKNPTII.js} +11 -11
- package/dist/providers/poe-agent.js +28 -19
- package/dist/safe-bash-worker-entry.js +3 -3
- package/dist/safe-bash.js +6 -6
- package/dist/{search-DRUQQER6.js → search-QRQVPOLJ.js} +3 -3
- package/dist/shared/safe-js/chunks/{chunk-T76YLX4V.js → chunk-CATT3NXL.js} +2 -2
- package/dist/shared/safe-js/chunks/{chunk-IMBIHHDW.js → chunk-L3QK6FH4.js} +19 -18
- package/dist/shared/safe-js/chunks/{cli-runtime-7QFSS3VJ.js → cli-runtime-UGTDRU7A.js} +3 -3
- package/dist/shared/safe-js/chunks/{mcp-Q7KNMDFG.js → mcp-MZNG3TYT.js} +3 -3
- package/dist/shared/safe-js/cli.js +2 -2
- package/dist/shared/safe-js/index.js +2 -2
- package/dist/{spawn-ESHW36HT.js → spawn-JVTZA4J2.js} +5 -5
- package/dist/{src-U6FPUTZY.js → src-KFIZ3ZHC.js} +7 -7
- package/dist/{src-O7RLS5KL.js → src-SMC2KSW6.js} +3 -3
- package/package.json +1 -1
- package/packages/mcp-oauth/dist/client/authorization-error.js +16 -0
- package/packages/mcp-oauth/dist/client/loopback-authorization.js +2 -16
- package/packages/mcp-oauth/dist/index.browser.js +18 -0
- package/packages/safe-bash/dist/chunks/{chunk-FVAPSB7V.js → chunk-6YWMJV24.js} +9 -1
- package/packages/safe-bash/dist/chunks/{chunk-QCD3LTEK.js → chunk-BK5SQPI2.js} +2 -2
- package/packages/safe-bash/dist/chunks/{chunk-5OOPK32K.js → chunk-MH6MCUVD.js} +2 -2
- package/packages/safe-bash/dist/chunks/{chunk-N2T46LIN.js → chunk-TJVZY5W4.js} +2 -2
- package/packages/safe-bash/dist/chunks/{gh-VURXZAIJ.js → gh-JPPD7RUG.js} +3 -3
- package/packages/safe-bash/dist/commands/xml/index.browser.js +2 -2
- package/packages/safe-bash/dist/commands/yq/index.browser.js +3 -3
- package/packages/safe-bash/dist/core.browser.js +5 -5
- package/packages/safe-bash/dist/playwright/capability-events.js +12 -2
- package/packages/safe-bash/dist/playwright/controller.js +38 -30
- package/packages/superintendent/dist/mcp.js +31 -22
- package/packages/tiny-mcp-client/dist/index.browser.js +6689 -0
- package/packages/tiny-mcp-client/dist/index.js +18 -17
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
YqValueFailure,
|
|
3
3
|
createYqQuerySession
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-TJVZY5W4.js";
|
|
5
5
|
import {
|
|
6
6
|
YqError,
|
|
7
7
|
YqLedger,
|
|
@@ -2683,4 +2683,4 @@ export {
|
|
|
2683
2683
|
evalSyncYqPrep,
|
|
2684
2684
|
formatSyncYqYamlLines
|
|
2685
2685
|
};
|
|
2686
|
-
//# sourceMappingURL=chunk-
|
|
2686
|
+
//# sourceMappingURL=chunk-BK5SQPI2.js.map
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
tryProcessFlatJsonChunkSync,
|
|
12
12
|
tryProcessFlatSelectProjectChunkSync,
|
|
13
13
|
tryWriteCompactSync
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-6YWMJV24.js";
|
|
15
15
|
import {
|
|
16
16
|
Budget,
|
|
17
17
|
JqError,
|
|
@@ -3090,4 +3090,4 @@ export {
|
|
|
3090
3090
|
createXmlCommands,
|
|
3091
3091
|
xmlCommands
|
|
3092
3092
|
};
|
|
3093
|
-
//# sourceMappingURL=chunk-
|
|
3093
|
+
//# sourceMappingURL=chunk-MH6MCUVD.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Interpreter,
|
|
3
3
|
parse
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-6YWMJV24.js";
|
|
5
5
|
import {
|
|
6
6
|
Budget,
|
|
7
7
|
Decimal,
|
|
@@ -598,4 +598,4 @@ export {
|
|
|
598
598
|
YqValueFailure,
|
|
599
599
|
createYqQuerySession
|
|
600
600
|
};
|
|
601
|
-
//# sourceMappingURL=chunk-
|
|
601
|
+
//# sourceMappingURL=chunk-TJVZY5W4.js.map
|
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
} from "./chunk-N2BYL2R2.js";
|
|
4
4
|
import {
|
|
5
5
|
createYqQuerySession
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-TJVZY5W4.js";
|
|
7
|
+
import "./chunk-6YWMJV24.js";
|
|
8
8
|
import "./chunk-CEWCRI6H.js";
|
|
9
9
|
import "./chunk-44WUNUPV.js";
|
|
10
10
|
import {
|
|
@@ -9880,4 +9880,4 @@ export {
|
|
|
9880
9880
|
parseRepoSpec,
|
|
9881
9881
|
settings
|
|
9882
9882
|
};
|
|
9883
|
-
//# sourceMappingURL=gh-
|
|
9883
|
+
//# sourceMappingURL=gh-JPPD7RUG.js.map
|
|
@@ -7,8 +7,8 @@ import {
|
|
|
7
7
|
evalSyncXq,
|
|
8
8
|
xmlCommands,
|
|
9
9
|
xmllintCommands
|
|
10
|
-
} from "../../chunks/chunk-
|
|
11
|
-
import "../../chunks/chunk-
|
|
10
|
+
} from "../../chunks/chunk-MH6MCUVD.js";
|
|
11
|
+
import "../../chunks/chunk-6YWMJV24.js";
|
|
12
12
|
import "../../chunks/chunk-CEWCRI6H.js";
|
|
13
13
|
import "../../chunks/chunk-44WUNUPV.js";
|
|
14
14
|
import "../../chunks/chunk-ZGNLZYQ4.js";
|
|
@@ -4,10 +4,10 @@ import {
|
|
|
4
4
|
evalSyncYqPrep,
|
|
5
5
|
formatSyncYqYamlLines,
|
|
6
6
|
yqCommands
|
|
7
|
-
} from "../../chunks/chunk-
|
|
8
|
-
import "../../chunks/chunk-
|
|
7
|
+
} from "../../chunks/chunk-BK5SQPI2.js";
|
|
8
|
+
import "../../chunks/chunk-TJVZY5W4.js";
|
|
9
9
|
import "../../chunks/chunk-4QTSSQKP.js";
|
|
10
|
-
import "../../chunks/chunk-
|
|
10
|
+
import "../../chunks/chunk-6YWMJV24.js";
|
|
11
11
|
import "../../chunks/chunk-CEWCRI6H.js";
|
|
12
12
|
import "../../chunks/chunk-44WUNUPV.js";
|
|
13
13
|
import "../../chunks/chunk-LLWAJOZH.js";
|
|
@@ -118,17 +118,17 @@ import {
|
|
|
118
118
|
sedRequirements,
|
|
119
119
|
xmlCommands,
|
|
120
120
|
xmllintCommands
|
|
121
|
-
} from "./chunks/chunk-
|
|
121
|
+
} from "./chunks/chunk-MH6MCUVD.js";
|
|
122
122
|
import {
|
|
123
123
|
createYqCommand,
|
|
124
124
|
createYqCommands,
|
|
125
125
|
evalSyncYqPrep,
|
|
126
126
|
formatSyncYqYamlLines,
|
|
127
127
|
yqCommands
|
|
128
|
-
} from "./chunks/chunk-
|
|
129
|
-
import "./chunks/chunk-
|
|
128
|
+
} from "./chunks/chunk-BK5SQPI2.js";
|
|
129
|
+
import "./chunks/chunk-TJVZY5W4.js";
|
|
130
130
|
import "./chunks/chunk-4QTSSQKP.js";
|
|
131
|
-
import "./chunks/chunk-
|
|
131
|
+
import "./chunks/chunk-6YWMJV24.js";
|
|
132
132
|
import {
|
|
133
133
|
Budget,
|
|
134
134
|
Pattern,
|
|
@@ -1353,7 +1353,7 @@ function lazyCommandPlugin(name2, commands, replace = false) {
|
|
|
1353
1353
|
}
|
|
1354
1354
|
|
|
1355
1355
|
// packages/safe-bash/src/lazy-gh.ts
|
|
1356
|
-
var loadgh = createLazyCommandLoader(() => import("./chunks/gh-
|
|
1356
|
+
var loadgh = createLazyCommandLoader(() => import("./chunks/gh-JPPD7RUG.js"));
|
|
1357
1357
|
var ghMetadata = [
|
|
1358
1358
|
{ name: "gh", description: "Work seamlessly with GitHub from the command line" }
|
|
1359
1359
|
];
|
|
@@ -34,8 +34,18 @@ export function observePlaywrightCapabilities(context, registerCleanup, limits)
|
|
|
34
34
|
history.set(record, { bytes: size, evict });
|
|
35
35
|
if (size > state.maxBytes)
|
|
36
36
|
forget(record);
|
|
37
|
-
while (history.size > (limits.maxEventEntries ?? Infinity) || bytes > state.maxBytes)
|
|
38
|
-
|
|
37
|
+
while (history.size > (limits.maxEventEntries ?? Infinity) || bytes > state.maxBytes) {
|
|
38
|
+
// Preserve active navigation metadata ahead of rolling diagnostics, while
|
|
39
|
+
// still applying the configured byte and entry budgets to every record.
|
|
40
|
+
let diagnostic;
|
|
41
|
+
for (const record of history.keys()) {
|
|
42
|
+
if (!('mainFrameNavigation' in record) || !record.mainFrameNavigation) {
|
|
43
|
+
diagnostic = record;
|
|
44
|
+
break;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
forget(diagnostic ?? history.keys().next().value);
|
|
48
|
+
}
|
|
39
49
|
};
|
|
40
50
|
const byteLength = (text) => new TextEncoder().encode(text).byteLength;
|
|
41
51
|
const pageEvents = (page) => {
|
|
@@ -969,12 +969,7 @@ export function createPlaywrightController(options = {}) {
|
|
|
969
969
|
return { sections };
|
|
970
970
|
}
|
|
971
971
|
sections.push(...await downloadSections(session));
|
|
972
|
-
|
|
973
|
-
const consoleLink = await flushPlaywrightConsole(session.lease.context, page, { ...(session.configuration ? { configuration: session.configuration } : {}), writeArtifact });
|
|
974
|
-
if (consoleLink)
|
|
975
|
-
sections.push({ title: 'Events', content: `- New console entries: ${consoleLink}` });
|
|
976
|
-
}
|
|
977
|
-
const pageSectionIndex = sections.length;
|
|
972
|
+
let pageSectionIndex = sections.length;
|
|
978
973
|
if (snapshot !== 'none' && (page.frames || page.ariaSnapshot || page._snapshotForAI || page.ariaSnapshotJSON || session.lease?.captureSnapshotJSON)) {
|
|
979
974
|
const snapshotOptions = { timeout: sessionSnapshotTimeout(session), ...(session.configuration?.snapshot?.boxes === undefined ? {} : { boxes: session.configuration.snapshot.boxes }), ...(session.lease?.captureSnapshotReferences ? { captureReferences: session.lease.captureSnapshotReferences } : {}) };
|
|
980
975
|
if (parsed.command === 'snapshot') {
|
|
@@ -986,18 +981,24 @@ export function createPlaywrightController(options = {}) {
|
|
|
986
981
|
}
|
|
987
982
|
if (parsed.options.boxes)
|
|
988
983
|
snapshotOptions.boxes = true;
|
|
989
|
-
if (parsed.args[0])
|
|
990
|
-
snapshotOptions.root = await resolveTarget(session, parsed.args[0]);
|
|
991
984
|
}
|
|
992
985
|
const captureWithHook = async (format, capture) => {
|
|
993
986
|
let active = true;
|
|
994
|
-
|
|
987
|
+
let pending = Promise.resolve();
|
|
988
|
+
const recapture = () => {
|
|
995
989
|
if (!active)
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
990
|
+
return Promise.reject(new Error('Playwright snapshot hook has completed'));
|
|
991
|
+
const operation = pending.then(async () => {
|
|
992
|
+
check();
|
|
993
|
+
if (parsed.command === 'snapshot' && parsed.args[0])
|
|
994
|
+
snapshotOptions.root = await resolveTarget(session, parsed.args[0]);
|
|
995
|
+
const value = await capture();
|
|
996
|
+
check();
|
|
997
|
+
return value;
|
|
998
|
+
});
|
|
999
|
+
// Observe failures immediately, and serialize all admitted captures.
|
|
1000
|
+
pending = operation.then(() => { }, () => { });
|
|
1001
|
+
return operation;
|
|
1001
1002
|
};
|
|
1002
1003
|
try {
|
|
1003
1004
|
const initial = await recapture();
|
|
@@ -1011,6 +1012,7 @@ export function createPlaywrightController(options = {}) {
|
|
|
1011
1012
|
}
|
|
1012
1013
|
finally {
|
|
1013
1014
|
active = false;
|
|
1015
|
+
await pending;
|
|
1014
1016
|
}
|
|
1015
1017
|
};
|
|
1016
1018
|
retained = false;
|
|
@@ -1019,24 +1021,30 @@ export function createPlaywrightController(options = {}) {
|
|
|
1019
1021
|
check();
|
|
1020
1022
|
retained = parsed.command === 'snapshot';
|
|
1021
1023
|
sections.push({ title: 'Snapshot', content: { json: tree }, codeframe: 'json' });
|
|
1022
|
-
return { sections };
|
|
1023
1024
|
}
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1025
|
+
else {
|
|
1026
|
+
retained = false;
|
|
1027
|
+
const text = await captureWithHook('yaml', () => session.snapshot.capture(page, local.signal, snapshotOptions));
|
|
1028
|
+
check();
|
|
1029
|
+
retained = parsed.command === 'snapshot';
|
|
1030
|
+
if (filename !== undefined || snapshot === 'file' && invocation.writeArtifact) {
|
|
1031
|
+
const target = filename ?? capabilityArtifactName('page', 'yml', session.configuration);
|
|
1032
|
+
const bytes = new TextEncoder().encode(text);
|
|
1033
|
+
if (bytes.byteLength > maxArtifactBytes)
|
|
1034
|
+
throw new PlaywrightResourceLimitError('Artifact byte limit exceeded');
|
|
1035
|
+
if (!invocation.writeArtifact)
|
|
1036
|
+
throw new Error('Artifact byte destination unsupported');
|
|
1037
|
+
await writeArtifact(bytes, target);
|
|
1038
|
+
sections.push({ title: 'Snapshot', content: `- [Snapshot](${target})` });
|
|
1039
|
+
}
|
|
1040
|
+
else
|
|
1041
|
+
sections.push({ title: 'Snapshot', content: text.trimEnd(), codeframe: 'yaml' });
|
|
1037
1042
|
}
|
|
1038
|
-
|
|
1039
|
-
|
|
1043
|
+
}
|
|
1044
|
+
if (invocation.writeArtifact) {
|
|
1045
|
+
const consoleLink = await flushPlaywrightConsole(session.lease.context, page, { ...(session.configuration ? { configuration: session.configuration } : {}), writeArtifact });
|
|
1046
|
+
if (consoleLink)
|
|
1047
|
+
sections.splice(pageSectionIndex++, 0, { title: 'Events', content: `- New console entries: ${consoleLink}` });
|
|
1040
1048
|
}
|
|
1041
1049
|
if (parsed.command !== 'snapshot' || !parsed.json) {
|
|
1042
1050
|
const title = await page.title?.();
|
|
@@ -17109,6 +17109,30 @@ var init_authorization_state = __esm({
|
|
|
17109
17109
|
}
|
|
17110
17110
|
});
|
|
17111
17111
|
|
|
17112
|
+
// packages/mcp-oauth/src/client/authorization-error.ts
|
|
17113
|
+
var authorizationErrorBrand, OAuthAuthorizationError;
|
|
17114
|
+
var init_authorization_error = __esm({
|
|
17115
|
+
"packages/mcp-oauth/src/client/authorization-error.ts"() {
|
|
17116
|
+
"use strict";
|
|
17117
|
+
authorizationErrorBrand = /* @__PURE__ */ Symbol.for("poe-platform.mcp-oauth.OAuthAuthorizationError");
|
|
17118
|
+
OAuthAuthorizationError = class extends Error {
|
|
17119
|
+
constructor(error2, errorDescription) {
|
|
17120
|
+
super(`OAuth authorization failed: ${error2} \u2014 ${errorDescription}`);
|
|
17121
|
+
this.error = error2;
|
|
17122
|
+
this.errorDescription = errorDescription;
|
|
17123
|
+
this.name = "OAuthAuthorizationError";
|
|
17124
|
+
Object.defineProperty(this, authorizationErrorBrand, { value: true });
|
|
17125
|
+
}
|
|
17126
|
+
error;
|
|
17127
|
+
errorDescription;
|
|
17128
|
+
/** Recognize errors from separately bundled copies of this package. */
|
|
17129
|
+
static is(value2) {
|
|
17130
|
+
return value2 instanceof Error && Object.getOwnPropertyDescriptor(value2, authorizationErrorBrand)?.value === true;
|
|
17131
|
+
}
|
|
17132
|
+
};
|
|
17133
|
+
}
|
|
17134
|
+
});
|
|
17135
|
+
|
|
17112
17136
|
// packages/mcp-oauth/src/client/loopback-authorization.ts
|
|
17113
17137
|
import http from "node:http";
|
|
17114
17138
|
function snapshotLoopbackAuthorizationOptions(options3) {
|
|
@@ -17374,28 +17398,14 @@ function buildSuccessPage(landingPage) {
|
|
|
17374
17398
|
"</div></body></html>"
|
|
17375
17399
|
].join("");
|
|
17376
17400
|
}
|
|
17377
|
-
var
|
|
17401
|
+
var oauthCallbackParameters;
|
|
17378
17402
|
var init_loopback_authorization = __esm({
|
|
17379
17403
|
"packages/mcp-oauth/src/client/loopback-authorization.ts"() {
|
|
17380
17404
|
"use strict";
|
|
17381
17405
|
init_authorization_state();
|
|
17382
|
-
|
|
17406
|
+
init_authorization_error();
|
|
17407
|
+
init_authorization_error();
|
|
17383
17408
|
oauthCallbackParameters = ["code", "state", "iss", "error", "error_description", "error_uri"];
|
|
17384
|
-
OAuthAuthorizationError = class extends Error {
|
|
17385
|
-
constructor(error2, errorDescription) {
|
|
17386
|
-
super(`OAuth authorization failed: ${error2} \u2014 ${errorDescription}`);
|
|
17387
|
-
this.error = error2;
|
|
17388
|
-
this.errorDescription = errorDescription;
|
|
17389
|
-
this.name = "OAuthAuthorizationError";
|
|
17390
|
-
Object.defineProperty(this, authorizationErrorBrand, { value: true });
|
|
17391
|
-
}
|
|
17392
|
-
error;
|
|
17393
|
-
errorDescription;
|
|
17394
|
-
/** Recognize errors from separately bundled copies of this package. */
|
|
17395
|
-
static is(value2) {
|
|
17396
|
-
return value2 instanceof Error && Object.getOwnPropertyDescriptor(value2, authorizationErrorBrand)?.value === true;
|
|
17397
|
-
}
|
|
17398
|
-
};
|
|
17399
17409
|
}
|
|
17400
17410
|
});
|
|
17401
17411
|
|
|
@@ -19907,7 +19917,6 @@ var init_http_response2 = __esm({
|
|
|
19907
19917
|
});
|
|
19908
19918
|
|
|
19909
19919
|
// packages/tiny-mcp-client/src/oauth-discovery.ts
|
|
19910
|
-
import { isIP as isIP2 } from "node:net";
|
|
19911
19920
|
function defaultOAuthMetadataFetch(input2, init) {
|
|
19912
19921
|
return fetch(input2, init);
|
|
19913
19922
|
}
|
|
@@ -19922,7 +19931,7 @@ function normalizeHostname2(hostname2) {
|
|
|
19922
19931
|
}
|
|
19923
19932
|
function isLoopbackHostname2(hostname2) {
|
|
19924
19933
|
const normalizedHostname = normalizeHostname2(hostname2);
|
|
19925
|
-
return normalizedHostname === "localhost" || normalizedHostname === "::1" || normalizedHostname === "[::1]" ||
|
|
19934
|
+
return normalizedHostname === "localhost" || normalizedHostname === "::1" || normalizedHostname === "[::1]" || normalizedHostname.startsWith("127.") && normalizedHostname.split(".").length === 4 && normalizedHostname.split(".").every((part) => part.length > 0 && [...part].every((char) => char >= "0" && char <= "9") && Number(part) <= 255);
|
|
19926
19935
|
}
|
|
19927
19936
|
function assertSecureUrl2(url, label) {
|
|
19928
19937
|
if (url.username !== "" || url.password !== "" || url.href.includes("#")) {
|
|
@@ -223060,7 +223069,7 @@ var init_poe_agent_plugin_system_prompt = __esm({
|
|
|
223060
223069
|
});
|
|
223061
223070
|
|
|
223062
223071
|
// packages/poe-agent/src/plugins/poe-agent-plugin-web.ts
|
|
223063
|
-
import { isIP as
|
|
223072
|
+
import { isIP as isIP2 } from "node:net";
|
|
223064
223073
|
import TurndownService from "turndown";
|
|
223065
223074
|
async function defaultSearchWeb(query, fetchFn, signal) {
|
|
223066
223075
|
const url = new URL("https://api.duckduckgo.com/");
|
|
@@ -223142,10 +223151,10 @@ function isNonPublicHost(hostname2) {
|
|
|
223142
223151
|
if (host2 === "localhost" || host2.endsWith(".localhost")) {
|
|
223143
223152
|
return true;
|
|
223144
223153
|
}
|
|
223145
|
-
if (
|
|
223154
|
+
if (isIP2(host2) === 4) {
|
|
223146
223155
|
return isNonPublicIpv4(host2);
|
|
223147
223156
|
}
|
|
223148
|
-
if (
|
|
223157
|
+
if (isIP2(host2) === 6) {
|
|
223149
223158
|
return isNonPublicIpv6(host2);
|
|
223150
223159
|
}
|
|
223151
223160
|
return false;
|