very-happy-cli 0.2.180 → 0.2.181
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/{AcpBackend-DfRDtMcG.cjs → AcpBackend-CgHb_ya5.cjs} +3 -3
- package/dist/{AcpBackend-B8Zi30Zh.mjs → AcpBackend-DZGCSuXF.mjs} +3 -3
- package/dist/{AcpSessionManager-CASKOnOj.cjs → AcpSessionManager-CacC2EVn.cjs} +1 -1
- package/dist/{AcpSessionManager-i8Rab0xT.mjs → AcpSessionManager-DwuPzWBh.mjs} +1 -1
- package/dist/{BasePermissionHandler-BlM_tfej.cjs → BasePermissionHandler-DCP8ZEB4.cjs} +1 -1
- package/dist/{BasePermissionHandler-26fKbRCm.mjs → BasePermissionHandler-Uo-GUjbb.mjs} +1 -1
- package/dist/{acpSessionResume-B9l54P-X.mjs → acpSessionResume-9OLTD6kT.mjs} +1 -1
- package/dist/{acpSessionResume-CR5pmgVo.cjs → acpSessionResume-BaVMD80f.cjs} +1 -1
- package/dist/{agentHome-CmGy0NWv.mjs → agentHome-B1BsKeqD.mjs} +4 -4
- package/dist/{agentHome-C7Sb7-Tz.cjs → agentHome-BtUmGcPX.cjs} +4 -4
- package/dist/{api-DM7b1OKj.cjs → api-COHFAkb_.cjs} +10 -10
- package/dist/{api-Hov8p7CA.mjs → api-Dr3wXL_7.mjs} +10 -10
- package/dist/{apiMachine-CwGEhQDT.mjs → apiMachine-CHEzPQdS.mjs} +54 -32
- package/dist/{apiMachine-DkGRj-Ai.cjs → apiMachine-D8H7CXaz.cjs} +55 -33
- package/dist/{attachmentContent-CIn4iPEk.mjs → attachmentContent-1YwtKgWl.mjs} +2 -2
- package/dist/{attachmentContent-CEm13_gF.cjs → attachmentContent-mIhbtRKl.cjs} +2 -2
- package/dist/{auth-rggxMpEE.mjs → auth-CbZkcMAb.mjs} +8 -8
- package/dist/{auth-CBXnm-Mj.cjs → auth-CgQP7d0q.cjs} +5 -5
- package/dist/{auth-BG1DY0gj.mjs → auth-DZsthtSk.mjs} +5 -5
- package/dist/{auth-Dawj7pP5.cjs → auth-Fg8fLadK.cjs} +8 -8
- package/dist/{auto-CbYOfoPS.cjs → auto-BB7kqSh5.cjs} +18 -18
- package/dist/{auto-CXXLXGeL.mjs → auto-_T-Ud-z5.mjs} +18 -18
- package/dist/{bootstrap-Dt5I1SOl.mjs → bootstrap-B6EkZh4u.mjs} +2 -2
- package/dist/{bootstrap-DoA7okld.cjs → bootstrap-CYtOtbi7.cjs} +2 -2
- package/dist/{browser-DUNetFT4.mjs → browser-C2qhUHSE.mjs} +1 -1
- package/dist/{browser-DZ6qRtfH.cjs → browser-DjNNQQk2.cjs} +1 -1
- package/dist/{claudeLocal-OHWQigCl.mjs → claudeLocal-BAFjWhZ8.mjs} +6 -6
- package/dist/{claudeLocal--DNyMOSv.cjs → claudeLocal-O_w7-fBh.cjs} +6 -6
- package/dist/{claudeLocalLauncher-BStvfa7M.mjs → claudeLocalLauncher-CWn30LZR.mjs} +11 -11
- package/dist/{claudeLocalLauncher-BhvPbcyH.cjs → claudeLocalLauncher-Df3zg1q0.cjs} +11 -11
- package/dist/{claudeSessionFork-GAVWhiKG.mjs → claudeSessionFork-2ZkSTOGn.mjs} +1 -1
- package/dist/{claudeSessionFork-Be16vzGc.cjs → claudeSessionFork-pwcKqB-e.cjs} +1 -1
- package/dist/{client-Ca5Pcgy_.mjs → client-BKyU66lg.mjs} +2 -2
- package/dist/{client-D_loZ9IK.cjs → client-CUO3ItoB.cjs} +34 -8
- package/dist/{client-CnB7kRCT.mjs → client-CXOnzuOy.mjs} +2 -2
- package/dist/{client-DJplzPjD.cjs → client-DWs6k041.cjs} +2 -2
- package/dist/{client-BWjaHKtj.cjs → client-D_U2VjO3.cjs} +2 -2
- package/dist/{client-D4uPb1uu.mjs → client-DsQcxVUV.mjs} +34 -9
- package/dist/codex/happyMcpStdioBridge.cjs +17 -17
- package/dist/codex/happyMcpStdioBridge.mjs +17 -17
- package/dist/{codexAppServerClient-PE-12AsW.cjs → codexAppServerClient-BRX3JZ_5.cjs} +3 -3
- package/dist/{codexAppServerClient-CO4G6OS4.mjs → codexAppServerClient-C3JO3pwM.mjs} +3 -3
- package/dist/{codexCommand-B_xUH79E.mjs → codexCommand-BZIAAqKS.mjs} +47 -45
- package/dist/{codexCommand-BNoD1t1C.cjs → codexCommand-dKOc5iQl.cjs} +47 -45
- package/dist/{codexTermination-BmBbizFK.cjs → codexTermination-BVR9HeVI.cjs} +1 -1
- package/dist/{codexTermination-Dx48ma6e.mjs → codexTermination-ztFkwHrG.mjs} +1 -1
- package/dist/{config-DSu0Blos.mjs → config-NbHjx8ge.mjs} +3 -3
- package/dist/{config-CtwEUxUP.cjs → config-cftYxLC7.cjs} +3 -3
- package/dist/{configuration-PxzEJumr.mjs → configuration-BPrfb17M.mjs} +1 -1
- package/dist/{configuration-CYO-kPOS.cjs → configuration-C8JgseHy.cjs} +1 -1
- package/dist/{connect-Dq7wndzR.cjs → connect-Br8VMrK1.cjs} +13 -13
- package/dist/{connect-BQrg3TB6.mjs → connect-CLD1ai0k.mjs} +13 -13
- package/dist/{context-6TP-iz_c.cjs → context-D1lgQTJC.cjs} +1 -1
- package/dist/{context-CJGRRGWW.mjs → context-_YGq8xdH.mjs} +1 -1
- package/dist/{controlClient-DoeYovwP.mjs → controlClient-CkNpT5zS.mjs} +3 -3
- package/dist/{controlClient-Bqv5v5OM.cjs → controlClient-D68Zj7Q-.cjs} +3 -3
- package/dist/{createSessionMetadata-DDIChCx8.mjs → createSessionMetadata-3WAj3_xl.mjs} +2 -2
- package/dist/{createSessionMetadata-xz767pcG.cjs → createSessionMetadata-DNIbKLHg.cjs} +2 -2
- package/dist/{defaultPermissionMode-PkZGsQDk.cjs → defaultPermissionMode-BmvjP32v.cjs} +2 -2
- package/dist/{defaultPermissionMode-i5KzdK09.mjs → defaultPermissionMode-DXMznl8v.mjs} +2 -2
- package/dist/{deterministicJson-xqA6DaOm.cjs → deterministicJson-BS7D7URE.cjs} +87 -22
- package/dist/{deterministicJson-CTEJDqtS.mjs → deterministicJson-BcBIKKf1.mjs} +87 -24
- package/dist/{doctor-BrgSlfXn.cjs → doctor-Be7zC0AF.cjs} +8 -7
- package/dist/{doctor-IctjVh9T.mjs → doctor-CoOaPq6w.mjs} +8 -8
- package/dist/{downloadTarget-jbOz1egC.mjs → downloadTarget-CeaAXdJj.mjs} +6 -6
- package/dist/{downloadTarget-CEb9che-.cjs → downloadTarget-LyOiucn_.cjs} +6 -6
- package/dist/{ensureDaemonRunning-b1e8LCSM.mjs → ensureDaemonRunning--98j7-17.mjs} +5 -5
- package/dist/{ensureDaemonRunning-D-HyjGIX.cjs → ensureDaemonRunning-B8z37VKD.cjs} +5 -5
- package/dist/fileStore-5qpetZS0.mjs +146 -0
- package/dist/fileStore-7qhnbs6N.cjs +152 -0
- package/dist/{handleResumeCommand-BvWVuRwH.cjs → handleResumeCommand-BFZlrFVH.cjs} +5 -5
- package/dist/{handleResumeCommand-DpaZvm2c.mjs → handleResumeCommand-gO8I4keP.mjs} +5 -5
- package/dist/{index-B2p2Mut7.cjs → index-B5PXbZjW.cjs} +77 -60
- package/dist/{index-F2UejqYs.cjs → index-BRMq9gOe.cjs} +3 -3
- package/dist/{index-C64Ufj4D.cjs → index-BkluinoS.cjs} +4 -4
- package/dist/{index-Bsvbgh9e.mjs → index-CO0n9ue6.mjs} +4 -4
- package/dist/{index-C6Vn5Eac.mjs → index-CeRXrGnH.mjs} +39 -6
- package/dist/{index-Dv0Q48P3.cjs → index-Df2eHm3O.cjs} +40 -6
- package/dist/{index-BUNnpGFF.mjs → index-DneHoQXf.mjs} +78 -61
- package/dist/{index-CMf5VbzG.mjs → index-WUj3954m.mjs} +4 -4
- package/dist/{index-wCbtF4BK.mjs → index-hQ8LP1C2.mjs} +3 -3
- package/dist/{index-DmTlDRSL.cjs → index-jF2t3ACW.cjs} +4 -4
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +2 -2
- package/dist/{install-BX3lv3NO.mjs → install-D0inLCv-.mjs} +1 -1
- package/dist/{install-BXvf2E3o.cjs → install-D2NCbeJ-.cjs} +1 -1
- package/dist/{install-CdzSV7qO.mjs → install-DkYFiVK4.mjs} +3 -3
- package/dist/{install-C0ANcEAW.cjs → install-FqkSUjPC.cjs} +3 -3
- package/dist/lib.cjs +12 -12
- package/dist/lib.d.cts +39 -1
- package/dist/lib.d.mts +39 -1
- package/dist/lib.mjs +12 -12
- package/dist/{lidState-bBrmaQd2.mjs → lidState-DghbfRbr.mjs} +1 -1
- package/dist/{lidState-DWGnm2H4.cjs → lidState-x8cJ8J_9.cjs} +1 -1
- package/dist/{localHappyAgentAuth-DZHQnIW9.cjs → localHappyAgentAuth-DZ2kb9uq.cjs} +1 -1
- package/dist/{localHappyAgentAuth-Dn1jYDpt.mjs → localHappyAgentAuth-IKmeRpuQ.mjs} +1 -1
- package/dist/{logger-CphW5nUE.cjs → logger-DgBwUSgS.cjs} +2 -2
- package/dist/{logger-BUngm5Xg.mjs → logger-LFr8iPgl.mjs} +2 -2
- package/dist/{machineMetadata-BXN_bKU3.mjs → machineMetadata-BglCsfvf.mjs} +11 -4
- package/dist/{machineMetadata-BQm9YTcI.cjs → machineMetadata-DB03ez4K.cjs} +11 -3
- package/dist/{main-B2UV51nK.cjs → main-YQ-Vkakw.cjs} +45 -45
- package/dist/{main-DGkdYfEq.mjs → main-_1LSzlLv.mjs} +45 -45
- package/dist/{mcp-BFvAEIRz.cjs → mcp-BIY80jSc.cjs} +14 -14
- package/dist/{mcp-CbTtbs0f.mjs → mcp-Csj-mT5Y.mjs} +14 -14
- package/dist/{mirrorProtocol-HKPivs5o.cjs → mirrorProtocol-BphKIAK9.cjs} +16 -153
- package/dist/{mirrorProtocol-BR4luBC0.mjs → mirrorProtocol-CAxOMBkb.mjs} +19 -151
- package/dist/{package-7Ld1YMhh.mjs → package-DYGwlmXl.mjs} +8 -8
- package/dist/{package-KhLqBDX9.cjs → package-NoD8QOOM.cjs} +8 -8
- package/dist/{panels-C7IVqpJk.mjs → panels-B8zRm7_d.mjs} +5 -5
- package/dist/{panels-Njf6GelF.cjs → panels-DYEc1NyQ.cjs} +5 -5
- package/dist/{peerTools-BOlDRyhi.mjs → peerTools-CK3JYu1k.mjs} +5 -5
- package/dist/{peerTools-DQNlrcqM.cjs → peerTools-CP-x-Peu.cjs} +5 -5
- package/dist/{persistence-9BMYspxG.cjs → persistence-BY-D00wT.cjs} +2 -2
- package/dist/{persistence-BFUOHW5h.mjs → persistence-D2Djrf7t.mjs} +2 -2
- package/dist/pi-CqyoZMjI.mjs +380 -0
- package/dist/pi-DlsrPCTa.cjs +400 -0
- package/dist/{piRunnerArgs-H2pgpA5z.mjs → piRunnerArgs-IZLoL7TG.mjs} +1 -1
- package/dist/{piRunnerArgs-DGaq6VYM.cjs → piRunnerArgs-gxLYIZH4.cjs} +1 -1
- package/dist/{piRuntime-CdN0JAsa.mjs → piRuntime-D7Y4oHVL.mjs} +2 -2
- package/dist/{piRuntime-CT5xv_3h.cjs → piRuntime-o5L8uX-W.cjs} +2 -2
- package/dist/{piTerminal-0FBtXTHK.cjs → piTerminal-C_-JDkLN.cjs} +17 -17
- package/dist/{piTerminal-C4m9YXAV.mjs → piTerminal-Kphx8Uhw.mjs} +17 -17
- package/dist/{prompt-lgF9IE82.cjs → prompt-Bof2aQkI.cjs} +7 -2
- package/dist/{prompt-BOouDaTM.mjs → prompt-QHuFx9j6.mjs} +7 -2
- package/dist/{pushNotifications-DI92havG.cjs → pushNotifications-BXoOSq_G.cjs} +10 -4
- package/dist/{pushNotifications-DCiBEVeC.mjs → pushNotifications-DXGIhE-A.mjs} +10 -4
- package/dist/{query-ywZbQUzR.mjs → query-CcA6DVZK.mjs} +1 -1
- package/dist/{query-BETKBrnz.cjs → query-CdCxzuaB.cjs} +1 -1
- package/dist/{rateLimitWindows-YRIYVdo4.cjs → rateLimitWindows-OpAmdOtC.cjs} +1 -1
- package/dist/{rateLimitWindows-BkfuUB1a.mjs → rateLimitWindows-ZtHZHe-l.mjs} +1 -1
- package/dist/{registerCommonHandlers-C7a_dUWs.cjs → registerCommonHandlers-CRjBoJLK.cjs} +2 -2
- package/dist/{registerCommonHandlers-CTkCvjxt.mjs → registerCommonHandlers-DF6bdDtd.mjs} +2 -2
- package/dist/{registerKillSessionHandler-CIsvBrVe.cjs → registerKillSessionHandler-7fOm6ooh.cjs} +6 -6
- package/dist/{registerKillSessionHandler-CaqqRYq6.mjs → registerKillSessionHandler-DDCKL3wf.mjs} +6 -6
- package/dist/{remoteSessionClient-PP-mOKmw.mjs → remoteSessionClient-B2POSKFT.mjs} +5 -5
- package/dist/{remoteSessionClient-D843fkzL.cjs → remoteSessionClient-CFCn42bs.cjs} +5 -5
- package/dist/{reportProgressTool-ZOCNjWHr.mjs → reportProgressTool-tPxEvh6x.mjs} +4 -4
- package/dist/{reportProgressTool-14AXr959.cjs → reportProgressTool-th4trcET.cjs} +4 -4
- package/dist/{resources-CvIlkzpP.cjs → resources-BPyN59Iv.cjs} +23 -2
- package/dist/{resources-y9jfyO-_.mjs → resources-CH1iP6Cv.mjs} +22 -3
- package/dist/{run-CAOCYYfT.cjs → run-C_FumCQk.cjs} +618 -594
- package/dist/{run-Dajw2E5j.mjs → run-cKQBbVi4.mjs} +554 -530
- package/dist/{runClaude-C6oxWYbp.mjs → runClaude-CYnM6krL.mjs} +22 -22
- package/dist/{runClaude-CRRKt-tm.cjs → runClaude-z_2YC_aa.cjs} +22 -22
- package/dist/{runClaudeDeps-B1ysqTvx.cjs → runClaudeDeps-CLubzWnA.cjs} +43 -41
- package/dist/{runClaudeDeps-BcZ68cX3.mjs → runClaudeDeps-duS06Pb4.mjs} +48 -46
- package/dist/{runGemini-D7yKc4wD.mjs → runGemini-C_Pc2EhH.mjs} +37 -35
- package/dist/{runGemini-DtKFXqf-.cjs → runGemini-vEoXV6qT.cjs} +37 -35
- package/dist/{runOpenClaw-Cq29mryb.cjs → runOpenClaw-CXJCtMgB.cjs} +18 -18
- package/dist/{runOpenClaw-C8ilyLP9.mjs → runOpenClaw-Cxun1qLC.mjs} +18 -18
- package/dist/{sandbox-gIj-EuF4.cjs → sandbox-CO46H2tK.cjs} +4 -4
- package/dist/{sandbox-CbCutma4.mjs → sandbox-CsvPnTmz.mjs} +4 -4
- package/dist/{selfCheck-BTGBVthv.cjs → selfCheck-DIr7Gc0i.cjs} +36 -36
- package/dist/selfCheck-NamtBHVB.mjs +85 -0
- package/dist/{send-YZRMQvMJ.mjs → send-DMoFg6F1.mjs} +8 -8
- package/dist/{send-CZf5lLw_.cjs → send-X2mfVEyr.cjs} +8 -8
- package/dist/{server-CknFq6xG.cjs → server-BwTEdbkr.cjs} +6 -6
- package/dist/{server-BqwXRzFZ.mjs → server-CkqQ0sRH.mjs} +4 -4
- package/dist/{sessionLock-DRZUcKHT.cjs → sessionLock-CdIRJlHH.cjs} +3 -3
- package/dist/{sessionLock-nBXdJxJm.mjs → sessionLock-JIfwCqMk.mjs} +3 -3
- package/dist/{sessionOps-BrGiU9-s.cjs → sessionOps-DVA-00nR.cjs} +4 -4
- package/dist/{sessionOps-C58iDeD5.mjs → sessionOps-DqlftXxe.mjs} +4 -4
- package/dist/{sessionScanner-Bm57LEXe.mjs → sessionScanner-BI0Vo1xT.mjs} +3 -3
- package/dist/{sessionScanner-CaO8bLaG.cjs → sessionScanner-BMwgGAhY.cjs} +3 -3
- package/dist/{sessions-BXyBHo8n.mjs → sessions-D6IimX7b.mjs} +10 -10
- package/dist/{sessions-uzqPCc37.cjs → sessions-DjgEcHaT.cjs} +10 -10
- package/dist/{setupOfflineReconnection-DvvVX3TB.cjs → setupOfflineReconnection-CjuCiKY3.cjs} +2 -2
- package/dist/{setupOfflineReconnection-1Qlek3wl.mjs → setupOfflineReconnection-DgJK_4m1.mjs} +2 -2
- package/dist/{spawn-vn93PhYL.mjs → spawn-Dvzy-tzc.mjs} +14 -14
- package/dist/{spawn-DBkodJEO.cjs → spawn-rhF28shY.cjs} +14 -14
- package/dist/{spawnAgents-CgPMWexP.mjs → spawnAgents-CCnlq-FI.mjs} +1 -1
- package/dist/{spawnAgents-DLNMlhWJ.cjs → spawnAgents-iwuqrgR9.cjs} +1 -1
- package/dist/{spawnHappyCLI-DnUZv0X2.cjs → spawnHappyCLI-DnKmIsEt.cjs} +1 -1
- package/dist/{spawnHappyCLI-BjFZc_7V.mjs → spawnHappyCLI-Dq3LLXLb.mjs} +1 -1
- package/dist/{specialCommands-D3ND9bdg.mjs → specialCommands-CcyZ1hGA.mjs} +3 -3
- package/dist/{specialCommands-BRufxlqe.cjs → specialCommands-Zwr2C6A2.cjs} +3 -3
- package/dist/{startFileWatcher-DXJ7yB5v.mjs → startFileWatcher-4thXDK9d.mjs} +1 -1
- package/dist/{startFileWatcher-D9cYzZOq.cjs → startFileWatcher-K6hJSyiR.cjs} +1 -1
- package/dist/{startupSessionCreate-uZ6BM0ty.mjs → startupSessionCreate-BfByJ16A.mjs} +1 -1
- package/dist/{startupSessionCreate-kdr3m1uX.cjs → startupSessionCreate-CKEbq0tL.cjs} +1 -1
- package/dist/{streamRelay-Dy6amlzx.cjs → streamRelay-Gy8Xfnon.cjs} +1 -1
- package/dist/{streamRelay-DnMCMMfV.mjs → streamRelay-LcDvyEjK.mjs} +1 -1
- package/dist/{sync-Bn-idAoy.cjs → sync-1hQ5KHpL.cjs} +1 -1
- package/dist/{sync-BvVhDO40.mjs → sync-DO-2PU45.mjs} +1 -1
- package/dist/{systemPrompt-CIZcJuJF.mjs → systemPrompt-BctLfMZs.mjs} +3 -3
- package/dist/{systemPrompt-DlyEk35T.cjs → systemPrompt-Dj7pgkMK.cjs} +3 -3
- package/dist/{teams-DLY3B5yi.mjs → teams-Bu8YeOoF.mjs} +8 -8
- package/dist/{teams-BLeRpDxv.cjs → teams-uQxUlyyz.cjs} +8 -8
- package/dist/{time-D3ETL7Jb.mjs → time-BcoJaG8E.mjs} +1 -1
- package/dist/{time-Cjv0zxQO.cjs → time-nqa9shu8.cjs} +1 -1
- package/dist/{titleGenerator-Cgp5ihFb.cjs → titleGenerator-D09XyYYG.cjs} +2 -2
- package/dist/{titleGenerator-Uzbd4utr.mjs → titleGenerator-D5r06bhf.mjs} +1 -1
- package/dist/{todo-pOMcEECE.cjs → todo-CCOnL7pT.cjs} +6 -6
- package/dist/{todo-C9Ga-oEM.mjs → todo-D1q8146q.mjs} +6 -6
- package/dist/{tools-Cho7iIWf.mjs → tools-D2E--n1x.mjs} +3 -3
- package/dist/{tools-BL7Byl_x.cjs → tools-DiCXnAC5.cjs} +3 -3
- package/dist/{uninstall-CbayEVoV.cjs → uninstall-BrNwwwSD.cjs} +3 -3
- package/dist/{uninstall-CvZHVY9C.mjs → uninstall-CtwXi1Rt.mjs} +3 -3
- package/package.json +8 -8
- package/dist/selfCheck-Smt-5Xiq.mjs +0 -85
|
@@ -4,45 +4,45 @@ var chalk = require('chalk');
|
|
|
4
4
|
var os = require('node:os');
|
|
5
5
|
var node_fs = require('node:fs');
|
|
6
6
|
var path = require('node:path');
|
|
7
|
-
var index = require('./index-
|
|
8
|
-
var configuration = require('./configuration-
|
|
9
|
-
var client = require('./client-
|
|
7
|
+
var index = require('./index-Df2eHm3O.cjs');
|
|
8
|
+
var configuration = require('./configuration-C8JgseHy.cjs');
|
|
9
|
+
var client = require('./client-D_U2VjO3.cjs');
|
|
10
10
|
var template = require('./template-BaHAmH2K.cjs');
|
|
11
|
-
var install = require('./install-
|
|
11
|
+
var install = require('./install-D2NCbeJ-.cjs');
|
|
12
12
|
var precheckCompat = require('./precheckCompat-CWOi5c9L.cjs');
|
|
13
|
-
var sessionOps = require('./sessionOps-
|
|
14
|
-
var spawn = require('./spawn-
|
|
15
|
-
var spawnAgents = require('./spawnAgents-
|
|
16
|
-
var time = require('./time-
|
|
13
|
+
var sessionOps = require('./sessionOps-DVA-00nR.cjs');
|
|
14
|
+
var spawn = require('./spawn-rhF28shY.cjs');
|
|
15
|
+
var spawnAgents = require('./spawnAgents-iwuqrgR9.cjs');
|
|
16
|
+
var time = require('./time-nqa9shu8.cjs');
|
|
17
17
|
require('zod');
|
|
18
18
|
require('@paralleldrive/cuid2');
|
|
19
|
-
require('./package-
|
|
19
|
+
require('./package-NoD8QOOM.cjs');
|
|
20
20
|
require('node:fs/promises');
|
|
21
|
-
require('./persistence-
|
|
21
|
+
require('./persistence-BY-D00wT.cjs');
|
|
22
22
|
require('./authRelay-Dy1qU9td.cjs');
|
|
23
23
|
require('node:crypto');
|
|
24
24
|
require('tweetnacl');
|
|
25
|
-
require('./logger-
|
|
25
|
+
require('./logger-DgBwUSgS.cjs');
|
|
26
26
|
require('node:util');
|
|
27
|
-
require('./resources-
|
|
27
|
+
require('./resources-BPyN59Iv.cjs');
|
|
28
28
|
require('axios');
|
|
29
|
-
require('./controlClient-
|
|
29
|
+
require('./controlClient-D68Zj7Q-.cjs');
|
|
30
30
|
require('socket.io-client');
|
|
31
31
|
require('./backgroundTaskActivity-CBvUdj39.cjs');
|
|
32
|
-
require('./client-
|
|
32
|
+
require('./client-DWs6k041.cjs');
|
|
33
33
|
require('./path-B7zW-WwE.cjs');
|
|
34
|
-
require('./claudeSessionFork-
|
|
34
|
+
require('./claudeSessionFork-pwcKqB-e.cjs');
|
|
35
35
|
require('node:readline');
|
|
36
|
-
require('./codexAppServerClient-
|
|
36
|
+
require('./codexAppServerClient-BRX3JZ_5.cjs');
|
|
37
37
|
require('node:child_process');
|
|
38
38
|
require('cross-spawn');
|
|
39
39
|
require('./contentLogMetadata-ZSFk_NjQ.cjs');
|
|
40
40
|
require('./manager-HrEj442o.cjs');
|
|
41
41
|
require('@anthropic-ai/sandbox-runtime');
|
|
42
|
-
require('./rateLimitWindows-
|
|
42
|
+
require('./rateLimitWindows-OpAmdOtC.cjs');
|
|
43
43
|
require('./processTree-CMHWlVse.cjs');
|
|
44
44
|
require('./codexThreadFork-DNekT4nQ.cjs');
|
|
45
|
-
require('./createSessionMetadata-
|
|
45
|
+
require('./createSessionMetadata-DNIbKLHg.cjs');
|
|
46
46
|
require('./projectPath-C3ioB4Bu.cjs');
|
|
47
47
|
require('path');
|
|
48
48
|
require('url');
|
|
@@ -2,45 +2,45 @@ import chalk from 'chalk';
|
|
|
2
2
|
import { homedir } from 'node:os';
|
|
3
3
|
import { readFileSync } from 'node:fs';
|
|
4
4
|
import { resolve } from 'node:path';
|
|
5
|
-
import { A as AUTOMATION_NAME_PATTERN, i as isAutomationRunTerminal, b as AUTOMATION_PRECHECK_MAX_TIMEOUT_MS, c as AutomationPrecheckSchema } from './index-
|
|
6
|
-
import { c as configuration } from './configuration-
|
|
7
|
-
import { a as authenticatedAutomationsClient, b as automationRunIdFromEnv, i as isAutomationsUnavailable, A as AUTOMATIONS_UNAVAILABLE_MESSAGE } from './client-
|
|
5
|
+
import { A as AUTOMATION_NAME_PATTERN, i as isAutomationRunTerminal, b as AUTOMATION_PRECHECK_MAX_TIMEOUT_MS, c as AutomationPrecheckSchema } from './index-CeRXrGnH.mjs';
|
|
6
|
+
import { c as configuration } from './configuration-BPrfb17M.mjs';
|
|
7
|
+
import { a as authenticatedAutomationsClient, b as automationRunIdFromEnv, i as isAutomationsUnavailable, A as AUTOMATIONS_UNAVAILABLE_MESSAGE } from './client-CXOnzuOy.mjs';
|
|
8
8
|
import { p as parseDuration, t as triggerFromFlags, d as describeTrigger, a as describeAction } from './template-CiOPa2rd.mjs';
|
|
9
|
-
import { A as AUTOMATION_SKILL, i as installAutomationSkill } from './install-
|
|
9
|
+
import { A as AUTOMATION_SKILL, i as installAutomationSkill } from './install-D0inLCv-.mjs';
|
|
10
10
|
import { u as updateAutomationChecked, c as createAutomationChecked } from './precheckCompat-DeEbilbr.mjs';
|
|
11
|
-
import { s as sessionWebUrl } from './sessionOps-
|
|
12
|
-
import { parseEnvAssignment } from './spawn-
|
|
13
|
-
import { S as SPAWN_AGENTS, s as sanitizeSpawnPermissionMode, A as ALLOWED_SPAWN_PERMISSION_MODES } from './spawnAgents-
|
|
14
|
-
import { d as delay } from './time-
|
|
11
|
+
import { s as sessionWebUrl } from './sessionOps-DqlftXxe.mjs';
|
|
12
|
+
import { parseEnvAssignment } from './spawn-Dvzy-tzc.mjs';
|
|
13
|
+
import { S as SPAWN_AGENTS, s as sanitizeSpawnPermissionMode, A as ALLOWED_SPAWN_PERMISSION_MODES } from './spawnAgents-CCnlq-FI.mjs';
|
|
14
|
+
import { d as delay } from './time-BcoJaG8E.mjs';
|
|
15
15
|
import 'zod';
|
|
16
16
|
import '@paralleldrive/cuid2';
|
|
17
|
-
import './package-
|
|
17
|
+
import './package-DYGwlmXl.mjs';
|
|
18
18
|
import 'node:fs/promises';
|
|
19
|
-
import './persistence-
|
|
19
|
+
import './persistence-D2Djrf7t.mjs';
|
|
20
20
|
import './authRelay-DhQhkBvX.mjs';
|
|
21
21
|
import 'node:crypto';
|
|
22
22
|
import 'tweetnacl';
|
|
23
|
-
import './logger-
|
|
23
|
+
import './logger-LFr8iPgl.mjs';
|
|
24
24
|
import 'node:util';
|
|
25
|
-
import './resources-
|
|
25
|
+
import './resources-CH1iP6Cv.mjs';
|
|
26
26
|
import 'axios';
|
|
27
|
-
import './controlClient-
|
|
27
|
+
import './controlClient-CkNpT5zS.mjs';
|
|
28
28
|
import 'socket.io-client';
|
|
29
29
|
import './backgroundTaskActivity-8PdPxrvy.mjs';
|
|
30
|
-
import './client-
|
|
30
|
+
import './client-BKyU66lg.mjs';
|
|
31
31
|
import './path-D2wdaNSk.mjs';
|
|
32
|
-
import './claudeSessionFork-
|
|
32
|
+
import './claudeSessionFork-2ZkSTOGn.mjs';
|
|
33
33
|
import 'node:readline';
|
|
34
|
-
import './codexAppServerClient-
|
|
34
|
+
import './codexAppServerClient-C3JO3pwM.mjs';
|
|
35
35
|
import 'node:child_process';
|
|
36
36
|
import 'cross-spawn';
|
|
37
37
|
import './contentLogMetadata-BlWI0egu.mjs';
|
|
38
38
|
import './manager-BEsI4qt3.mjs';
|
|
39
39
|
import '@anthropic-ai/sandbox-runtime';
|
|
40
|
-
import './rateLimitWindows-
|
|
40
|
+
import './rateLimitWindows-ZtHZHe-l.mjs';
|
|
41
41
|
import './processTree-CP5IvQ2Z.mjs';
|
|
42
42
|
import './codexThreadFork-R76RU5H0.mjs';
|
|
43
|
-
import './createSessionMetadata-
|
|
43
|
+
import './createSessionMetadata-3WAj3_xl.mjs';
|
|
44
44
|
import './projectPath-BTBIMB57.mjs';
|
|
45
45
|
import 'path';
|
|
46
46
|
import 'url';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { existsSync } from 'node:fs';
|
|
2
2
|
import { mkdir, writeFile } from 'node:fs/promises';
|
|
3
3
|
import { join } from 'node:path';
|
|
4
|
-
import { c as configuration } from './configuration-
|
|
4
|
+
import { c as configuration } from './configuration-BPrfb17M.mjs';
|
|
5
5
|
import 'node:os';
|
|
6
|
-
import './package-
|
|
6
|
+
import './package-DYGwlmXl.mjs';
|
|
7
7
|
|
|
8
8
|
const ASSISTANT_CLAUDE_MD = `# very-happy \u8C03\u5EA6\u4E2D\u5FC3\uFF08\u8BED\u97F3\u52A9\u624B\uFF09
|
|
9
9
|
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
var node_fs = require('node:fs');
|
|
4
4
|
var promises = require('node:fs/promises');
|
|
5
5
|
var path = require('node:path');
|
|
6
|
-
var configuration = require('./configuration-
|
|
6
|
+
var configuration = require('./configuration-C8JgseHy.cjs');
|
|
7
7
|
require('node:os');
|
|
8
|
-
require('./package-
|
|
8
|
+
require('./package-NoD8QOOM.cjs');
|
|
9
9
|
|
|
10
10
|
const ASSISTANT_CLAUDE_MD = `# very-happy \u8C03\u5EA6\u4E2D\u5FC3\uFF08\u8BED\u97F3\u52A9\u624B\uFF09
|
|
11
11
|
|
|
@@ -2,26 +2,26 @@ import { spawn } from 'cross-spawn';
|
|
|
2
2
|
import { createInterface } from 'node:readline';
|
|
3
3
|
import { readdirSync, statSync, mkdirSync, existsSync } from 'node:fs';
|
|
4
4
|
import { randomUUID } from 'node:crypto';
|
|
5
|
-
import { l as logger } from './logger-
|
|
5
|
+
import { l as logger } from './logger-LFr8iPgl.mjs';
|
|
6
6
|
import { p as pinSmallFastModel, e as ensureLocalProxyBypass } from './smallFastModel-BLNgMrwR.mjs';
|
|
7
7
|
import { join } from 'node:path';
|
|
8
8
|
import { g as getProjectPath } from './path-D2wdaNSk.mjs';
|
|
9
|
-
import { c as claudeCheckSession, s as systemPrompt } from './systemPrompt-
|
|
9
|
+
import { c as claudeCheckSession, s as systemPrompt } from './systemPrompt-BctLfMZs.mjs';
|
|
10
10
|
import { i as initializeSandbox, a as wrapCommand } from './manager-BEsI4qt3.mjs';
|
|
11
11
|
import { c as contentLogMetadata } from './contentLogMetadata-BlWI0egu.mjs';
|
|
12
12
|
import { claudeCliPath } from './claudeCliPath-BqkaH2oR.mjs';
|
|
13
13
|
import 'chalk';
|
|
14
14
|
import 'node:util';
|
|
15
|
-
import './configuration-
|
|
15
|
+
import './configuration-BPrfb17M.mjs';
|
|
16
16
|
import 'node:os';
|
|
17
|
-
import './package-
|
|
17
|
+
import './package-DYGwlmXl.mjs';
|
|
18
18
|
import 'node:fs/promises';
|
|
19
|
-
import './index-
|
|
19
|
+
import './index-CeRXrGnH.mjs';
|
|
20
20
|
import 'zod';
|
|
21
21
|
import '@paralleldrive/cuid2';
|
|
22
22
|
import './trimIdent-BAjmv_TG.mjs';
|
|
23
23
|
import './agentGuidance-BDYt2Qy2.mjs';
|
|
24
|
-
import './prompt-
|
|
24
|
+
import './prompt-QHuFx9j6.mjs';
|
|
25
25
|
import '@anthropic-ai/sandbox-runtime';
|
|
26
26
|
import './projectPath-BTBIMB57.mjs';
|
|
27
27
|
import 'path';
|
|
@@ -4,26 +4,26 @@ var spawn = require('cross-spawn');
|
|
|
4
4
|
var node_readline = require('node:readline');
|
|
5
5
|
var node_fs = require('node:fs');
|
|
6
6
|
var node_crypto = require('node:crypto');
|
|
7
|
-
var logger = require('./logger-
|
|
7
|
+
var logger = require('./logger-DgBwUSgS.cjs');
|
|
8
8
|
var smallFastModel = require('./smallFastModel-D_uxGMo3.cjs');
|
|
9
9
|
var path$1 = require('node:path');
|
|
10
10
|
var path = require('./path-B7zW-WwE.cjs');
|
|
11
|
-
var systemPrompt = require('./systemPrompt-
|
|
11
|
+
var systemPrompt = require('./systemPrompt-Dj7pgkMK.cjs');
|
|
12
12
|
var manager = require('./manager-HrEj442o.cjs');
|
|
13
13
|
var contentLogMetadata = require('./contentLogMetadata-ZSFk_NjQ.cjs');
|
|
14
14
|
var claudeCliPath = require('./claudeCliPath-GaP3UUz1.cjs');
|
|
15
15
|
require('chalk');
|
|
16
16
|
require('node:util');
|
|
17
|
-
require('./configuration-
|
|
17
|
+
require('./configuration-C8JgseHy.cjs');
|
|
18
18
|
require('node:os');
|
|
19
|
-
require('./package-
|
|
19
|
+
require('./package-NoD8QOOM.cjs');
|
|
20
20
|
require('node:fs/promises');
|
|
21
|
-
require('./index-
|
|
21
|
+
require('./index-Df2eHm3O.cjs');
|
|
22
22
|
require('zod');
|
|
23
23
|
require('@paralleldrive/cuid2');
|
|
24
24
|
require('./trimIdent-4gvk9Wk6.cjs');
|
|
25
25
|
require('./agentGuidance-BtBx2xxE.cjs');
|
|
26
|
-
require('./prompt-
|
|
26
|
+
require('./prompt-Bof2aQkI.cjs');
|
|
27
27
|
require('@anthropic-ai/sandbox-runtime');
|
|
28
28
|
require('./projectPath-C3ioB4Bu.cjs');
|
|
29
29
|
require('path');
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { l as logger } from './logger-
|
|
2
|
-
import { claudeLocal, ExitCodeError } from './claudeLocal-
|
|
3
|
-
import { c as createSessionScanner, F as Future, d as describeClaudeProcessExit } from './sessionScanner-
|
|
1
|
+
import { l as logger } from './logger-LFr8iPgl.mjs';
|
|
2
|
+
import { claudeLocal, ExitCodeError } from './claudeLocal-BAFjWhZ8.mjs';
|
|
3
|
+
import { c as createSessionScanner, F as Future, d as describeClaudeProcessExit } from './sessionScanner-BI0Vo1xT.mjs';
|
|
4
4
|
import 'chalk';
|
|
5
5
|
import 'node:util';
|
|
6
|
-
import './configuration-
|
|
6
|
+
import './configuration-BPrfb17M.mjs';
|
|
7
7
|
import 'node:fs';
|
|
8
8
|
import 'node:os';
|
|
9
9
|
import 'node:path';
|
|
10
|
-
import './package-
|
|
10
|
+
import './package-DYGwlmXl.mjs';
|
|
11
11
|
import 'node:fs/promises';
|
|
12
12
|
import 'cross-spawn';
|
|
13
13
|
import 'node:readline';
|
|
14
14
|
import 'node:crypto';
|
|
15
15
|
import './smallFastModel-BLNgMrwR.mjs';
|
|
16
16
|
import './path-D2wdaNSk.mjs';
|
|
17
|
-
import './systemPrompt-
|
|
18
|
-
import './index-
|
|
17
|
+
import './systemPrompt-BctLfMZs.mjs';
|
|
18
|
+
import './index-CeRXrGnH.mjs';
|
|
19
19
|
import 'zod';
|
|
20
20
|
import '@paralleldrive/cuid2';
|
|
21
21
|
import './trimIdent-BAjmv_TG.mjs';
|
|
22
22
|
import './agentGuidance-BDYt2Qy2.mjs';
|
|
23
|
-
import './prompt-
|
|
23
|
+
import './prompt-QHuFx9j6.mjs';
|
|
24
24
|
import './manager-BEsI4qt3.mjs';
|
|
25
25
|
import '@anthropic-ai/sandbox-runtime';
|
|
26
26
|
import './contentLogMetadata-BlWI0egu.mjs';
|
|
@@ -28,11 +28,11 @@ import './claudeCliPath-BqkaH2oR.mjs';
|
|
|
28
28
|
import './projectPath-BTBIMB57.mjs';
|
|
29
29
|
import 'path';
|
|
30
30
|
import 'url';
|
|
31
|
-
import './sync-
|
|
32
|
-
import './time-
|
|
31
|
+
import './sync-DO-2PU45.mjs';
|
|
32
|
+
import './time-BcoJaG8E.mjs';
|
|
33
33
|
import './types-CkqAACXx.mjs';
|
|
34
34
|
import './transcriptCursor-B7T_gkQ0.mjs';
|
|
35
|
-
import './startFileWatcher-
|
|
35
|
+
import './startFileWatcher-4thXDK9d.mjs';
|
|
36
36
|
import 'fs/promises';
|
|
37
37
|
|
|
38
38
|
async function claudeLocalLauncher(session) {
|
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var logger = require('./logger-
|
|
4
|
-
var claudeLocal = require('./claudeLocal
|
|
5
|
-
var sessionScanner = require('./sessionScanner-
|
|
3
|
+
var logger = require('./logger-DgBwUSgS.cjs');
|
|
4
|
+
var claudeLocal = require('./claudeLocal-O_w7-fBh.cjs');
|
|
5
|
+
var sessionScanner = require('./sessionScanner-BMwgGAhY.cjs');
|
|
6
6
|
require('chalk');
|
|
7
7
|
require('node:util');
|
|
8
|
-
require('./configuration-
|
|
8
|
+
require('./configuration-C8JgseHy.cjs');
|
|
9
9
|
require('node:fs');
|
|
10
10
|
require('node:os');
|
|
11
11
|
require('node:path');
|
|
12
|
-
require('./package-
|
|
12
|
+
require('./package-NoD8QOOM.cjs');
|
|
13
13
|
require('node:fs/promises');
|
|
14
14
|
require('cross-spawn');
|
|
15
15
|
require('node:readline');
|
|
16
16
|
require('node:crypto');
|
|
17
17
|
require('./smallFastModel-D_uxGMo3.cjs');
|
|
18
18
|
require('./path-B7zW-WwE.cjs');
|
|
19
|
-
require('./systemPrompt-
|
|
20
|
-
require('./index-
|
|
19
|
+
require('./systemPrompt-Dj7pgkMK.cjs');
|
|
20
|
+
require('./index-Df2eHm3O.cjs');
|
|
21
21
|
require('zod');
|
|
22
22
|
require('@paralleldrive/cuid2');
|
|
23
23
|
require('./trimIdent-4gvk9Wk6.cjs');
|
|
24
24
|
require('./agentGuidance-BtBx2xxE.cjs');
|
|
25
|
-
require('./prompt-
|
|
25
|
+
require('./prompt-Bof2aQkI.cjs');
|
|
26
26
|
require('./manager-HrEj442o.cjs');
|
|
27
27
|
require('@anthropic-ai/sandbox-runtime');
|
|
28
28
|
require('./contentLogMetadata-ZSFk_NjQ.cjs');
|
|
@@ -30,11 +30,11 @@ require('./claudeCliPath-GaP3UUz1.cjs');
|
|
|
30
30
|
require('./projectPath-C3ioB4Bu.cjs');
|
|
31
31
|
require('path');
|
|
32
32
|
require('url');
|
|
33
|
-
require('./sync-
|
|
34
|
-
require('./time-
|
|
33
|
+
require('./sync-1hQ5KHpL.cjs');
|
|
34
|
+
require('./time-nqa9shu8.cjs');
|
|
35
35
|
require('./types-CRS-srZK.cjs');
|
|
36
36
|
require('./transcriptCursor-DcXGLeSc.cjs');
|
|
37
|
-
require('./startFileWatcher-
|
|
37
|
+
require('./startFileWatcher-K6hJSyiR.cjs');
|
|
38
38
|
require('fs/promises');
|
|
39
39
|
|
|
40
40
|
async function claudeLocalLauncher(session) {
|
|
@@ -3,7 +3,7 @@ import { copyFile, unlink, readFile, rename, writeFile } from 'node:fs/promises'
|
|
|
3
3
|
import { createReadStream, createWriteStream } from 'node:fs';
|
|
4
4
|
import { join } from 'node:path';
|
|
5
5
|
import { createInterface } from 'node:readline';
|
|
6
|
-
import { l as logger } from './logger-
|
|
6
|
+
import { l as logger } from './logger-LFr8iPgl.mjs';
|
|
7
7
|
|
|
8
8
|
class ForkTruncateUuidNotFoundError extends Error {
|
|
9
9
|
constructor(cutAfterUuid, sourcePath) {
|
|
@@ -5,7 +5,7 @@ var promises = require('node:fs/promises');
|
|
|
5
5
|
var node_fs = require('node:fs');
|
|
6
6
|
var path = require('node:path');
|
|
7
7
|
var node_readline = require('node:readline');
|
|
8
|
-
var logger = require('./logger-
|
|
8
|
+
var logger = require('./logger-DgBwUSgS.cjs');
|
|
9
9
|
|
|
10
10
|
class ForkTruncateUuidNotFoundError extends Error {
|
|
11
11
|
constructor(cutAfterUuid, sourcePath) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as configuration } from './configuration-
|
|
2
|
-
import { b as readCredentialsForConfiguredRelay } from './persistence-
|
|
1
|
+
import { c as configuration } from './configuration-BPrfb17M.mjs';
|
|
2
|
+
import { b as readCredentialsForConfiguredRelay } from './persistence-D2Djrf7t.mjs';
|
|
3
3
|
|
|
4
4
|
const UNSUPPORTED_BACKOFF_MS = 10 * 6e4;
|
|
5
5
|
class ProjectsUnsupportedError extends Error {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var node_crypto = require('node:crypto');
|
|
4
|
-
var configuration = require('./configuration-
|
|
5
|
-
var persistence = require('./persistence-
|
|
6
|
-
var context = require('./context-
|
|
4
|
+
var configuration = require('./configuration-C8JgseHy.cjs');
|
|
5
|
+
var persistence = require('./persistence-BY-D00wT.cjs');
|
|
6
|
+
var context = require('./context-D1lgQTJC.cjs');
|
|
7
7
|
|
|
8
8
|
async function teamRequest(path, method, token, scoped, body) {
|
|
9
9
|
const response = await fetch(`${configuration.configuration.serverUrl}${path}`, {
|
|
@@ -15,7 +15,11 @@ async function teamRequest(path, method, token, scoped, body) {
|
|
|
15
15
|
}).catch(() => {
|
|
16
16
|
throw new Error("Teams connection failed; outcome may be unknown. Reuse the request ID when retrying.");
|
|
17
17
|
});
|
|
18
|
-
if (!response.ok)
|
|
18
|
+
if (!response.ok) {
|
|
19
|
+
const body2 = response.status === 409 ? await response.json().catch(() => null) : null;
|
|
20
|
+
if (body2?.error === "session_in_other_team") throw new SessionInOtherTeamError(typeof body2.teamId === "string" ? body2.teamId : "", typeof body2.teamName === "string" ? body2.teamName : "");
|
|
21
|
+
throw new Error(`Teams request failed (HTTP ${response.status})`);
|
|
22
|
+
}
|
|
19
23
|
try {
|
|
20
24
|
return await response.json();
|
|
21
25
|
} catch {
|
|
@@ -24,6 +28,21 @@ async function teamRequest(path, method, token, scoped, body) {
|
|
|
24
28
|
}
|
|
25
29
|
class TeamConnectionPreflightError extends Error {
|
|
26
30
|
}
|
|
31
|
+
class SessionInOtherTeamError extends TeamConnectionPreflightError {
|
|
32
|
+
code = "session_in_other_team";
|
|
33
|
+
teamId;
|
|
34
|
+
teamName;
|
|
35
|
+
constructor(teamId, teamName) {
|
|
36
|
+
const safe = (value) => value.replace(/[\u0000-\u001f\u007f]/g, " ").slice(0, 128);
|
|
37
|
+
super(sessionInOtherTeamMessage(safe(teamName) || "another team", safe(teamId)));
|
|
38
|
+
this.teamId = safe(teamId);
|
|
39
|
+
this.teamName = safe(teamName);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
function sessionInOtherTeamMessage(teamName, teamId) {
|
|
43
|
+
return `This session is already the lead or a member of team "${teamName}"${teamId ? ` (${teamId})` : ""}. Call team_inspect and use team_delegate to assign work inside that team; do not create or join another team. \u4F60\u5DF2\u7ECF\u662F\u56E2\u961F\u300C${teamName}\u300D\u7684\u6210\u5458\u6216\u8D1F\u8D23\u4EBA\uFF0C\u8BF7\u5148 team_inspect\uFF0C\u518D\u7528 team_delegate \u5728\u672C\u56E2\u961F\u5185\u6D3E\u6D3B\uFF0C\u4E0D\u8981\u65B0\u5EFA\u6216\u52A0\u5165\u5176\u4ED6\u56E2\u961F\u3002`;
|
|
44
|
+
}
|
|
45
|
+
const NO_TEAM_SCOPE_MESSAGE = "This session has no team scope. Do not create a team to get one: if you lead or work in a team (for example after a restart), call team_inspect again or tell the user; use team_create or team_join only when the user asks for a new team.";
|
|
27
46
|
const initializationLocks = /* @__PURE__ */ new Map();
|
|
28
47
|
async function serializeInitialization(path, work) {
|
|
29
48
|
const previous = initializationLocks.get(path) ?? Promise.resolve();
|
|
@@ -36,6 +55,12 @@ async function serializeInitialization(path, work) {
|
|
|
36
55
|
if (initializationLocks.get(path) === next) initializationLocks.delete(path);
|
|
37
56
|
}
|
|
38
57
|
}
|
|
58
|
+
function teamCreateBody(input, machineId, sessionId, directory) {
|
|
59
|
+
const body = { name: input.name, machineId, requestId: input.requestId, sessionId, ...input.transfer ? { transfer: true } : {} };
|
|
60
|
+
if (input.noProject) return body;
|
|
61
|
+
if (input.projectId) return { ...body, project: { projectId: input.projectId } };
|
|
62
|
+
return { ...body, project: { inheritFromSessionId: sessionId, ...directory ? { directory } : {} } };
|
|
63
|
+
}
|
|
39
64
|
function createTeamsClient(sessionId) {
|
|
40
65
|
const scopePath = () => context.teamScopePath(sessionId ?? process.env.HAPPY_SESSION_ID);
|
|
41
66
|
return {
|
|
@@ -57,7 +82,7 @@ function createTeamsClient(sessionId) {
|
|
|
57
82
|
if (priorScope && !options?.expectedTeamId) throw new Error("This session already belongs to another team scope");
|
|
58
83
|
let teamId = input.teamId ?? options?.expectedTeamId;
|
|
59
84
|
if (!teamId) {
|
|
60
|
-
const created = await teamRequest("/v1/teams", "POST", credentials.token, false,
|
|
85
|
+
const created = await teamRequest("/v1/teams", "POST", credentials.token, false, teamCreateBody(input, machineId, sid, persisted.metadata.path));
|
|
61
86
|
teamId = created.team.id;
|
|
62
87
|
} else {
|
|
63
88
|
const existing = await teamRequest(`/v1/teams/${encodeURIComponent(teamId)}`, "GET", credentials.token, false);
|
|
@@ -76,7 +101,7 @@ function createTeamsClient(sessionId) {
|
|
|
76
101
|
"POST",
|
|
77
102
|
credentials.token,
|
|
78
103
|
false,
|
|
79
|
-
{ requestId: input.requestId, action: { type: "join", name: input.name, sessionId: sid, ...input.botId ? { botId: input.botId } : {} } }
|
|
104
|
+
{ requestId: input.requestId, action: { type: "join", name: input.name, sessionId: sid, ...input.botId ? { botId: input.botId } : {}, ...input.transfer ? { transfer: true } : {} } }
|
|
80
105
|
);
|
|
81
106
|
if (!result.credential?.token || !result.credential?.botId) throw new Error("Team join did not issue a credential");
|
|
82
107
|
await context.writeTeamScope(path, { serverUrl: configuration.configuration.serverUrl, teamId, botId: result.credential.botId, scopeToken: result.credential.token });
|
|
@@ -85,13 +110,13 @@ function createTeamsClient(sessionId) {
|
|
|
85
110
|
},
|
|
86
111
|
async inspect() {
|
|
87
112
|
const scope = await context.readTeamScope(scopePath());
|
|
88
|
-
if (!scope) throw new Error(
|
|
113
|
+
if (!scope) throw new Error(NO_TEAM_SCOPE_MESSAGE);
|
|
89
114
|
const { credential: _credential, ...safe } = await teamRequest(`/v1/teams/${encodeURIComponent(scope.teamId)}/agent`, "GET", scope.scopeToken, true);
|
|
90
115
|
return safe;
|
|
91
116
|
},
|
|
92
117
|
async action(action, requestId = node_crypto.randomUUID()) {
|
|
93
118
|
const scope = await context.readTeamScope(scopePath());
|
|
94
|
-
if (!scope) throw new Error(
|
|
119
|
+
if (!scope) throw new Error(NO_TEAM_SCOPE_MESSAGE);
|
|
95
120
|
const result = await teamRequest(`/v1/teams/${encodeURIComponent(scope.teamId)}/agent`, "POST", scope.scopeToken, true, { requestId, action });
|
|
96
121
|
const { credential: _credential, ...safe } = result;
|
|
97
122
|
return safe;
|
|
@@ -99,6 +124,7 @@ function createTeamsClient(sessionId) {
|
|
|
99
124
|
};
|
|
100
125
|
}
|
|
101
126
|
|
|
127
|
+
exports.SessionInOtherTeamError = SessionInOtherTeamError;
|
|
102
128
|
exports.TeamConnectionPreflightError = TeamConnectionPreflightError;
|
|
103
129
|
exports.createTeamsClient = createTeamsClient;
|
|
104
130
|
exports.teamRequest = teamRequest;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as configuration } from './configuration-
|
|
2
|
-
import { b as readCredentialsForConfiguredRelay, r as readSettings } from './persistence-
|
|
1
|
+
import { c as configuration } from './configuration-BPrfb17M.mjs';
|
|
2
|
+
import { b as readCredentialsForConfiguredRelay, r as readSettings } from './persistence-D2Djrf7t.mjs';
|
|
3
3
|
|
|
4
4
|
class AutomationsRequestError extends Error {
|
|
5
5
|
constructor(status, code, runStatus) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var configuration = require('./configuration-
|
|
4
|
-
var persistence = require('./persistence-
|
|
3
|
+
var configuration = require('./configuration-C8JgseHy.cjs');
|
|
4
|
+
var persistence = require('./persistence-BY-D00wT.cjs');
|
|
5
5
|
|
|
6
6
|
const UNSUPPORTED_BACKOFF_MS = 10 * 6e4;
|
|
7
7
|
class ProjectsUnsupportedError extends Error {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var configuration = require('./configuration-
|
|
4
|
-
var persistence = require('./persistence-
|
|
3
|
+
var configuration = require('./configuration-C8JgseHy.cjs');
|
|
4
|
+
var persistence = require('./persistence-BY-D00wT.cjs');
|
|
5
5
|
|
|
6
6
|
class AutomationsRequestError extends Error {
|
|
7
7
|
constructor(status, code, runStatus) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { randomUUID } from 'node:crypto';
|
|
2
|
-
import { c as configuration } from './configuration-
|
|
3
|
-
import { r as readSettings, c as readPersistedSessions, b as readCredentialsForConfiguredRelay } from './persistence-
|
|
4
|
-
import { r as readTeamScope, t as teamScopePath, w as writeTeamScope } from './context-
|
|
2
|
+
import { c as configuration } from './configuration-BPrfb17M.mjs';
|
|
3
|
+
import { r as readSettings, c as readPersistedSessions, b as readCredentialsForConfiguredRelay } from './persistence-D2Djrf7t.mjs';
|
|
4
|
+
import { r as readTeamScope, t as teamScopePath, w as writeTeamScope } from './context-_YGq8xdH.mjs';
|
|
5
5
|
|
|
6
6
|
async function teamRequest(path, method, token, scoped, body) {
|
|
7
7
|
const response = await fetch(`${configuration.serverUrl}${path}`, {
|
|
@@ -13,7 +13,11 @@ async function teamRequest(path, method, token, scoped, body) {
|
|
|
13
13
|
}).catch(() => {
|
|
14
14
|
throw new Error("Teams connection failed; outcome may be unknown. Reuse the request ID when retrying.");
|
|
15
15
|
});
|
|
16
|
-
if (!response.ok)
|
|
16
|
+
if (!response.ok) {
|
|
17
|
+
const body2 = response.status === 409 ? await response.json().catch(() => null) : null;
|
|
18
|
+
if (body2?.error === "session_in_other_team") throw new SessionInOtherTeamError(typeof body2.teamId === "string" ? body2.teamId : "", typeof body2.teamName === "string" ? body2.teamName : "");
|
|
19
|
+
throw new Error(`Teams request failed (HTTP ${response.status})`);
|
|
20
|
+
}
|
|
17
21
|
try {
|
|
18
22
|
return await response.json();
|
|
19
23
|
} catch {
|
|
@@ -22,6 +26,21 @@ async function teamRequest(path, method, token, scoped, body) {
|
|
|
22
26
|
}
|
|
23
27
|
class TeamConnectionPreflightError extends Error {
|
|
24
28
|
}
|
|
29
|
+
class SessionInOtherTeamError extends TeamConnectionPreflightError {
|
|
30
|
+
code = "session_in_other_team";
|
|
31
|
+
teamId;
|
|
32
|
+
teamName;
|
|
33
|
+
constructor(teamId, teamName) {
|
|
34
|
+
const safe = (value) => value.replace(/[\u0000-\u001f\u007f]/g, " ").slice(0, 128);
|
|
35
|
+
super(sessionInOtherTeamMessage(safe(teamName) || "another team", safe(teamId)));
|
|
36
|
+
this.teamId = safe(teamId);
|
|
37
|
+
this.teamName = safe(teamName);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
function sessionInOtherTeamMessage(teamName, teamId) {
|
|
41
|
+
return `This session is already the lead or a member of team "${teamName}"${teamId ? ` (${teamId})` : ""}. Call team_inspect and use team_delegate to assign work inside that team; do not create or join another team. \u4F60\u5DF2\u7ECF\u662F\u56E2\u961F\u300C${teamName}\u300D\u7684\u6210\u5458\u6216\u8D1F\u8D23\u4EBA\uFF0C\u8BF7\u5148 team_inspect\uFF0C\u518D\u7528 team_delegate \u5728\u672C\u56E2\u961F\u5185\u6D3E\u6D3B\uFF0C\u4E0D\u8981\u65B0\u5EFA\u6216\u52A0\u5165\u5176\u4ED6\u56E2\u961F\u3002`;
|
|
42
|
+
}
|
|
43
|
+
const NO_TEAM_SCOPE_MESSAGE = "This session has no team scope. Do not create a team to get one: if you lead or work in a team (for example after a restart), call team_inspect again or tell the user; use team_create or team_join only when the user asks for a new team.";
|
|
25
44
|
const initializationLocks = /* @__PURE__ */ new Map();
|
|
26
45
|
async function serializeInitialization(path, work) {
|
|
27
46
|
const previous = initializationLocks.get(path) ?? Promise.resolve();
|
|
@@ -34,6 +53,12 @@ async function serializeInitialization(path, work) {
|
|
|
34
53
|
if (initializationLocks.get(path) === next) initializationLocks.delete(path);
|
|
35
54
|
}
|
|
36
55
|
}
|
|
56
|
+
function teamCreateBody(input, machineId, sessionId, directory) {
|
|
57
|
+
const body = { name: input.name, machineId, requestId: input.requestId, sessionId, ...input.transfer ? { transfer: true } : {} };
|
|
58
|
+
if (input.noProject) return body;
|
|
59
|
+
if (input.projectId) return { ...body, project: { projectId: input.projectId } };
|
|
60
|
+
return { ...body, project: { inheritFromSessionId: sessionId, ...directory ? { directory } : {} } };
|
|
61
|
+
}
|
|
37
62
|
function createTeamsClient(sessionId) {
|
|
38
63
|
const scopePath = () => teamScopePath(sessionId ?? process.env.HAPPY_SESSION_ID);
|
|
39
64
|
return {
|
|
@@ -55,7 +80,7 @@ function createTeamsClient(sessionId) {
|
|
|
55
80
|
if (priorScope && !options?.expectedTeamId) throw new Error("This session already belongs to another team scope");
|
|
56
81
|
let teamId = input.teamId ?? options?.expectedTeamId;
|
|
57
82
|
if (!teamId) {
|
|
58
|
-
const created = await teamRequest("/v1/teams", "POST", credentials.token, false,
|
|
83
|
+
const created = await teamRequest("/v1/teams", "POST", credentials.token, false, teamCreateBody(input, machineId, sid, persisted.metadata.path));
|
|
59
84
|
teamId = created.team.id;
|
|
60
85
|
} else {
|
|
61
86
|
const existing = await teamRequest(`/v1/teams/${encodeURIComponent(teamId)}`, "GET", credentials.token, false);
|
|
@@ -74,7 +99,7 @@ function createTeamsClient(sessionId) {
|
|
|
74
99
|
"POST",
|
|
75
100
|
credentials.token,
|
|
76
101
|
false,
|
|
77
|
-
{ requestId: input.requestId, action: { type: "join", name: input.name, sessionId: sid, ...input.botId ? { botId: input.botId } : {} } }
|
|
102
|
+
{ requestId: input.requestId, action: { type: "join", name: input.name, sessionId: sid, ...input.botId ? { botId: input.botId } : {}, ...input.transfer ? { transfer: true } : {} } }
|
|
78
103
|
);
|
|
79
104
|
if (!result.credential?.token || !result.credential?.botId) throw new Error("Team join did not issue a credential");
|
|
80
105
|
await writeTeamScope(path, { serverUrl: configuration.serverUrl, teamId, botId: result.credential.botId, scopeToken: result.credential.token });
|
|
@@ -83,13 +108,13 @@ function createTeamsClient(sessionId) {
|
|
|
83
108
|
},
|
|
84
109
|
async inspect() {
|
|
85
110
|
const scope = await readTeamScope(scopePath());
|
|
86
|
-
if (!scope) throw new Error(
|
|
111
|
+
if (!scope) throw new Error(NO_TEAM_SCOPE_MESSAGE);
|
|
87
112
|
const { credential: _credential, ...safe } = await teamRequest(`/v1/teams/${encodeURIComponent(scope.teamId)}/agent`, "GET", scope.scopeToken, true);
|
|
88
113
|
return safe;
|
|
89
114
|
},
|
|
90
115
|
async action(action, requestId = randomUUID()) {
|
|
91
116
|
const scope = await readTeamScope(scopePath());
|
|
92
|
-
if (!scope) throw new Error(
|
|
117
|
+
if (!scope) throw new Error(NO_TEAM_SCOPE_MESSAGE);
|
|
93
118
|
const result = await teamRequest(`/v1/teams/${encodeURIComponent(scope.teamId)}/agent`, "POST", scope.scopeToken, true, { requestId, action });
|
|
94
119
|
const { credential: _credential, ...safe } = result;
|
|
95
120
|
return safe;
|
|
@@ -97,4 +122,4 @@ function createTeamsClient(sessionId) {
|
|
|
97
122
|
};
|
|
98
123
|
}
|
|
99
124
|
|
|
100
|
-
export { TeamConnectionPreflightError as T, createTeamsClient as c, teamRequest as t };
|
|
125
|
+
export { SessionInOtherTeamError as S, TeamConnectionPreflightError as T, createTeamsClient as c, teamRequest as t };
|