@posthog/wizard 2.79.1 → 2.80.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/{PickerMenu-dG5DQCZA.js → PickerMenu-m4CCPX4f.js} +10 -10
- package/dist/PickerMenu-m4CCPX4f.js.map +1 -0
- package/dist/{agent-BWFhuLgo.js → agent-BkBbVuNq.js} +48 -37
- package/dist/agent-BkBbVuNq.js.map +1 -0
- package/dist/agent-QGK2YzlX.js +6 -0
- package/dist/{agent-interface-FkbaBJwz.js → agent-interface-CzyCmp7q.js} +68 -31
- package/dist/agent-interface-CzyCmp7q.js.map +1 -0
- package/dist/{agent-prompt-loader-D0weQ-7k.js → agent-prompt-loader-4wMxlYSX.js} +5 -5
- package/dist/{agent-prompt-loader-D0weQ-7k.js.map → agent-prompt-loader-4wMxlYSX.js.map} +1 -1
- package/dist/{analytics-DXK1gc12.js → analytics-B6q5PN7a.js} +5 -5
- package/dist/analytics-B6q5PN7a.js.map +1 -0
- package/dist/analytics-BXtfK9o7.js +2 -0
- package/dist/{api-CrbCIQOz.js → api-C3Dc4LFl.js} +3 -3
- package/dist/{api-CrbCIQOz.js.map → api-C3Dc4LFl.js.map} +1 -1
- package/dist/api-yNjrfZs2.js +2 -0
- package/dist/bin.js +1 -1
- package/dist/{bounded-fs-vAq-T-K7.js → bounded-fs-CC_NDtoP.js} +3 -3
- package/dist/{bounded-fs-vAq-T-K7.js.map → bounded-fs-CC_NDtoP.js.map} +1 -1
- package/dist/check-screens.tsx +5 -5
- package/dist/{ci-install-COcV8SY2.js → ci-install-DfcAMhlu.js} +7 -7
- package/dist/ci-install-DfcAMhlu.js.map +1 -0
- package/dist/{constants-DHCBSfnx.js → constants-DO4X70po.js} +3 -3
- package/dist/{constants-DHCBSfnx.js.map → constants-DO4X70po.js.map} +1 -1
- package/dist/{debug-BuYHGr6_.js → debug-BueK5mRR.js} +1 -1
- package/dist/{debug-kAHwWGg7.js → debug-DyARf5TF.js} +3 -3
- package/dist/debug-DyARf5TF.js.map +1 -0
- package/dist/{defaults-a9TelDhJ.js → defaults-DpfMnH2q.js} +2 -2
- package/dist/defaults-DpfMnH2q.js.map +1 -0
- package/dist/{endpoints-BVMYm9F4.js → endpoints-D-4KxZiB.js} +3 -3
- package/dist/{endpoints-BVMYm9F4.js.map → endpoints-D-4KxZiB.js.map} +1 -1
- package/dist/env-api-key-CHGLe0iz.js +2 -0
- package/dist/{env-api-key-BP-NFFXt.js → env-api-key-COf0U-Au.js} +2 -2
- package/dist/{env-api-key-BP-NFFXt.js.map → env-api-key-COf0U-Au.js.map} +1 -1
- package/dist/{environment-BATlQxcQ.js → environment-DrLaSsA8.js} +4 -4
- package/dist/{environment-BATlQxcQ.js.map → environment-DrLaSsA8.js.map} +1 -1
- package/dist/environment-hBj7ngmO.js +2 -0
- package/dist/{file-DcRKycV8.js → file-CVA9ocIC.js} +3 -3
- package/dist/file-CVA9ocIC.js.map +1 -0
- package/dist/file-CmoKK_Pp.js +2 -0
- package/dist/{file-watcher-Brq2nnHV.js → file-watcher-C3Su8vXm.js} +3 -3
- package/dist/file-watcher-C3Su8vXm.js.map +1 -0
- package/dist/{gateway-C9-GlLO9.js → gateway-BmjYUSua.js} +6 -6
- package/dist/{gateway-C9-GlLO9.js.map → gateway-BmjYUSua.js.map} +1 -1
- package/dist/{headless-ui-CqI2gXlD.js → headless-ui-CUbv12Yx.js} +3 -3
- package/dist/headless-ui-CUbv12Yx.js.map +1 -0
- package/dist/host-resolution-DVSb7kXb.js +114 -0
- package/dist/host-resolution-DVSb7kXb.js.map +1 -0
- package/dist/{add-mcp-server-to-clients-DIaTRWMY.js → install-Bk5TNk27.js} +15 -14
- package/dist/install-Bk5TNk27.js.map +1 -0
- package/dist/{add-mcp-server-to-clients-artmN7mz.js → install-F4wm3RSl.js} +1 -1
- package/dist/interactive-C5LNvDj6.js +11 -0
- package/dist/interactive-C5LNvDj6.js.map +1 -0
- package/dist/{telemetry-B7zJdRmA.js → links-9LWZPSCq.js} +4 -13
- package/dist/links-9LWZPSCq.js.map +1 -0
- package/dist/{logging-ui-Dza4D0MK.js → logging-ui-p6XKVmTx.js} +6 -6
- package/dist/logging-ui-p6XKVmTx.js.map +1 -0
- package/dist/{main-CgKxbwMP.js → main-DKPjFHEV.js} +149 -141
- package/dist/main-DKPjFHEV.js.map +1 -0
- package/dist/{mcp-DnAyW0-w.js → mcp-Co8VRF62.js} +4 -4
- package/dist/{mcp-DnAyW0-w.js.map → mcp-Co8VRF62.js.map} +1 -1
- package/dist/mcp-install-smoke-test.ts +1 -1
- package/dist/{mcp-prompt-streaming-DDWQ-FCA.js → mcp-prompt-streaming-ljCVoQ9I.js} +6 -6
- package/dist/{mcp-prompt-streaming-DDWQ-FCA.js.map → mcp-prompt-streaming-ljCVoQ9I.js.map} +1 -1
- package/dist/{mint-failure-u8xQKNOn.js → mint-failure-C0HyvEwO.js} +103 -92
- package/dist/mint-failure-C0HyvEwO.js.map +1 -0
- package/dist/{models-WcwUnSKb.js → models-Dba8ITeo.js} +2 -2
- package/dist/{models-WcwUnSKb.js.map → models-Dba8ITeo.js.map} +1 -1
- package/dist/{non-interactive-DyVC1AGc.js → non-interactive-CLMJrj_7.js} +3 -3
- package/dist/non-interactive-CLMJrj_7.js.map +1 -0
- package/dist/{oauth-session-DYM2Hrl2.js → oauth-session-D-RfcVmr.js} +2 -2
- package/dist/{oauth-session-DYM2Hrl2.js.map → oauth-session-D-RfcVmr.js.map} +1 -1
- package/dist/{orchestrator-tools-DbgNBFGA.js → orchestrator-tools-CVJ1F9Ub.js} +3 -3
- package/dist/{orchestrator-tools-DbgNBFGA.js.map → orchestrator-tools-CVJ1F9Ub.js.map} +1 -1
- package/dist/package-json--ppioh2F.js +2 -0
- package/dist/{package-json-Atg34fa4.js → package-json-Cowya9-3.js} +1 -1
- package/dist/{package-json-Atg34fa4.js.map → package-json-Cowya9-3.js.map} +1 -1
- package/dist/{pi-8KsYsPmM.js → pi-B5YTBRDv.js} +18 -17
- package/dist/pi-B5YTBRDv.js.map +1 -0
- package/dist/{playground-BlYRBMj7.js → playground-BLsCfHmQ.js} +33 -33
- package/dist/playground-BLsCfHmQ.js.map +1 -0
- package/dist/posthog-B2E0hpZt.js +2 -0
- package/dist/{posthog-Bt0Aplb8.js → posthog-B42rt_1S.js} +3 -3
- package/dist/posthog-B42rt_1S.js.map +1 -0
- package/dist/project-data--L-WZyvj.js +2 -0
- package/dist/{setup-utils-B26Lf2yF.js → project-data-BO9IXn9y.js} +566 -947
- package/dist/project-data-BO9IXn9y.js.map +1 -0
- package/dist/provisioning-C01REIU2.js +2 -0
- package/dist/{provisioning-Bo2NRxFz.js → provisioning-CLhuKqXH.js} +6 -67
- package/dist/provisioning-CLhuKqXH.js.map +1 -0
- package/dist/{queue-tools-C8mXOh7e.js → queue-tools-knnPQP0e.js} +4 -4
- package/dist/{queue-tools-C8mXOh7e.js.map → queue-tools-knnPQP0e.js.map} +1 -1
- package/dist/{registry-CD5RQt38.js → registry-B3rC5U4b.js} +6 -6
- package/dist/{registry-CD5RQt38.js.map → registry-B3rC5U4b.js.map} +1 -1
- package/dist/registry-BamsM7J9.js +2 -0
- package/dist/run-agent-legacy-CwUmPfQF.js +2 -0
- package/dist/{run-agent-legacy-DOlM6DQu.js → run-agent-legacy-DWBajsMh.js} +38 -111
- package/dist/run-agent-legacy-DWBajsMh.js.map +1 -0
- package/dist/{runners-ov3EXF1n.js → runners-D1PqqpjA.js} +38 -38
- package/dist/runners-D1PqqpjA.js.map +1 -0
- package/dist/{security-C71pkwqH.js → security-BvdSFDuM.js} +5 -5
- package/dist/{security-C71pkwqH.js.map → security-BvdSFDuM.js.map} +1 -1
- package/dist/setup-utils-ChXXTi1m.js +301 -0
- package/dist/setup-utils-ChXXTi1m.js.map +1 -0
- package/dist/{start-tui-Bo2L0bar.js → start-tui-DicLfgsj.js} +92 -90
- package/dist/start-tui-DicLfgsj.js.map +1 -0
- package/dist/{steps-BPcg3_3Q.js → steps-Hc28zVc_.js} +10 -10
- package/dist/steps-Hc28zVc_.js.map +1 -0
- package/dist/store-COCO6U0P.js +5 -0
- package/dist/{store-BTzcvRGT.js → store-D3509G87.js} +66 -28
- package/dist/store-D3509G87.js.map +1 -0
- package/dist/{subagent-D1TrTchE.js → subagent-D_Sqak94.js} +3 -3
- package/dist/{subagent-D1TrTchE.js.map → subagent-D_Sqak94.js.map} +1 -1
- package/dist/{task-DqRlQBfs.js → task-DiTI6Sak.js} +16 -16
- package/dist/task-DiTI6Sak.js.map +1 -0
- package/dist/{wizard-ui-DVqrYaOM.js → task-status-CmrrR7zo.js} +2 -2
- package/dist/task-status-CmrrR7zo.js.map +1 -0
- package/dist/{task-stream-Bw6JaLCX.js → task-stream-BckhG_cB.js} +10 -10
- package/dist/task-stream-BckhG_cB.js.map +1 -0
- package/dist/{tasks-ChWufsdO.js → tasks-ChZ_F1YP.js} +1 -1
- package/dist/{tasks-ChWufsdO.js.map → tasks-ChZ_F1YP.js.map} +1 -1
- package/dist/telemetry-BNKsDxNS.js +13 -0
- package/dist/telemetry-BNKsDxNS.js.map +1 -0
- package/dist/{terminal-zgkEfoCL.js → terminal-PK9bCLRi.js} +123 -97
- package/dist/terminal-PK9bCLRi.js.map +1 -0
- package/dist/{tools-CkJ2y9Wt.js → tools-C8LQ8QFz.js} +8 -8
- package/dist/{tools-CkJ2y9Wt.js.map → tools-C8LQ8QFz.js.map} +1 -1
- package/dist/{ui-Q6-RvERF.js → ui-tPNpM6vj.js} +3 -3
- package/dist/ui-tPNpM6vj.js.map +1 -0
- package/dist/urls-BI4kJ4qQ.js +67 -0
- package/dist/urls-BI4kJ4qQ.js.map +1 -0
- package/dist/{version-CHhJjz_H.js → version-5_ydHkM6.js} +2 -2
- package/dist/{version-CHhJjz_H.js.map → version-5_ydHkM6.js.map} +1 -1
- package/dist/{wizard-abort-Br1qMDNa.js → wizard-abort-BVjqLyeA.js} +1 -1
- package/dist/{wizard-abort-BPdv07np.js → wizard-abort-DBKtfnBR.js} +18 -16
- package/dist/wizard-abort-DBKtfnBR.js.map +1 -0
- package/dist/wizard-session-B7BHnay0.js +2 -0
- package/dist/{wizard-session-2w4Ru-Wz.js → wizard-session-BYw6LzpS.js} +30 -28
- package/dist/wizard-session-BYw6LzpS.js.map +1 -0
- package/dist/{yara-hooks-BnxejtXK.js → yara-hooks-C3L6lBij.js} +5 -5
- package/dist/{yara-hooks-BnxejtXK.js.map → yara-hooks-C3L6lBij.js.map} +1 -1
- package/dist/yara-hooks-CF_IsoaA.js +2 -0
- package/package.json +2 -3
- package/dist/PickerMenu-dG5DQCZA.js.map +0 -1
- package/dist/add-mcp-server-to-clients-DIaTRWMY.js.map +0 -1
- package/dist/agent-BEjARD2a.js +0 -6
- package/dist/agent-BWFhuLgo.js.map +0 -1
- package/dist/agent-interface-FkbaBJwz.js.map +0 -1
- package/dist/analytics-DFtbRjYh.js +0 -2
- package/dist/analytics-DXK1gc12.js.map +0 -1
- package/dist/api-Cm9UtKZh.js +0 -2
- package/dist/ci-install-COcV8SY2.js.map +0 -1
- package/dist/debug-kAHwWGg7.js.map +0 -1
- package/dist/defaults-a9TelDhJ.js.map +0 -1
- package/dist/env-api-key-CaWEDj_9.js +0 -2
- package/dist/environment-CwD8OPYj.js +0 -2
- package/dist/file-C5JMsyR1.js +0 -2
- package/dist/file-DcRKycV8.js.map +0 -1
- package/dist/file-watcher-Brq2nnHV.js.map +0 -1
- package/dist/headless-ui-CqI2gXlD.js.map +0 -1
- package/dist/interactive-B_Ti_CsS.js +0 -11
- package/dist/interactive-B_Ti_CsS.js.map +0 -1
- package/dist/logging-ui-Dza4D0MK.js.map +0 -1
- package/dist/main-CgKxbwMP.js.map +0 -1
- package/dist/mint-failure-u8xQKNOn.js.map +0 -1
- package/dist/non-interactive-DyVC1AGc.js.map +0 -1
- package/dist/package-json-D8Ga03tK.js +0 -2
- package/dist/pi-8KsYsPmM.js.map +0 -1
- package/dist/playground-BlYRBMj7.js.map +0 -1
- package/dist/posthog-Bt0Aplb8.js.map +0 -1
- package/dist/posthog-CUgCEhH0.js +0 -2
- package/dist/provisioning-Bo2NRxFz.js.map +0 -1
- package/dist/provisioning-OGFGlzf7.js +0 -2
- package/dist/registry-C06e_x-p.js +0 -2
- package/dist/run-agent-legacy-ChacZImU.js +0 -2
- package/dist/run-agent-legacy-DOlM6DQu.js.map +0 -1
- package/dist/runners-ov3EXF1n.js.map +0 -1
- package/dist/setup-utils-B26Lf2yF.js.map +0 -1
- package/dist/setup-utils-CVS86NYR.js +0 -2
- package/dist/start-tui-Bo2L0bar.js.map +0 -1
- package/dist/steps-BPcg3_3Q.js.map +0 -1
- package/dist/store-BTzcvRGT.js.map +0 -1
- package/dist/store-BpqySPXm.js +0 -5
- package/dist/task-DqRlQBfs.js.map +0 -1
- package/dist/task-stream-Bw6JaLCX.js.map +0 -1
- package/dist/telemetry-B7zJdRmA.js.map +0 -1
- package/dist/terminal-zgkEfoCL.js.map +0 -1
- package/dist/ui-Q6-RvERF.js.map +0 -1
- package/dist/wizard-abort-BPdv07np.js.map +0 -1
- package/dist/wizard-session-2w4Ru-Wz.js.map +0 -1
- package/dist/wizard-session-DGaUHOF3.js +0 -2
- package/dist/wizard-ui-DVqrYaOM.js.map +0 -1
- package/dist/yara-hooks-DSuExwb4.js +0 -2
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import "./agent-interface-CzyCmp7q.js";
|
|
2
|
+
import { d as configureGatewayFromCIEnvironment } from "./gateway-BmjYUSua.js";
|
|
3
|
+
import { t as runMcpPromptViaSdk } from "./agent-BkBbVuNq.js";
|
|
4
|
+
import "./yara-hooks-C3L6lBij.js";
|
|
5
|
+
import "./queue-tools-knnPQP0e.js";
|
|
6
|
+
export { configureGatewayFromCIEnvironment, runMcpPromptViaSdk };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { a as getLogFilePath, o as initLogFile, r as debug, s as logToFile, v as runtimeEnv } from "./debug-
|
|
2
|
-
import { Y as WIZARD_REMARK_EVENT_NAME, c as CONTEXT_MILL_URL, et as wizardUserAgentForProgram, o as AWS_SKILLS_BASE_URL } from "./constants-
|
|
3
|
-
import { n as analytics } from "./analytics-
|
|
1
|
+
import { a as getLogFilePath, o as initLogFile, r as debug, s as logToFile, v as runtimeEnv } from "./debug-DyARf5TF.js";
|
|
2
|
+
import { Y as WIZARD_REMARK_EVENT_NAME, c as CONTEXT_MILL_URL, et as wizardUserAgentForProgram, o as AWS_SKILLS_BASE_URL } from "./constants-DO4X70po.js";
|
|
3
|
+
import { n as analytics } from "./analytics-B6q5PN7a.js";
|
|
4
4
|
import { i as classifyAuthFailure } from "./errors-C2domSkK.js";
|
|
5
|
-
import { a as safeReadFile, i as readProjectFile, o as walkProjectFiles } from "./bounded-fs-
|
|
6
|
-
import { t as registerCleanup } from "./wizard-abort-
|
|
7
|
-
import { c as REMARK_INSTRUCTION, f as gatewayAuth, i as gatewayApiFor, l as RESUME_INSTRUCTION, n as buildGatewayModel, p as isPastRefresh, s as AgentSignals, u as buildWizardPropertiesBlob } from "./gateway-
|
|
8
|
-
import { i as modelCapabilities, o as triageModelFor } from "./models-
|
|
9
|
-
import { _ as coerceAuditChecks, h as AUDIT_CHECKS_FILE, l as prewarmYaraScanner, n as createPostToolUseYaraHooks, p as scanInstalledSkill, r as createPreToolUseYaraHooks } from "./yara-hooks-
|
|
10
|
-
import { l as buildOrchestratorTools, v as makeMutex, y as writeJsonAtomic } from "./queue-tools-
|
|
5
|
+
import { a as safeReadFile, i as readProjectFile, o as walkProjectFiles } from "./bounded-fs-CC_NDtoP.js";
|
|
6
|
+
import { t as registerCleanup } from "./wizard-abort-DBKtfnBR.js";
|
|
7
|
+
import { c as REMARK_INSTRUCTION, f as gatewayAuth, i as gatewayApiFor, l as RESUME_INSTRUCTION, n as buildGatewayModel, p as isPastRefresh, s as AgentSignals, u as buildWizardPropertiesBlob } from "./gateway-BmjYUSua.js";
|
|
8
|
+
import { i as modelCapabilities, o as triageModelFor } from "./models-Dba8ITeo.js";
|
|
9
|
+
import { _ as coerceAuditChecks, h as AUDIT_CHECKS_FILE, l as prewarmYaraScanner, n as createPostToolUseYaraHooks, p as scanInstalledSkill, r as createPreToolUseYaraHooks } from "./yara-hooks-C3L6lBij.js";
|
|
10
|
+
import { l as buildOrchestratorTools, v as makeMutex, y as writeJsonAtomic } from "./queue-tools-knnPQP0e.js";
|
|
11
11
|
import { createRequire } from "node:module";
|
|
12
12
|
import * as fs$1 from "fs";
|
|
13
13
|
import fs from "fs";
|
|
@@ -15,11 +15,11 @@ import path from "path";
|
|
|
15
15
|
import path$1 from "node:path";
|
|
16
16
|
import { spawnSync } from "node:child_process";
|
|
17
17
|
import { closeSync, constants, fchmodSync, lstatSync, openSync, renameSync, unlinkSync, writeSync } from "node:fs";
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import { randomUUID as randomUUID$1 } from "crypto";
|
|
18
|
+
import { randomUUID } from "crypto";
|
|
19
|
+
import { randomBytes, randomUUID as randomUUID$1 } from "node:crypto";
|
|
21
20
|
import * as os from "os";
|
|
22
21
|
import { unzipSync } from "fflate";
|
|
22
|
+
import { z } from "zod";
|
|
23
23
|
//#region \0rolldown/runtime.js
|
|
24
24
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
25
25
|
//#endregion
|
|
@@ -73,6 +73,34 @@ function createTriageLLMProvider(auth, harness) {
|
|
|
73
73
|
}
|
|
74
74
|
};
|
|
75
75
|
}
|
|
76
|
+
//#endregion
|
|
77
|
+
//#region src/shared/ask-policy.ts
|
|
78
|
+
/**
|
|
79
|
+
* Decide whether the `wizard_ask` overlay should be wired for this run.
|
|
80
|
+
* Disabled in non-interactive modes (CI, signup) — there's no human to
|
|
81
|
+
* answer. Per-program disabling is done by adding WIZARD_ASK_TOOL_NAME to
|
|
82
|
+
* the program's `disallowedTools` so the SDK rejects calls outright.
|
|
83
|
+
* Extracted so the policy can be unit-tested directly.
|
|
84
|
+
*
|
|
85
|
+
* `e2eAsk` is the one escape hatch. The e2e harness runs a `ci`
|
|
86
|
+
* session, but it does have an answerer — the driver loop answers each
|
|
87
|
+
* `wizard_ask` batch from the program's e2e profile. Without the flag the
|
|
88
|
+
* agent-in-the-loop layer (the ask bridge in both sequence arms, and the
|
|
89
|
+
* orchestrator's seeded warehouse task) stays unreachable from a test.
|
|
90
|
+
*
|
|
91
|
+
* Only the e2e TUI host sets the flag, from the `E2E_ASK` env var. No CLI flag
|
|
92
|
+
* populates it, so plain `--ci` and `--signup` runs behave exactly as before.
|
|
93
|
+
*/
|
|
94
|
+
function shouldDisableAsk(flags) {
|
|
95
|
+
return (flags.ci || flags.signup) && !flags.e2eAsk;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* The longer per-question timeout, for asks that send the user on an errand —
|
|
99
|
+
* open a database console, mint a restricted API key. The default above is
|
|
100
|
+
* sized for a question answerable from memory and expires long before an
|
|
101
|
+
* errand is done.
|
|
102
|
+
*/
|
|
103
|
+
const LONGER_ASK_TIMEOUT_MS = 1200 * 1e3;
|
|
76
104
|
/** A scan retains at most this many distinct key names. */
|
|
77
105
|
const MAX_ENV_KEY_SET = 5e3;
|
|
78
106
|
/** Files whose names start with `.env` carry env keys (`.env.local`, `.env.production`, …). */
|
|
@@ -729,13 +757,6 @@ function evaluateBashCommand(rawCommand) {
|
|
|
729
757
|
*/
|
|
730
758
|
/** Sentinel returned for unanswered fields on cancellation or timeout. */
|
|
731
759
|
const CANCELLED_SENTINEL = "__cancelled__";
|
|
732
|
-
/**
|
|
733
|
-
* The longer per-question timeout, for asks that send the user on an errand —
|
|
734
|
-
* open a database console, mint a restricted API key. The default above is
|
|
735
|
-
* sized for a question answerable from memory and expires long before an
|
|
736
|
-
* errand is done.
|
|
737
|
-
*/
|
|
738
|
-
const LONGER_ASK_TIMEOUT_MS = 1200 * 1e3;
|
|
739
760
|
function buildCancelledAnswers(questions) {
|
|
740
761
|
const out = {};
|
|
741
762
|
for (const q of questions) out[q.id] = CANCELLED_SENTINEL;
|
|
@@ -760,7 +781,7 @@ function createWizardAskBridge(opts) {
|
|
|
760
781
|
timedOut: false
|
|
761
782
|
};
|
|
762
783
|
const pending = {
|
|
763
|
-
id: randomUUID
|
|
784
|
+
id: randomUUID(),
|
|
764
785
|
questions,
|
|
765
786
|
source: opts.getSource(),
|
|
766
787
|
richLinks: opts.richLinks ?? false,
|
|
@@ -771,13 +792,21 @@ function createWizardAskBridge(opts) {
|
|
|
771
792
|
const controller = new AbortController();
|
|
772
793
|
let timer;
|
|
773
794
|
let timedOut = false;
|
|
795
|
+
let settled = false;
|
|
796
|
+
let answeredCount = 0;
|
|
774
797
|
let cancelForAbort;
|
|
798
|
+
let armTimeout = () => void 0;
|
|
775
799
|
const timeoutPromise = new Promise((resolve) => {
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
800
|
+
armTimeout = () => {
|
|
801
|
+
if (settled) return;
|
|
802
|
+
if (timer) clearTimeout(timer);
|
|
803
|
+
timer = setTimeout(() => {
|
|
804
|
+
timedOut = true;
|
|
805
|
+
resolve(buildCancelledAnswers(questions));
|
|
806
|
+
controller.abort();
|
|
807
|
+
}, timeoutMs);
|
|
808
|
+
};
|
|
809
|
+
armTimeout();
|
|
781
810
|
});
|
|
782
811
|
const aborted = new Promise((resolve) => {
|
|
783
812
|
cancelForAbort = () => {
|
|
@@ -788,7 +817,13 @@ function createWizardAskBridge(opts) {
|
|
|
788
817
|
});
|
|
789
818
|
try {
|
|
790
819
|
const answers = await Promise.race([
|
|
791
|
-
opts.showQuestion(pending, {
|
|
820
|
+
opts.showQuestion(pending, {
|
|
821
|
+
signal: controller.signal,
|
|
822
|
+
onAnswer: () => {
|
|
823
|
+
answeredCount += 1;
|
|
824
|
+
armTimeout();
|
|
825
|
+
}
|
|
826
|
+
}),
|
|
792
827
|
timeoutPromise,
|
|
793
828
|
aborted
|
|
794
829
|
]);
|
|
@@ -797,6 +832,7 @@ function createWizardAskBridge(opts) {
|
|
|
797
832
|
source: pending.source,
|
|
798
833
|
subject,
|
|
799
834
|
question_count: questions.length,
|
|
835
|
+
questions_answered: answeredCount,
|
|
800
836
|
duration_ms: durationMs,
|
|
801
837
|
timed_out: timedOut
|
|
802
838
|
});
|
|
@@ -811,6 +847,7 @@ function createWizardAskBridge(opts) {
|
|
|
811
847
|
timedOut
|
|
812
848
|
};
|
|
813
849
|
} finally {
|
|
850
|
+
settled = true;
|
|
814
851
|
if (timer) clearTimeout(timer);
|
|
815
852
|
if (cancelForAbort) opts.signal?.removeEventListener("abort", cancelForAbort);
|
|
816
853
|
pendingQuestions.delete(pending.id);
|
|
@@ -1767,7 +1804,7 @@ function createSecretVault() {
|
|
|
1767
1804
|
const store = /* @__PURE__ */ new Map();
|
|
1768
1805
|
return {
|
|
1769
1806
|
put(value, meta) {
|
|
1770
|
-
const ref = `${REF_PREFIX}${randomUUID
|
|
1807
|
+
const ref = `${REF_PREFIX}${randomUUID()}`;
|
|
1771
1808
|
store.set(ref, {
|
|
1772
1809
|
value,
|
|
1773
1810
|
meta: {
|
|
@@ -3819,11 +3856,11 @@ function handleTaskCreate(block, store) {
|
|
|
3819
3856
|
if (!input?.subject) return;
|
|
3820
3857
|
let source = taskSources.get(store.tasks);
|
|
3821
3858
|
if (!source) {
|
|
3822
|
-
source = randomUUID();
|
|
3859
|
+
source = randomUUID$1();
|
|
3823
3860
|
taskSources.set(store.tasks, source);
|
|
3824
3861
|
}
|
|
3825
3862
|
store.tasks.set(block.id, {
|
|
3826
|
-
id: randomUUID(),
|
|
3863
|
+
id: randomUUID$1(),
|
|
3827
3864
|
source,
|
|
3828
3865
|
content: input.subject,
|
|
3829
3866
|
status: "pending",
|
|
@@ -4087,6 +4124,6 @@ function handleSDKMessage(message, options, spinner, signals, emit, receivedSucc
|
|
|
4087
4124
|
}
|
|
4088
4125
|
}
|
|
4089
4126
|
//#endregion
|
|
4090
|
-
export { vaultSensitiveAnswers as $, CHECK_ENV_KEYS_FILE_PATH_DESCRIPTION as A, describeAskCancellation as B, AUDIT_ADD_CHECKS_PARAM_DESCRIPTION as C, AUDIT_SEED_CHECKS_PARAM_DESCRIPTION as D, AUDIT_SEED_CHECKS_DESCRIPTION as E, WIZARD_ASK_TOOL_DESCRIPTION as F, mergeEnvValues as G, ensureGitignoreCoverage as H, WIZARD_TOOL_NAMES as I, resolveAuditChecks as J, normaliseAskSubject as K, addAuditChecks as L, WIZARD_ASK_KIND_DESCRIPTION as M, WIZARD_ASK_SENSITIVE_DESCRIPTION as N, AUDIT_STATUSES as O, WIZARD_ASK_SUBJECT_DESCRIPTION as P, templateEnvWriteRefusal as Q, checkEnvKeys as R, AUDIT_ADD_CHECKS_DESCRIPTION as S, AUDIT_RESOLVE_CHECKS_PARAM_DESCRIPTION as T, installSkillById as U, downloadSkill as V, legacyKeyNameRefusal as W, resolveEnvSecretRefs as X, resolveEnvPath as Y, seedAuditChecks as Z, createSecretVault as _, wizardCanUseTool as a,
|
|
4127
|
+
export { vaultSensitiveAnswers as $, CHECK_ENV_KEYS_FILE_PATH_DESCRIPTION as A, describeAskCancellation as B, AUDIT_ADD_CHECKS_PARAM_DESCRIPTION as C, AUDIT_SEED_CHECKS_PARAM_DESCRIPTION as D, AUDIT_SEED_CHECKS_DESCRIPTION as E, WIZARD_ASK_TOOL_DESCRIPTION as F, mergeEnvValues as G, ensureGitignoreCoverage as H, WIZARD_TOOL_NAMES as I, resolveAuditChecks as J, normaliseAskSubject as K, addAuditChecks as L, WIZARD_ASK_KIND_DESCRIPTION as M, WIZARD_ASK_SENSITIVE_DESCRIPTION as N, AUDIT_STATUSES as O, WIZARD_ASK_SUBJECT_DESCRIPTION as P, templateEnvWriteRefusal as Q, checkEnvKeys as R, AUDIT_ADD_CHECKS_DESCRIPTION as S, AUDIT_RESOLVE_CHECKS_PARAM_DESCRIPTION as T, installSkillById as U, downloadSkill as V, legacyKeyNameRefusal as W, resolveEnvSecretRefs as X, resolveEnvPath as Y, seedAuditChecks as Z, createSecretVault as _, wizardCanUseTool as a, isEnvFileName as at, PUBLISH_HANDOFF_TOOL_NAME as b, checkAllSettingsConflicts as c, LONGER_ASK_TIMEOUT_MS as ct, restoreClaudeSettings as d, fetchSkillMenu as et, sanitizeAgentSubprocessEnv as f, assembleCommandments as g, markGrantRevoked as h, runAgent as i, MAX_ENV_KEY_SET as it, ENV_FILE_PATH_DESCRIPTION as j, CHECK_ENV_KEYS_DESCRIPTION as k, classifySettingsConflicts as l, shouldDisableAsk as lt, isGrantRevoked as m, buildRunTags as n, createWizardAskBridge as nt, createIsolatedAgentConfigDir as o, parseEnvKeyNames as ot, AgentOutputSignals as p, resolveAskQuestionKinds as q, initializeAgent as r, isFullyCancelled as rt, backupAndFixClaudeSettings as s, toPromptSafeRelativePath as st, buildAgentEnv as t, fetchWithRetry as tt, recoverOrphanedSettingsBackups as u, createTriageLLMProvider as ut, PUBLISH_HANDOFF_CONTENT_DESCRIPTION as v, AUDIT_RESOLVE_CHECKS_DESCRIPTION as w, publishHandoff as x, PUBLISH_HANDOFF_DESCRIPTION as y, createAskAccounting as z };
|
|
4091
4128
|
|
|
4092
|
-
//# sourceMappingURL=agent-interface-
|
|
4129
|
+
//# sourceMappingURL=agent-interface-CzyCmp7q.js.map
|