@hanzo/bot 2026.3.8 → 2026.3.9
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/{accounts-Cp7zE1zb.js → accounts-B-9Bhdn6.js} +17 -17
- package/dist/{accounts-B4Cft76I.js → accounts-C2vo5fEt.js} +2 -2
- package/dist/{accounts-C_LXSS3x.js → accounts-DNligSyz.js} +2 -2
- package/dist/{active-listener-BR7vpJxr.js → active-listener-zLV9i9LQ.js} +2 -2
- package/dist/{api-key-rotation-iYITGuLK.js → api-key-rotation-BENZC8ep.js} +2 -2
- package/dist/{audio-preflight-BEc8i-bS.js → audio-preflight-Bd44yEnM.js} +32 -32
- package/dist/{audio-transcription-runner-X1KzI7dF.js → audio-transcription-runner-CsXaWVup.js} +12 -12
- package/dist/{audit-membership-runtime-CVVxrZ7j.js → audit-membership-runtime-BJ149bTU.js} +4 -4
- package/dist/build-info.json +3 -3
- package/dist/bundled/boot-md/handler.js +51 -51
- package/dist/bundled/bootstrap-extra-files/handler.js +6 -6
- package/dist/bundled/command-logger/handler.js +2 -2
- package/dist/bundled/session-memory/handler.js +51 -51
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/{channel-activity-DR4SiHcg.js → channel-activity-DO-d_jr4.js} +3 -3
- package/dist/{chrome-C7OwLtx9.js → chrome-hkgY24uS.js} +26 -26
- package/dist/{commands-registry-Ce7SJnAP.js → commands-registry-C6INZSSX.js} +4 -4
- package/dist/{deliver-D8dBbzpu.js → deliver-B1PE5Kmq.js} +21 -21
- package/dist/deliver-runtime-L42k3QaI.js +36 -0
- package/dist/deps-send-discord.runtime-DSqcSnN3.js +26 -0
- package/dist/deps-send-imessage.runtime-Ch2ZcE2r.js +25 -0
- package/dist/deps-send-signal.runtime-c-v7bD8y.js +24 -0
- package/dist/deps-send-slack.runtime-xA-JRpSq.js +22 -0
- package/dist/deps-send-telegram.runtime-CO2npp7q.js +27 -0
- package/dist/deps-send-whatsapp.runtime-wvdxQphB.js +60 -0
- package/dist/{diagnostic-D1IbJfJM.js → diagnostic-Do7hUiao.js} +2 -2
- package/dist/entry.js +14 -7
- package/dist/{errors-CHd6Q-vF.js → errors-DDrhcWHi.js} +1 -1
- package/dist/{fetch-C6doVJxZ.js → fetch-BETRLmK8.js} +5 -5
- package/dist/{fetch-guard-C-neMX4E.js → fetch-guard-pwJ-F5aP.js} +2 -2
- package/dist/{frontmatter-B6XNqDx2.js → frontmatter-BFHzrAY7.js} +3 -3
- package/dist/{fs-safe-DmeSz0Nd.js → fs-safe-CeZ_BXcn.js} +4 -4
- package/dist/{github-copilot-token-BDioPmd6.js → github-copilot-token-D13V9YBz.js} +7 -7
- package/dist/{image-BOybyCis.js → image-DJo3nF6e.js} +6 -6
- package/dist/{image-ops-C-QWxnVw.js → image-ops-CLQ9abCf.js} +2 -2
- package/dist/image-runtime-Bd2-_2Fa.js +29 -0
- package/dist/{ir-B0iARYlT.js → ir-9Bn85Mqy.js} +8 -8
- package/dist/{legacy-names-DZdACm3t.js → legacy-names-Bkl4tjN-.js} +1 -1
- package/dist/llm-slug-generator.js +51 -51
- package/dist/{logger-LCC1m_20.js → logger-D4RcXHR-.js} +7 -7
- package/dist/{login-BbBqhgOM.js → login-nNeuyFrd.js} +5 -5
- package/dist/{login-qr-AAX0vgZR.js → login-qr-BEawmd_E.js} +10 -10
- package/dist/{manager-BOyc7q1-.js → manager-Bq6y1TH8.js} +13 -13
- package/dist/manager-runtime-DNkH2nza.js +18 -0
- package/dist/{model-selection-BNMWRHZu.js → model-selection-DQ5NblsF.js} +43 -43
- package/dist/{outbound-C72ULCcI.js → outbound-CPL9ID8o.js} +6 -6
- package/dist/{outbound-attachment-BF1JVcCB.js → outbound-attachment-BmiVeNLr.js} +2 -2
- package/dist/{path-alias-guards-BCv18tKc.js → path-alias-guards-DBVdJRcc.js} +1 -1
- package/dist/{paths-Cvc9EM8Y.js → paths-C6TxBCvO.js} +5 -5
- package/dist/{paths-l8GkNRRD.js → paths-Cgd1FfOW.js} +4 -4
- package/dist/{pi-embedded-BHXPs-Ix.js → pi-embedded-BYfpUcIY.js} +168 -168
- package/dist/{pi-embedded-helpers-xIXwvwuE.js → pi-embedded-helpers-_OL4yNw0.js} +52 -52
- package/dist/{pi-model-discovery-Cucu_uXw.js → pi-model-discovery-DANpv7pw.js} +7 -7
- package/dist/pi-model-discovery-runtime-Dr5-MM2j.js +11 -0
- package/dist/{pi-tools.before-tool-call.runtime-DQ2d5nM_.js → pi-tools.before-tool-call.runtime-CLb1M0uM.js} +9 -9
- package/dist/plugin-sdk/discord.js +6 -6
- package/dist/{plugins-YJZX7mvv.js → plugins-CeflwBVL.js} +13 -13
- package/dist/{proxy-env-CreSu2Ej.js → proxy-env-zUD967XQ.js} +1 -1
- package/dist/{proxy-fetch-lxJGuoUa.js → proxy-fetch-ChfJDZwG.js} +1 -1
- package/dist/{pw-ai-DsYmOxCp.js → pw-ai-yR5naMge.js} +14 -14
- package/dist/{qmd-manager-5C5L5YNn.js → qmd-manager-CWAXF3Vk.js} +10 -10
- package/dist/{query-expansion-BeRz7_bo.js → query-expansion-Cbd21KuP.js} +6 -6
- package/dist/{redact-DqlKR0-n.js → redact-DGz6yigq.js} +1 -1
- package/dist/{run-with-concurrency-ffnO0KnQ.js → run-with-concurrency-kEFC1Fle.js} +4 -4
- package/dist/runtime-whatsapp-login.runtime-BKnJdTKn.js +13 -0
- package/dist/runtime-whatsapp-outbound.runtime-DZYgfcRc.js +22 -0
- package/dist/{send-CmVj590_.js → send-Bi_r7Hno.js} +7 -7
- package/dist/{send-BrlM68Dd.js → send-C4kartXc.js} +6 -6
- package/dist/{send-Cp6dmr2f.js → send-CisFoCif.js} +28 -28
- package/dist/{send-BXQ1U9Zk.js → send-DKjV2v4c.js} +5 -5
- package/dist/{send-CKIMBFLs.js → send-DqQOo6dv.js} +8 -8
- package/dist/{session-DoD05Mm8.js → session-U4Hk8Woy.js} +8 -8
- package/dist/{skill-commands-DGy6Juvb.js → skill-commands-BN9qtrxT.js} +9 -9
- package/dist/{skills-BDJUqEFI.js → skills-DgwotBrr.js} +22 -22
- package/dist/slash-commands.runtime-iBi9rbmg.js +16 -0
- package/dist/slash-dispatch.runtime-8okSdt7k.js +56 -0
- package/dist/slash-skill-commands.runtime-a4qnxIQp.js +20 -0
- package/dist/{store-cJlS-gR6.js → store-CNWtYorN.js} +2 -2
- package/dist/subagent-registry-runtime-C4H5Ofm0.js +56 -0
- package/dist/{subsystem-CdFYjh2k.js → subsystem-W834z9Wa.js} +14 -14
- package/dist/{tables-CgcFNr6G.js → tables-DBZFzS9x.js} +1 -1
- package/dist/{target-errors-DPj6Es2y.js → target-errors-CxUP9L6c.js} +2 -2
- package/dist/{thinking-C3b10cHs.js → thinking-Xlbm5WNq.js} +7 -7
- package/dist/{tokens-mtgzW7UN.js → tokens-Cyi-NbsV.js} +1 -1
- package/dist/{tool-images-D9pdW1gE.js → tool-images-D217wDXi.js} +2 -2
- package/dist/{web-CREcqhe9.js → web-o9PMPEDK.js} +55 -55
- package/dist/{whatsapp-actions-nZnQ4BwK.js → whatsapp-actions-DmKZmCkz.js} +21 -21
- package/dist/{workspace-BC5WA0Th.js → workspace-CPNwHoy5.js} +20 -20
- package/extensions/acpx/package.json +1 -1
- package/extensions/bluebubbles/package.json +1 -1
- package/extensions/ci-fix-loop/package.json +1 -1
- package/extensions/continuous-learning/package.json +1 -1
- package/extensions/copilot-proxy/package.json +1 -1
- package/extensions/diagnostics-otel/package.json +1 -1
- package/extensions/diffs/package.json +1 -1
- package/extensions/discord/package.json +1 -1
- package/extensions/feishu/package.json +1 -1
- package/extensions/flow/package.json +1 -1
- package/extensions/google-antigravity-auth/package.json +1 -1
- package/extensions/google-gemini-cli-auth/package.json +1 -1
- package/extensions/googlechat/package.json +1 -1
- package/extensions/imessage/package.json +1 -1
- package/extensions/irc/package.json +1 -1
- package/extensions/line/package.json +1 -1
- package/extensions/llm-task/package.json +1 -1
- package/extensions/lobster/package.json +1 -1
- package/extensions/matrix/CHANGELOG.md +5 -0
- package/extensions/matrix/package.json +1 -1
- package/extensions/mattermost/package.json +1 -1
- package/extensions/memory-core/package.json +1 -1
- package/extensions/memory-lancedb/package.json +1 -1
- package/extensions/minimax-portal-auth/package.json +1 -1
- package/extensions/msteams/CHANGELOG.md +5 -0
- package/extensions/msteams/package.json +1 -1
- package/extensions/nextcloud-talk/package.json +1 -1
- package/extensions/nostr/CHANGELOG.md +5 -0
- package/extensions/nostr/package.json +1 -1
- package/extensions/open-prose/package.json +1 -1
- package/extensions/self-improvement/package.json +1 -1
- package/extensions/signal/package.json +1 -1
- package/extensions/slack/package.json +1 -1
- package/extensions/synology-chat/package.json +1 -1
- package/extensions/telegram/package.json +1 -1
- package/extensions/tlon/package.json +1 -1
- package/extensions/twitch/CHANGELOG.md +5 -0
- package/extensions/twitch/package.json +1 -1
- package/extensions/voice-call/CHANGELOG.md +5 -0
- package/extensions/voice-call/package.json +1 -1
- package/extensions/whatsapp/package.json +1 -1
- package/extensions/zalo/CHANGELOG.md +5 -0
- package/extensions/zalo/package.json +1 -1
- package/extensions/zalouser/CHANGELOG.md +5 -0
- package/extensions/zalouser/package.json +1 -1
- package/package.json +2 -1
- package/dist/deliver-runtime-C76IMU4W.js +0 -36
- package/dist/deps-send-discord.runtime-BM3uHet5.js +0 -26
- package/dist/deps-send-imessage.runtime-CBlUhUeN.js +0 -25
- package/dist/deps-send-signal.runtime-DnH0lazO.js +0 -24
- package/dist/deps-send-slack.runtime-Dmq0lsvR.js +0 -22
- package/dist/deps-send-telegram.runtime-33sbp3Ol.js +0 -27
- package/dist/deps-send-whatsapp.runtime-Cv_awFtm.js +0 -60
- package/dist/image-runtime-y4msd5bn.js +0 -29
- package/dist/manager-runtime-20Upetpf.js +0 -18
- package/dist/pi-model-discovery-runtime-BcJAGnf4.js +0 -11
- package/dist/runtime-whatsapp-login.runtime-BcbYtLph.js +0 -13
- package/dist/runtime-whatsapp-outbound.runtime-MIKcURpN.js +0 -22
- package/dist/slash-commands.runtime-2kptrdDi.js +0 -16
- package/dist/slash-dispatch.runtime-D28-UnsO.js +0 -56
- package/dist/slash-skill-commands.runtime-6jUbSMOW.js +0 -20
- package/dist/subagent-registry-runtime-Bt-LYyrB.js +0 -56
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import { f as resolveSessionAgentId, i as resolveAgentConfig } from "./run-with-concurrency-
|
|
2
|
-
import { a as resolveGatewayPort, d as resolveRequiredHomeDir, n as STATE_DIR } from "./paths-
|
|
3
|
-
import { i as defaultRuntime, t as createSubsystemLogger } from "./subsystem-
|
|
4
|
-
import { B as resolveAgentIdFromSessionKey, K as normalizeOptionalAccountId, N as buildAgentMainSessionKey, R as normalizeAgentId, T as resolvePathViaExistingAncestorSync, _ as runExec, a as DEFAULT_IDENTITY_FILENAME, b as openBoundaryFile, c as DEFAULT_USER_FILENAME, i as DEFAULT_HEARTBEAT_FILENAME, j as DEFAULT_AGENT_ID, l as ensureAgentWorkspace, n as DEFAULT_AGENT_WORKSPACE_DIR, o as DEFAULT_SOUL_FILENAME, r as DEFAULT_BOOTSTRAP_FILENAME, s as DEFAULT_TOOLS_FILENAME, t as DEFAULT_AGENTS_FILENAME, z as normalizeMainKey } from "./workspace-
|
|
5
|
-
import { E as truncateUtf16Safe, h as normalizeE164, y as resolveUserPath } from "./logger-
|
|
6
|
-
import { G as resolveSecretRefValues, Ht as CHANNEL_IDS, X as createConfigIO, Z as loadConfig, dr as isPidAlive, fr as formatCliCommand, gt as parseByteSize, ht as parseDurationMs, lr as resolveProcessScopedMap, mt as getBlockedNetworkModeReason, pt as secretRefKey, tt as writeConfigFile, ur as getProcessStartTime, vr as hasConfiguredSecretInput, xr as resolveSecretInputRef } from "./model-selection-
|
|
7
|
-
import { c as parseBooleanValue } from "./legacy-names-
|
|
8
|
-
import { d as getChannelDock, o as normalizeThinkLevel, v as normalizeHyphenSlug } from "./thinking-
|
|
9
|
-
import { r as normalizeChannelId, x as normalizeChatType } from "./plugins-
|
|
1
|
+
import { f as resolveSessionAgentId, i as resolveAgentConfig } from "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import { a as resolveGatewayPort, d as resolveRequiredHomeDir, n as STATE_DIR } from "./paths-C6TxBCvO.js";
|
|
3
|
+
import { i as defaultRuntime, t as createSubsystemLogger } from "./subsystem-W834z9Wa.js";
|
|
4
|
+
import { B as resolveAgentIdFromSessionKey, K as normalizeOptionalAccountId, N as buildAgentMainSessionKey, R as normalizeAgentId, T as resolvePathViaExistingAncestorSync, _ as runExec, a as DEFAULT_IDENTITY_FILENAME, b as openBoundaryFile, c as DEFAULT_USER_FILENAME, i as DEFAULT_HEARTBEAT_FILENAME, j as DEFAULT_AGENT_ID, l as ensureAgentWorkspace, n as DEFAULT_AGENT_WORKSPACE_DIR, o as DEFAULT_SOUL_FILENAME, r as DEFAULT_BOOTSTRAP_FILENAME, s as DEFAULT_TOOLS_FILENAME, t as DEFAULT_AGENTS_FILENAME, z as normalizeMainKey } from "./workspace-CPNwHoy5.js";
|
|
5
|
+
import { E as truncateUtf16Safe, h as normalizeE164, y as resolveUserPath } from "./logger-D4RcXHR-.js";
|
|
6
|
+
import { G as resolveSecretRefValues, Ht as CHANNEL_IDS, X as createConfigIO, Z as loadConfig, dr as isPidAlive, fr as formatCliCommand, gt as parseByteSize, ht as parseDurationMs, lr as resolveProcessScopedMap, mt as getBlockedNetworkModeReason, pt as secretRefKey, tt as writeConfigFile, ur as getProcessStartTime, vr as hasConfiguredSecretInput, xr as resolveSecretInputRef } from "./model-selection-DQ5NblsF.js";
|
|
7
|
+
import { c as parseBooleanValue } from "./legacy-names-Bkl4tjN-.js";
|
|
8
|
+
import { d as getChannelDock, o as normalizeThinkLevel, v as normalizeHyphenSlug } from "./thinking-Xlbm5WNq.js";
|
|
9
|
+
import { r as normalizeChannelId, x as normalizeChatType } from "./plugins-CeflwBVL.js";
|
|
10
10
|
import { t as generateSecureToken } from "./secure-random-CXrBi7Jq.js";
|
|
11
|
-
import { i as getImageMetadata, m as normalizeMessageChannel, n as buildImageResizeSideGrid, p as listDeliverableMessageChannels, s as resizeToJpeg, t as IMAGE_REDUCE_QUALITY_STEPS } from "./image-ops-
|
|
12
|
-
import { C as ensureChromeExtensionRelayServer, D as PROFILE_POST_RESTART_WS_TIMEOUT_MS, E as PROFILE_ATTACH_RETRY_TIMEOUT_MS, G as DEFAULT_BROWSER_EVALUATE_ENABLED, H as DEFAULT_AI_SNAPSHOT_EFFICIENT_MAX_CHARS, I as resolveWritablePathWithinRoot, J as DEFAULT_OPENCLAW_BROWSER_PROFILE_NAME, K as DEFAULT_OPENCLAW_BROWSER_COLOR, M as DEFAULT_TRACE_DIR, N as DEFAULT_UPLOAD_DIR, O as resolveCdpReachabilityTimeouts, P as resolveExistingPathsWithinRoot, R as normalizeBrowserFormField, T as CDP_JSON_NEW_TIMEOUT_MS, U as DEFAULT_AI_SNAPSHOT_MAX_CHARS, V as DEFAULT_AI_SNAPSHOT_EFFICIENT_DEPTH, W as DEFAULT_BROWSER_DEFAULT_PROFILE_NAME, _ as withBrowserNavigationPolicy, a as resolveOpenClawUserDataDir, b as fetchOk, c as resolveBrowserExecutableForPlatform, f as normalizeCdpWsUrl, g as assertBrowserNavigationResultAllowed, h as assertBrowserNavigationAllowed, i as launchOpenClawChrome, j as DEFAULT_DOWNLOAD_DIR, l as captureScreenshot, m as InvalidBrowserNavigationUrlError, n as isChromeCdpReady, o as stopOpenClawChrome, p as snapshotAria, q as DEFAULT_OPENCLAW_BROWSER_ENABLED, r as isChromeReachable, u as createTargetViaCdp, v as appendCdpPath, w as stopChromeExtensionRelayServer, y as fetchJson, z as isLoopbackHost } from "./chrome-
|
|
13
|
-
import { a as syncSkillsToWorkspace, l as resolveSandboxInputPath, m as sanitizeEnvVars, u as resolveSandboxPath } from "./skills-
|
|
14
|
-
import { t as PATH_ALIAS_POLICIES } from "./path-alias-guards-
|
|
15
|
-
import { n as extractErrorCode, r as formatErrorMessage } from "./errors-
|
|
16
|
-
import { n as SsrFBlockedError } from "./proxy-env-
|
|
17
|
-
import { i as saveMediaBuffer, n as ensureMediaDir } from "./store-
|
|
11
|
+
import { i as getImageMetadata, m as normalizeMessageChannel, n as buildImageResizeSideGrid, p as listDeliverableMessageChannels, s as resizeToJpeg, t as IMAGE_REDUCE_QUALITY_STEPS } from "./image-ops-CLQ9abCf.js";
|
|
12
|
+
import { C as ensureChromeExtensionRelayServer, D as PROFILE_POST_RESTART_WS_TIMEOUT_MS, E as PROFILE_ATTACH_RETRY_TIMEOUT_MS, G as DEFAULT_BROWSER_EVALUATE_ENABLED, H as DEFAULT_AI_SNAPSHOT_EFFICIENT_MAX_CHARS, I as resolveWritablePathWithinRoot, J as DEFAULT_OPENCLAW_BROWSER_PROFILE_NAME, K as DEFAULT_OPENCLAW_BROWSER_COLOR, M as DEFAULT_TRACE_DIR, N as DEFAULT_UPLOAD_DIR, O as resolveCdpReachabilityTimeouts, P as resolveExistingPathsWithinRoot, R as normalizeBrowserFormField, T as CDP_JSON_NEW_TIMEOUT_MS, U as DEFAULT_AI_SNAPSHOT_MAX_CHARS, V as DEFAULT_AI_SNAPSHOT_EFFICIENT_DEPTH, W as DEFAULT_BROWSER_DEFAULT_PROFILE_NAME, _ as withBrowserNavigationPolicy, a as resolveOpenClawUserDataDir, b as fetchOk, c as resolveBrowserExecutableForPlatform, f as normalizeCdpWsUrl, g as assertBrowserNavigationResultAllowed, h as assertBrowserNavigationAllowed, i as launchOpenClawChrome, j as DEFAULT_DOWNLOAD_DIR, l as captureScreenshot, m as InvalidBrowserNavigationUrlError, n as isChromeCdpReady, o as stopOpenClawChrome, p as snapshotAria, q as DEFAULT_OPENCLAW_BROWSER_ENABLED, r as isChromeReachable, u as createTargetViaCdp, v as appendCdpPath, w as stopChromeExtensionRelayServer, y as fetchJson, z as isLoopbackHost } from "./chrome-hkgY24uS.js";
|
|
13
|
+
import { a as syncSkillsToWorkspace, l as resolveSandboxInputPath, m as sanitizeEnvVars, u as resolveSandboxPath } from "./skills-DgwotBrr.js";
|
|
14
|
+
import { t as PATH_ALIAS_POLICIES } from "./path-alias-guards-DBVdJRcc.js";
|
|
15
|
+
import { n as extractErrorCode, r as formatErrorMessage } from "./errors-DDrhcWHi.js";
|
|
16
|
+
import { n as SsrFBlockedError } from "./proxy-env-zUD967XQ.js";
|
|
17
|
+
import { i as saveMediaBuffer, n as ensureMediaDir } from "./store-CNWtYorN.js";
|
|
18
18
|
import { n as resolveWindowsSpawnProgram, t as materializeWindowsSpawnProgram } from "./windows-spawn-B89VigUN.js";
|
|
19
19
|
import { i as writeTextAtomic, r as writeJsonAtomic } from "./json-files-D7-rxoSr.js";
|
|
20
|
-
import { a as resolveSessionTranscriptPathInDir, i as resolveSessionTranscriptPath, n as resolveSessionFilePath, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-
|
|
20
|
+
import { a as resolveSessionTranscriptPathInDir, i as resolveSessionTranscriptPath, n as resolveSessionFilePath, s as resolveStorePath, t as resolveDefaultSessionStorePath } from "./paths-Cgd1FfOW.js";
|
|
21
21
|
import { t as emitSessionTranscriptUpdate } from "./transcript-events-uYL2gEou.js";
|
|
22
|
-
import { t as sanitizeContentBlocksImages } from "./tool-images-
|
|
22
|
+
import { t as sanitizeContentBlocksImages } from "./tool-images-D217wDXi.js";
|
|
23
23
|
import fs from "node:fs/promises";
|
|
24
24
|
import os from "node:os";
|
|
25
25
|
import path, { posix } from "node:path";
|
|
26
|
-
import
|
|
26
|
+
import syncFs, { existsSync } from "node:fs";
|
|
27
27
|
import { spawn } from "node:child_process";
|
|
28
28
|
import crypto, { createHash, timingSafeEqual } from "node:crypto";
|
|
29
29
|
import { CURRENT_SESSION_VERSION, SessionManager } from "@mariozechner/pi-coding-agent";
|
|
@@ -1353,7 +1353,7 @@ function isModuleNotFoundError(err) {
|
|
|
1353
1353
|
}
|
|
1354
1354
|
async function loadPwAiModule(mode) {
|
|
1355
1355
|
try {
|
|
1356
|
-
return await import("./pw-ai-
|
|
1356
|
+
return await import("./pw-ai-yR5naMge.js");
|
|
1357
1357
|
} catch (err) {
|
|
1358
1358
|
if (mode === "soft") return null;
|
|
1359
1359
|
if (isModuleNotFoundError(err)) return null;
|
|
@@ -3130,11 +3130,11 @@ async function movePathToTrash(targetPath) {
|
|
|
3130
3130
|
return targetPath;
|
|
3131
3131
|
} catch {
|
|
3132
3132
|
const trashDir = path.join(os.homedir(), ".Trash");
|
|
3133
|
-
|
|
3133
|
+
syncFs.mkdirSync(trashDir, { recursive: true });
|
|
3134
3134
|
const base = path.basename(targetPath);
|
|
3135
3135
|
let dest = path.join(trashDir, `${base}-${Date.now()}`);
|
|
3136
|
-
if (
|
|
3137
|
-
|
|
3136
|
+
if (syncFs.existsSync(dest)) dest = path.join(trashDir, `${base}-${Date.now()}-${generateSecureToken(6)}`);
|
|
3137
|
+
syncFs.renameSync(targetPath, dest);
|
|
3138
3138
|
return dest;
|
|
3139
3139
|
}
|
|
3140
3140
|
}
|
|
@@ -3221,7 +3221,7 @@ function createBrowserProfilesService(ctx) {
|
|
|
3221
3221
|
} catch {}
|
|
3222
3222
|
const userDataDir = resolveOpenClawUserDataDir(name);
|
|
3223
3223
|
const profileDir = path.dirname(userDataDir);
|
|
3224
|
-
if (
|
|
3224
|
+
if (syncFs.existsSync(profileDir)) {
|
|
3225
3225
|
await movePathToTrash(profileDir);
|
|
3226
3226
|
deleted = true;
|
|
3227
3227
|
}
|
|
@@ -3719,7 +3719,7 @@ function createProfileAvailability({ opts, profile, state, getProfileState, setP
|
|
|
3719
3719
|
//#region src/browser/server-context.reset.ts
|
|
3720
3720
|
async function closePlaywrightBrowserConnection() {
|
|
3721
3721
|
try {
|
|
3722
|
-
await (await import("./pw-ai-
|
|
3722
|
+
await (await import("./pw-ai-yR5naMge.js")).closePlaywrightBrowserConnection();
|
|
3723
3723
|
} catch {}
|
|
3724
3724
|
}
|
|
3725
3725
|
function createProfileResetOps({ profile, getProfileState, stopRunningBrowser, isHttpReachable, resolveOpenClawUserDataDir }) {
|
|
@@ -3737,7 +3737,7 @@ function createProfileResetOps({ profile, getProfileState, stopRunningBrowser, i
|
|
|
3737
3737
|
if (await isHttpReachable(300) && !profileState.running) await closePlaywrightBrowserConnection();
|
|
3738
3738
|
if (profileState.running) await stopRunningBrowser();
|
|
3739
3739
|
await closePlaywrightBrowserConnection();
|
|
3740
|
-
if (!
|
|
3740
|
+
if (!syncFs.existsSync(userDataDir)) return {
|
|
3741
3741
|
moved: false,
|
|
3742
3742
|
from: userDataDir
|
|
3743
3743
|
};
|
|
@@ -4485,7 +4485,7 @@ function releaseAllLocksSync() {
|
|
|
4485
4485
|
if (typeof held.handle.close === "function") held.handle.close().catch(() => {});
|
|
4486
4486
|
} catch {}
|
|
4487
4487
|
try {
|
|
4488
|
-
|
|
4488
|
+
syncFs.rmSync(held.lockPath, { force: true });
|
|
4489
4489
|
} catch {}
|
|
4490
4490
|
HELD_LOCKS.delete(sessionFile);
|
|
4491
4491
|
}
|
|
@@ -6083,7 +6083,7 @@ var SandboxFsBridgeImpl = class {
|
|
|
6083
6083
|
if (guarded.reason !== "path") {
|
|
6084
6084
|
if (!(options.allowedType === "directory" && this.pathIsExistingDirectory(target.hostPath))) throw guarded.error instanceof Error ? guarded.error : /* @__PURE__ */ new Error(`Sandbox boundary checks failed; cannot ${options.action}: ${target.containerPath}`);
|
|
6085
6085
|
}
|
|
6086
|
-
} else
|
|
6086
|
+
} else syncFs.closeSync(guarded.fd);
|
|
6087
6087
|
const canonicalContainerPath = await this.resolveCanonicalContainerPath({
|
|
6088
6088
|
containerPath: target.containerPath,
|
|
6089
6089
|
allowFinalSymlinkForUnlink: options.aliasPolicy?.allowFinalSymlinkForUnlink === true
|
|
@@ -6094,7 +6094,7 @@ var SandboxFsBridgeImpl = class {
|
|
|
6094
6094
|
}
|
|
6095
6095
|
pathIsExistingDirectory(hostPath) {
|
|
6096
6096
|
try {
|
|
6097
|
-
return
|
|
6097
|
+
return syncFs.statSync(hostPath).isDirectory();
|
|
6098
6098
|
} catch {
|
|
6099
6099
|
return false;
|
|
6100
6100
|
}
|
|
@@ -6895,14 +6895,14 @@ function resolveSessionTranscriptCandidates(sessionId, storePath, sessionFile, a
|
|
|
6895
6895
|
function canonicalizePathForComparison$1(filePath) {
|
|
6896
6896
|
const resolved = path.resolve(filePath);
|
|
6897
6897
|
try {
|
|
6898
|
-
return
|
|
6898
|
+
return syncFs.realpathSync(resolved);
|
|
6899
6899
|
} catch {
|
|
6900
6900
|
return resolved;
|
|
6901
6901
|
}
|
|
6902
6902
|
}
|
|
6903
6903
|
function archiveFileOnDisk(filePath, reason) {
|
|
6904
6904
|
const archived = `${filePath}.${reason}.${formatSessionArchiveTimestamp()}`;
|
|
6905
|
-
|
|
6905
|
+
syncFs.renameSync(filePath, archived);
|
|
6906
6906
|
return archived;
|
|
6907
6907
|
}
|
|
6908
6908
|
/**
|
|
@@ -6918,7 +6918,7 @@ function archiveSessionTranscripts(opts) {
|
|
|
6918
6918
|
const relative = path.relative(storeDir, candidatePath);
|
|
6919
6919
|
if (!relative || relative.startsWith("..") || path.isAbsolute(relative)) continue;
|
|
6920
6920
|
}
|
|
6921
|
-
if (!
|
|
6921
|
+
if (!syncFs.existsSync(candidatePath)) continue;
|
|
6922
6922
|
try {
|
|
6923
6923
|
archived.push(archiveFileOnDisk(candidatePath, opts.reason));
|
|
6924
6924
|
} catch {}
|
|
@@ -6936,15 +6936,15 @@ async function cleanupArchivedSessionTranscripts(opts) {
|
|
|
6936
6936
|
let removed = 0;
|
|
6937
6937
|
let scanned = 0;
|
|
6938
6938
|
for (const dir of directories) {
|
|
6939
|
-
const entries = await
|
|
6939
|
+
const entries = await syncFs.promises.readdir(dir).catch(() => []);
|
|
6940
6940
|
for (const entry of entries) {
|
|
6941
6941
|
const timestamp = parseSessionArchiveTimestamp(entry, reason);
|
|
6942
6942
|
if (timestamp == null) continue;
|
|
6943
6943
|
scanned += 1;
|
|
6944
6944
|
if (now - timestamp <= opts.olderThanMs) continue;
|
|
6945
6945
|
const fullPath = path.join(dir, entry);
|
|
6946
|
-
if (!(await
|
|
6947
|
-
await
|
|
6946
|
+
if (!(await syncFs.promises.stat(fullPath).catch(() => null))?.isFile()) continue;
|
|
6947
|
+
await syncFs.promises.rm(fullPath).catch(() => void 0);
|
|
6948
6948
|
removed += 1;
|
|
6949
6949
|
}
|
|
6950
6950
|
}
|
|
@@ -7074,7 +7074,7 @@ function isCacheEnabled(ttlMs) {
|
|
|
7074
7074
|
}
|
|
7075
7075
|
function getFileStatSnapshot(filePath) {
|
|
7076
7076
|
try {
|
|
7077
|
-
const stats =
|
|
7077
|
+
const stats = syncFs.statSync(filePath);
|
|
7078
7078
|
return {
|
|
7079
7079
|
mtimeMs: stats.mtimeMs,
|
|
7080
7080
|
sizeBytes: stats.size
|
|
@@ -7093,7 +7093,7 @@ const NOOP_LOGGER = {
|
|
|
7093
7093
|
function canonicalizePathForComparison(filePath) {
|
|
7094
7094
|
const resolved = path.resolve(filePath);
|
|
7095
7095
|
try {
|
|
7096
|
-
return
|
|
7096
|
+
return syncFs.realpathSync(resolved);
|
|
7097
7097
|
} catch {
|
|
7098
7098
|
return resolved;
|
|
7099
7099
|
}
|
|
@@ -7151,12 +7151,12 @@ function resolveReferencedSessionTranscriptPaths(params) {
|
|
|
7151
7151
|
return referenced;
|
|
7152
7152
|
}
|
|
7153
7153
|
async function readSessionsDirFiles(sessionsDir) {
|
|
7154
|
-
const dirEntries = await
|
|
7154
|
+
const dirEntries = await syncFs.promises.readdir(sessionsDir, { withFileTypes: true }).catch(() => []);
|
|
7155
7155
|
const files = [];
|
|
7156
7156
|
for (const dirent of dirEntries) {
|
|
7157
7157
|
if (!dirent.isFile()) continue;
|
|
7158
7158
|
const filePath = path.join(sessionsDir, dirent.name);
|
|
7159
|
-
const stat = await
|
|
7159
|
+
const stat = await syncFs.promises.stat(filePath).catch(() => null);
|
|
7160
7160
|
if (!stat?.isFile()) continue;
|
|
7161
7161
|
files.push({
|
|
7162
7162
|
path: filePath,
|
|
@@ -7169,9 +7169,9 @@ async function readSessionsDirFiles(sessionsDir) {
|
|
|
7169
7169
|
return files;
|
|
7170
7170
|
}
|
|
7171
7171
|
async function removeFileIfExists(filePath) {
|
|
7172
|
-
const stat = await
|
|
7172
|
+
const stat = await syncFs.promises.stat(filePath).catch(() => null);
|
|
7173
7173
|
if (!stat?.isFile()) return 0;
|
|
7174
|
-
await
|
|
7174
|
+
await syncFs.promises.rm(filePath, { force: true }).catch(() => void 0);
|
|
7175
7175
|
return stat.size;
|
|
7176
7176
|
}
|
|
7177
7177
|
async function removeFileForBudget(params) {
|
|
@@ -7530,7 +7530,7 @@ function capEntryCount(store, overrideMax, opts = {}) {
|
|
|
7530
7530
|
}
|
|
7531
7531
|
async function getSessionFileSize(storePath) {
|
|
7532
7532
|
try {
|
|
7533
|
-
return (await
|
|
7533
|
+
return (await syncFs.promises.stat(storePath)).size;
|
|
7534
7534
|
} catch {
|
|
7535
7535
|
return null;
|
|
7536
7536
|
}
|
|
@@ -7547,7 +7547,7 @@ async function rotateSessionFile(storePath, overrideBytes) {
|
|
|
7547
7547
|
if (fileSize <= maxBytes) return false;
|
|
7548
7548
|
const backupPath = `${storePath}.bak.${Date.now()}`;
|
|
7549
7549
|
try {
|
|
7550
|
-
await
|
|
7550
|
+
await syncFs.promises.rename(storePath, backupPath);
|
|
7551
7551
|
log$2.info("rotated session store file", {
|
|
7552
7552
|
backupPath: path.basename(backupPath),
|
|
7553
7553
|
sizeBytes: fileSize
|
|
@@ -7558,11 +7558,11 @@ async function rotateSessionFile(storePath, overrideBytes) {
|
|
|
7558
7558
|
try {
|
|
7559
7559
|
const dir = path.dirname(storePath);
|
|
7560
7560
|
const baseName = path.basename(storePath);
|
|
7561
|
-
const backups = (await
|
|
7561
|
+
const backups = (await syncFs.promises.readdir(dir)).filter((f) => f.startsWith(`${baseName}.bak.`)).toSorted().toReversed();
|
|
7562
7562
|
const maxBackups = 3;
|
|
7563
7563
|
if (backups.length > maxBackups) {
|
|
7564
7564
|
const toDelete = backups.slice(maxBackups);
|
|
7565
|
-
for (const old of toDelete) await
|
|
7565
|
+
for (const old of toDelete) await syncFs.promises.unlink(path.join(dir, old)).catch(() => void 0);
|
|
7566
7566
|
log$2.info("cleaned up old session store backups", { deleted: toDelete.length });
|
|
7567
7567
|
}
|
|
7568
7568
|
} catch {}
|
|
@@ -7685,7 +7685,7 @@ function loadSessionStore(storePath, opts = {}) {
|
|
|
7685
7685
|
const maxReadAttempts = process.platform === "win32" ? 3 : 1;
|
|
7686
7686
|
const retryBuf = maxReadAttempts > 1 ? new Int32Array(new SharedArrayBuffer(4)) : void 0;
|
|
7687
7687
|
for (let attempt = 0; attempt < maxReadAttempts; attempt++) try {
|
|
7688
|
-
const raw =
|
|
7688
|
+
const raw = syncFs.readFileSync(storePath, "utf-8");
|
|
7689
7689
|
if (raw.length === 0 && attempt < maxReadAttempts - 1) {
|
|
7690
7690
|
Atomics.wait(retryBuf, 0, 0, 50);
|
|
7691
7691
|
continue;
|
|
@@ -7839,7 +7839,7 @@ async function saveSessionStoreUnlocked(storePath, store, opts) {
|
|
|
7839
7839
|
});
|
|
7840
7840
|
}
|
|
7841
7841
|
}
|
|
7842
|
-
await
|
|
7842
|
+
await syncFs.promises.mkdir(path.dirname(storePath), { recursive: true });
|
|
7843
7843
|
const json = JSON.stringify(store, null, 2);
|
|
7844
7844
|
if (getSerializedSessionStore(storePath) === json) {
|
|
7845
7845
|
updateSessionStoreWriteCaches({
|
|
@@ -8176,8 +8176,8 @@ function resolveMirroredTranscriptText(params) {
|
|
|
8176
8176
|
return trimmed ? trimmed : null;
|
|
8177
8177
|
}
|
|
8178
8178
|
async function ensureSessionHeader(params) {
|
|
8179
|
-
if (
|
|
8180
|
-
await
|
|
8179
|
+
if (syncFs.existsSync(params.sessionFile)) return;
|
|
8180
|
+
await syncFs.promises.mkdir(path.dirname(params.sessionFile), { recursive: true });
|
|
8181
8181
|
const header = {
|
|
8182
8182
|
type: "session",
|
|
8183
8183
|
version: CURRENT_SESSION_VERSION,
|
|
@@ -8185,7 +8185,7 @@ async function ensureSessionHeader(params) {
|
|
|
8185
8185
|
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
8186
8186
|
cwd: process.cwd()
|
|
8187
8187
|
};
|
|
8188
|
-
await
|
|
8188
|
+
await syncFs.promises.writeFile(params.sessionFile, `${JSON.stringify(header)}\n`, {
|
|
8189
8189
|
encoding: "utf-8",
|
|
8190
8190
|
mode: 384
|
|
8191
8191
|
});
|
|
@@ -8420,13 +8420,13 @@ async function ensureSandboxWorkspace(workspaceDir, seedFrom, skipBootstrap) {
|
|
|
8420
8420
|
});
|
|
8421
8421
|
if (!opened.ok) continue;
|
|
8422
8422
|
try {
|
|
8423
|
-
const content =
|
|
8423
|
+
const content = syncFs.readFileSync(opened.fd, "utf-8");
|
|
8424
8424
|
await fs.writeFile(dest, content, {
|
|
8425
8425
|
encoding: "utf-8",
|
|
8426
8426
|
flag: "wx"
|
|
8427
8427
|
});
|
|
8428
8428
|
} finally {
|
|
8429
|
-
|
|
8429
|
+
syncFs.closeSync(opened.fd);
|
|
8430
8430
|
}
|
|
8431
8431
|
} catch {}
|
|
8432
8432
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-Cbj13DAv.js";
|
|
2
|
-
import { ar as ensureAuthProfileStore, c as normalizeProviderId } from "./model-selection-
|
|
2
|
+
import { ar as ensureAuthProfileStore, c as normalizeProviderId } from "./model-selection-DQ5NblsF.js";
|
|
3
3
|
import path from "node:path";
|
|
4
|
-
import
|
|
4
|
+
import syncFs from "node:fs";
|
|
5
5
|
import * as PiCodingAgent from "@mariozechner/pi-coding-agent";
|
|
6
6
|
|
|
7
7
|
//#region src/agents/pi-auth-credentials.ts
|
|
@@ -70,10 +70,10 @@ function isRecord(value) {
|
|
|
70
70
|
}
|
|
71
71
|
function scrubLegacyStaticAuthJsonEntries(pathname) {
|
|
72
72
|
if (process.env.OPENCLAW_AUTH_STORE_READONLY === "1") return;
|
|
73
|
-
if (!
|
|
73
|
+
if (!syncFs.existsSync(pathname)) return;
|
|
74
74
|
let parsed;
|
|
75
75
|
try {
|
|
76
|
-
parsed = JSON.parse(
|
|
76
|
+
parsed = JSON.parse(syncFs.readFileSync(pathname, "utf8"));
|
|
77
77
|
} catch {
|
|
78
78
|
return;
|
|
79
79
|
}
|
|
@@ -87,11 +87,11 @@ function scrubLegacyStaticAuthJsonEntries(pathname) {
|
|
|
87
87
|
}
|
|
88
88
|
if (!changed) return;
|
|
89
89
|
if (Object.keys(parsed).length === 0) {
|
|
90
|
-
|
|
90
|
+
syncFs.rmSync(pathname, { force: true });
|
|
91
91
|
return;
|
|
92
92
|
}
|
|
93
|
-
|
|
94
|
-
|
|
93
|
+
syncFs.writeFileSync(pathname, `${JSON.stringify(parsed, null, 2)}\n`, "utf8");
|
|
94
|
+
syncFs.chmodSync(pathname, 384);
|
|
95
95
|
}
|
|
96
96
|
function createAuthStorage(AuthStorageLike, path, creds) {
|
|
97
97
|
const withInMemory = AuthStorageLike;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import "./paths-C6TxBCvO.js";
|
|
3
|
+
import "./subsystem-W834z9Wa.js";
|
|
4
|
+
import "./workspace-CPNwHoy5.js";
|
|
5
|
+
import "./logger-D4RcXHR-.js";
|
|
6
|
+
import "./model-selection-DQ5NblsF.js";
|
|
7
|
+
import "./github-copilot-token-D13V9YBz.js";
|
|
8
|
+
import "./legacy-names-Bkl4tjN-.js";
|
|
9
|
+
import { n as discoverModels, t as discoverAuthStorage } from "./pi-model-discovery-DANpv7pw.js";
|
|
10
|
+
|
|
11
|
+
export { discoverAuthStorage, discoverModels };
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./run-with-concurrency-
|
|
2
|
-
import "./paths-
|
|
3
|
-
import { t as createSubsystemLogger } from "./subsystem-
|
|
4
|
-
import "./workspace-
|
|
5
|
-
import { D as isPlainObject } from "./logger-
|
|
6
|
-
import "./model-selection-
|
|
7
|
-
import "./github-copilot-token-
|
|
8
|
-
import "./legacy-names-
|
|
9
|
-
import { p as getDiagnosticSessionState, s as logToolLoopAction } from "./diagnostic-
|
|
1
|
+
import "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import "./paths-C6TxBCvO.js";
|
|
3
|
+
import { t as createSubsystemLogger } from "./subsystem-W834z9Wa.js";
|
|
4
|
+
import "./workspace-CPNwHoy5.js";
|
|
5
|
+
import { D as isPlainObject } from "./logger-D4RcXHR-.js";
|
|
6
|
+
import "./model-selection-DQ5NblsF.js";
|
|
7
|
+
import "./github-copilot-token-D13V9YBz.js";
|
|
8
|
+
import "./legacy-names-Bkl4tjN-.js";
|
|
9
|
+
import { p as getDiagnosticSessionState, s as logToolLoopAction } from "./diagnostic-Do7hUiao.js";
|
|
10
10
|
import { createHash } from "node:crypto";
|
|
11
11
|
|
|
12
12
|
//#region src/agents/tool-loop-detection.ts
|
|
@@ -4,7 +4,7 @@ import chalk, { Chalk } from "chalk";
|
|
|
4
4
|
import fs, { constants } from "node:fs";
|
|
5
5
|
import { Logger } from "tslog";
|
|
6
6
|
import os from "node:os";
|
|
7
|
-
import
|
|
7
|
+
import json5 from "json5";
|
|
8
8
|
import { isDeepStrictEqual, promisify } from "node:util";
|
|
9
9
|
import fs$1 from "node:fs/promises";
|
|
10
10
|
import { execFile, execFileSync, spawn } from "node:child_process";
|
|
@@ -812,7 +812,7 @@ function readLoggingConfig() {
|
|
|
812
812
|
try {
|
|
813
813
|
if (!fs.existsSync(configPath)) return;
|
|
814
814
|
const raw = fs.readFileSync(configPath, "utf-8");
|
|
815
|
-
const logging =
|
|
815
|
+
const logging = json5.parse(raw)?.logging;
|
|
816
816
|
if (!logging || typeof logging !== "object" || Array.isArray(logging)) return;
|
|
817
817
|
return logging;
|
|
818
818
|
} catch {
|
|
@@ -6046,7 +6046,7 @@ const defaultResolver = {
|
|
|
6046
6046
|
resolvedPath,
|
|
6047
6047
|
rootRealDir
|
|
6048
6048
|
}),
|
|
6049
|
-
parseJson: (raw) =>
|
|
6049
|
+
parseJson: (raw) => json5.parse(raw)
|
|
6050
6050
|
};
|
|
6051
6051
|
/**
|
|
6052
6052
|
* Resolves all $include directives in a parsed config object.
|
|
@@ -13506,7 +13506,7 @@ function resolveConfigPathForDeps(deps) {
|
|
|
13506
13506
|
function normalizeDeps(overrides = {}) {
|
|
13507
13507
|
return {
|
|
13508
13508
|
fs: overrides.fs ?? fs,
|
|
13509
|
-
json5: overrides.json5 ??
|
|
13509
|
+
json5: overrides.json5 ?? json5,
|
|
13510
13510
|
env: overrides.env ?? process.env,
|
|
13511
13511
|
homedir: overrides.homedir ?? (() => resolveRequiredHomeDir(overrides.env ?? process.env, os.homedir)),
|
|
13512
13512
|
configPath: overrides.configPath ?? "",
|
|
@@ -13517,11 +13517,11 @@ function maybeLoadDotEnvForConfig(env) {
|
|
|
13517
13517
|
if (env !== process.env) return;
|
|
13518
13518
|
loadDotEnv({ quiet: true });
|
|
13519
13519
|
}
|
|
13520
|
-
function parseConfigJson5(raw, json5 =
|
|
13520
|
+
function parseConfigJson5(raw, json5$1 = json5) {
|
|
13521
13521
|
try {
|
|
13522
13522
|
return {
|
|
13523
13523
|
ok: true,
|
|
13524
|
-
parsed: json5.parse(raw)
|
|
13524
|
+
parsed: json5$1.parse(raw)
|
|
13525
13525
|
};
|
|
13526
13526
|
} catch (err) {
|
|
13527
13527
|
return {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { l as resolveDefaultAgentId } from "./run-with-concurrency-
|
|
2
|
-
import { t as createSubsystemLogger } from "./subsystem-
|
|
3
|
-
import { G as normalizeAccountId, K as normalizeOptionalAccountId, R as normalizeAgentId, W as DEFAULT_ACCOUNT_ID } from "./workspace-
|
|
4
|
-
import { h as normalizeE164 } from "./logger-
|
|
5
|
-
import { Jt as normalizeChatChannelId, Kt as normalizeAnyChannelId, Qt as requireActivePluginRegistry, Ut as CHAT_CHANNEL_ORDER, Zt as getActivePluginRegistryVersion, br as normalizeSecretInputString, er as isTruthyEnvValue, vr as hasConfiguredSecretInput, yr as normalizeResolvedSecretInputString } from "./model-selection-
|
|
6
|
-
import { g as resolveAccountEntry, h as createAccountListHelpers } from "./accounts-
|
|
7
|
-
import
|
|
1
|
+
import { l as resolveDefaultAgentId } from "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import { t as createSubsystemLogger } from "./subsystem-W834z9Wa.js";
|
|
3
|
+
import { G as normalizeAccountId, K as normalizeOptionalAccountId, R as normalizeAgentId, W as DEFAULT_ACCOUNT_ID } from "./workspace-CPNwHoy5.js";
|
|
4
|
+
import { h as normalizeE164 } from "./logger-D4RcXHR-.js";
|
|
5
|
+
import { Jt as normalizeChatChannelId, Kt as normalizeAnyChannelId, Qt as requireActivePluginRegistry, Ut as CHAT_CHANNEL_ORDER, Zt as getActivePluginRegistryVersion, br as normalizeSecretInputString, er as isTruthyEnvValue, vr as hasConfiguredSecretInput, yr as normalizeResolvedSecretInputString } from "./model-selection-DQ5NblsF.js";
|
|
6
|
+
import { g as resolveAccountEntry, h as createAccountListHelpers } from "./accounts-B-9Bhdn6.js";
|
|
7
|
+
import syncFs from "node:fs";
|
|
8
8
|
import util from "node:util";
|
|
9
9
|
|
|
10
10
|
//#region src/channels/plugins/account-action-gate.ts
|
|
@@ -512,7 +512,7 @@ function resolveTelegramToken(cfg, opts = {}) {
|
|
|
512
512
|
const accountCfg = resolveAccountCfg(accountId !== DEFAULT_ACCOUNT_ID ? accountId : DEFAULT_ACCOUNT_ID);
|
|
513
513
|
const accountTokenFile = accountCfg?.tokenFile?.trim();
|
|
514
514
|
if (accountTokenFile) {
|
|
515
|
-
if (!
|
|
515
|
+
if (!syncFs.existsSync(accountTokenFile)) {
|
|
516
516
|
opts.logMissingFile?.(`channels.telegram.accounts.${accountId}.tokenFile not found: ${accountTokenFile}`);
|
|
517
517
|
return {
|
|
518
518
|
token: "",
|
|
@@ -520,7 +520,7 @@ function resolveTelegramToken(cfg, opts = {}) {
|
|
|
520
520
|
};
|
|
521
521
|
}
|
|
522
522
|
try {
|
|
523
|
-
const token =
|
|
523
|
+
const token = syncFs.readFileSync(accountTokenFile, "utf-8").trim();
|
|
524
524
|
if (token) return {
|
|
525
525
|
token,
|
|
526
526
|
source: "tokenFile"
|
|
@@ -548,7 +548,7 @@ function resolveTelegramToken(cfg, opts = {}) {
|
|
|
548
548
|
const allowEnv = accountId === DEFAULT_ACCOUNT_ID;
|
|
549
549
|
const tokenFile = telegramCfg?.tokenFile?.trim();
|
|
550
550
|
if (tokenFile) {
|
|
551
|
-
if (!
|
|
551
|
+
if (!syncFs.existsSync(tokenFile)) {
|
|
552
552
|
opts.logMissingFile?.(`channels.telegram.tokenFile not found: ${tokenFile}`);
|
|
553
553
|
return {
|
|
554
554
|
token: "",
|
|
@@ -556,7 +556,7 @@ function resolveTelegramToken(cfg, opts = {}) {
|
|
|
556
556
|
};
|
|
557
557
|
}
|
|
558
558
|
try {
|
|
559
|
-
const token =
|
|
559
|
+
const token = syncFs.readFileSync(tokenFile, "utf-8").trim();
|
|
560
560
|
if (token) return {
|
|
561
561
|
token,
|
|
562
562
|
source: "tokenFile"
|
|
@@ -720,13 +720,13 @@ function mergeTelegramAccountConfig(cfg, accountId) {
|
|
|
720
720
|
function inspectTokenFile(pathValue) {
|
|
721
721
|
const tokenFile = typeof pathValue === "string" ? pathValue.trim() : "";
|
|
722
722
|
if (!tokenFile) return null;
|
|
723
|
-
if (!
|
|
723
|
+
if (!syncFs.existsSync(tokenFile)) return {
|
|
724
724
|
token: "",
|
|
725
725
|
tokenSource: "tokenFile",
|
|
726
726
|
tokenStatus: "configured_unavailable"
|
|
727
727
|
};
|
|
728
728
|
try {
|
|
729
|
-
const token =
|
|
729
|
+
const token = syncFs.readFileSync(tokenFile, "utf-8").trim();
|
|
730
730
|
return {
|
|
731
731
|
token,
|
|
732
732
|
tokenSource: "tokenFile",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Dt as parseLooseIpAddress, Et as parseCanonicalIpAddress, St as isLegacyIpv4Literal, _t as extractEmbeddedIpv4FromIpv6, bt as isCanonicalDottedDecimalIPv4, vt as isBlockedSpecialUseIpv4Address, xt as isIpv4Address, yt as isBlockedSpecialUseIpv6Address } from "./model-selection-
|
|
1
|
+
import { Dt as parseLooseIpAddress, Et as parseCanonicalIpAddress, St as isLegacyIpv4Literal, _t as extractEmbeddedIpv4FromIpv6, bt as isCanonicalDottedDecimalIPv4, vt as isBlockedSpecialUseIpv4Address, xt as isIpv4Address, yt as isBlockedSpecialUseIpv6Address } from "./model-selection-DQ5NblsF.js";
|
|
2
2
|
import { lookup } from "node:dns";
|
|
3
3
|
import { lookup as lookup$1 } from "node:dns/promises";
|
|
4
4
|
import { Agent } from "undici";
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import "./run-with-concurrency-
|
|
2
|
-
import "./paths-
|
|
3
|
-
import { w as resolvePreferredOpenClawTmpDir } from "./subsystem-
|
|
4
|
-
import "./workspace-
|
|
5
|
-
import "./logger-
|
|
6
|
-
import { fr as formatCliCommand } from "./model-selection-
|
|
7
|
-
import "./github-copilot-token-
|
|
8
|
-
import "./legacy-names-
|
|
9
|
-
import { F as resolveStrictExistingPathsWithinRoot, L as DEFAULT_FILL_FIELD_TYPE, M as DEFAULT_TRACE_DIR, N as DEFAULT_UPLOAD_DIR, S as withCdpSocket, _ as withBrowserNavigationPolicy, d as formatAriaSnapshot, f as normalizeCdpWsUrl, g as assertBrowserNavigationResultAllowed, h as assertBrowserNavigationAllowed, k as withNoProxyForCdpUrl, t as getChromeWebSocketUrl, v as appendCdpPath, x as getHeadersWithAuth, y as fetchJson } from "./chrome-
|
|
10
|
-
import "./path-alias-guards-
|
|
11
|
-
import "./redact-
|
|
12
|
-
import { r as formatErrorMessage } from "./errors-
|
|
13
|
-
import { s as writeFileFromPathWithinRoot } from "./fs-safe-
|
|
14
|
-
import "./proxy-env-
|
|
1
|
+
import "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import "./paths-C6TxBCvO.js";
|
|
3
|
+
import { w as resolvePreferredOpenClawTmpDir } from "./subsystem-W834z9Wa.js";
|
|
4
|
+
import "./workspace-CPNwHoy5.js";
|
|
5
|
+
import "./logger-D4RcXHR-.js";
|
|
6
|
+
import { fr as formatCliCommand } from "./model-selection-DQ5NblsF.js";
|
|
7
|
+
import "./github-copilot-token-D13V9YBz.js";
|
|
8
|
+
import "./legacy-names-Bkl4tjN-.js";
|
|
9
|
+
import { F as resolveStrictExistingPathsWithinRoot, L as DEFAULT_FILL_FIELD_TYPE, M as DEFAULT_TRACE_DIR, N as DEFAULT_UPLOAD_DIR, S as withCdpSocket, _ as withBrowserNavigationPolicy, d as formatAriaSnapshot, f as normalizeCdpWsUrl, g as assertBrowserNavigationResultAllowed, h as assertBrowserNavigationAllowed, k as withNoProxyForCdpUrl, t as getChromeWebSocketUrl, v as appendCdpPath, x as getHeadersWithAuth, y as fetchJson } from "./chrome-hkgY24uS.js";
|
|
10
|
+
import "./path-alias-guards-DBVdJRcc.js";
|
|
11
|
+
import "./redact-DGz6yigq.js";
|
|
12
|
+
import { r as formatErrorMessage } from "./errors-DDrhcWHi.js";
|
|
13
|
+
import { s as writeFileFromPathWithinRoot } from "./fs-safe-CeZ_BXcn.js";
|
|
14
|
+
import "./proxy-env-zUD967XQ.js";
|
|
15
15
|
import fs from "node:fs/promises";
|
|
16
16
|
import path from "node:path";
|
|
17
17
|
import crypto from "node:crypto";
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { c as resolveAgentWorkspaceDir } from "./run-with-concurrency-
|
|
2
|
-
import { c as resolveStateDir } from "./paths-
|
|
3
|
-
import { t as createSubsystemLogger } from "./subsystem-
|
|
4
|
-
import { $ as parseAgentSessionKey } from "./workspace-
|
|
5
|
-
import "./logger-
|
|
6
|
-
import "./path-alias-guards-
|
|
7
|
-
import "./redact-
|
|
8
|
-
import { c as writeFileWithinRoot } from "./fs-safe-
|
|
1
|
+
import { c as resolveAgentWorkspaceDir } from "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import { c as resolveStateDir } from "./paths-C6TxBCvO.js";
|
|
3
|
+
import { t as createSubsystemLogger } from "./subsystem-W834z9Wa.js";
|
|
4
|
+
import { $ as parseAgentSessionKey } from "./workspace-CPNwHoy5.js";
|
|
5
|
+
import "./logger-D4RcXHR-.js";
|
|
6
|
+
import "./path-alias-guards-DBVdJRcc.js";
|
|
7
|
+
import "./redact-DGz6yigq.js";
|
|
8
|
+
import { c as writeFileWithinRoot } from "./fs-safe-CeZ_BXcn.js";
|
|
9
9
|
import { n as resolveWindowsSpawnProgram, t as materializeWindowsSpawnProgram } from "./windows-spawn-B89VigUN.js";
|
|
10
|
-
import "./paths-
|
|
11
|
-
import { a as listSessionFilesForAgent, i as buildSessionEntry, r as requireNodeSqlite, t as extractKeywords, v as isFileMissingError, y as statRegularFile } from "./query-expansion-
|
|
10
|
+
import "./paths-Cgd1FfOW.js";
|
|
11
|
+
import { a as listSessionFilesForAgent, i as buildSessionEntry, r as requireNodeSqlite, t as extractKeywords, v as isFileMissingError, y as statRegularFile } from "./query-expansion-Cbd21KuP.js";
|
|
12
12
|
import fs from "node:fs/promises";
|
|
13
13
|
import os from "node:os";
|
|
14
14
|
import path from "node:path";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { t as runTasksWithConcurrency } from "./run-with-concurrency-
|
|
2
|
-
import { t as createSubsystemLogger } from "./subsystem-
|
|
3
|
-
import { t as redactSensitiveText } from "./redact-
|
|
4
|
-
import { o as resolveSessionTranscriptsDirForAgent } from "./paths-
|
|
1
|
+
import { t as runTasksWithConcurrency } from "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import { t as createSubsystemLogger } from "./subsystem-W834z9Wa.js";
|
|
3
|
+
import { t as redactSensitiveText } from "./redact-DGz6yigq.js";
|
|
4
|
+
import { o as resolveSessionTranscriptsDirForAgent } from "./paths-Cgd1FfOW.js";
|
|
5
5
|
import { createRequire } from "node:module";
|
|
6
6
|
import fs from "node:fs/promises";
|
|
7
7
|
import path from "node:path";
|
|
8
|
-
import
|
|
8
|
+
import syncFs from "node:fs";
|
|
9
9
|
import crypto from "node:crypto";
|
|
10
10
|
|
|
11
11
|
//#region src/memory/fs-utils.ts
|
|
@@ -31,7 +31,7 @@ async function statRegularFile(absPath) {
|
|
|
31
31
|
//#region src/memory/internal.ts
|
|
32
32
|
function ensureDir(dir) {
|
|
33
33
|
try {
|
|
34
|
-
|
|
34
|
+
syncFs.mkdirSync(dir, { recursive: true });
|
|
35
35
|
} catch {}
|
|
36
36
|
return dir;
|
|
37
37
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { c as resolveStateDir } from "./paths-
|
|
2
|
-
import { t as createSubsystemLogger } from "./subsystem-
|
|
3
|
-
import { $ as parseAgentSessionKey, B as resolveAgentIdFromSessionKey, R as normalizeAgentId, j as DEFAULT_AGENT_ID, p as resolveDefaultAgentWorkspaceDir } from "./workspace-
|
|
4
|
-
import { y as resolveUserPath } from "./logger-
|
|
1
|
+
import { c as resolveStateDir } from "./paths-C6TxBCvO.js";
|
|
2
|
+
import { t as createSubsystemLogger } from "./subsystem-W834z9Wa.js";
|
|
3
|
+
import { $ as parseAgentSessionKey, B as resolveAgentIdFromSessionKey, R as normalizeAgentId, j as DEFAULT_AGENT_ID, p as resolveDefaultAgentWorkspaceDir } from "./workspace-CPNwHoy5.js";
|
|
4
|
+
import { y as resolveUserPath } from "./logger-D4RcXHR-.js";
|
|
5
5
|
import path from "node:path";
|
|
6
6
|
|
|
7
7
|
//#region src/config/model-input.ts
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import "./run-with-concurrency-kEFC1Fle.js";
|
|
2
|
+
import "./paths-C6TxBCvO.js";
|
|
3
|
+
import "./subsystem-W834z9Wa.js";
|
|
4
|
+
import "./workspace-CPNwHoy5.js";
|
|
5
|
+
import "./logger-D4RcXHR-.js";
|
|
6
|
+
import "./model-selection-DQ5NblsF.js";
|
|
7
|
+
import "./github-copilot-token-D13V9YBz.js";
|
|
8
|
+
import "./legacy-names-Bkl4tjN-.js";
|
|
9
|
+
import "./accounts-B-9Bhdn6.js";
|
|
10
|
+
import "./session-U4Hk8Woy.js";
|
|
11
|
+
import { t as loginWeb } from "./login-nNeuyFrd.js";
|
|
12
|
+
|
|
13
|
+
export { loginWeb };
|