very-happy-cli 0.2.189 → 0.2.190
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-fj16v_cf.mjs → AcpBackend-Dd1h-Rgt.mjs} +3 -3
- package/dist/{AcpBackend-DRPJ2g9G.cjs → AcpBackend-dkRv9QHm.cjs} +3 -3
- package/dist/{AcpSessionManager-DM-KKg6v.cjs → AcpSessionManager-AqWAqahm.cjs} +1 -1
- package/dist/{AcpSessionManager-BZPmUDL5.mjs → AcpSessionManager-QBZ-CIf7.mjs} +2 -2
- package/dist/{BasePermissionHandler-CVtH-snr.mjs → BasePermissionHandler-CLp1ge-4.mjs} +1 -1
- package/dist/{BasePermissionHandler-DjM16uJz.cjs → BasePermissionHandler-CpSugp7Z.cjs} +1 -1
- package/dist/{acpSessionResume-2BTMsB7_.cjs → acpSessionResume-CZao6QEd.cjs} +1 -1
- package/dist/{acpSessionResume-Dxl1LRAT.mjs → acpSessionResume-CcpDuIO5.mjs} +1 -1
- package/dist/{agentHome-CHctmMzZ.mjs → agentHome-BJGRA2Kx.mjs} +4 -4
- package/dist/{agentHome-W17n1gnH.cjs → agentHome-fIUqT-pn.cjs} +4 -4
- package/dist/{api-BDuuyys8.cjs → api-CXL6jp-p.cjs} +18 -9
- package/dist/{api-B0yN68XH.mjs → api-Dw8gFsQi.mjs} +19 -10
- package/dist/{apiMachine-mc9CsKuS.mjs → apiMachine-BBNEtjf7.mjs} +56 -15
- package/dist/{apiMachine-iddD-F19.cjs → apiMachine-C6UqHoPF.cjs} +55 -14
- package/dist/{attachmentContent-CcIdMfAx.mjs → attachmentContent-CC4yIrSm.mjs} +2 -2
- package/dist/{attachmentContent-Cc5b7TPr.cjs → attachmentContent-NmVfKp-B.cjs} +2 -2
- package/dist/{auth-DQKSpaEf.cjs → auth-Bb_SL2os.cjs} +5 -5
- package/dist/{auth-DNAgkUkB.mjs → auth-Bh6SUoGi.mjs} +8 -8
- package/dist/{auth-CyrVvWHF.mjs → auth-Bj0psrD2.mjs} +5 -5
- package/dist/{auth-B7tVmyfX.cjs → auth-DKa4MsAi.cjs} +8 -8
- package/dist/{auto-CetlumDo.cjs → auto-C9Qohh0P.cjs} +15 -15
- package/dist/{auto-BklCipw1.mjs → auto-DK7pbCnV.mjs} +18 -18
- package/dist/{bootstrap-DfXwkUQb.mjs → bootstrap-Ct9Nb4sv.mjs} +2 -2
- package/dist/{bootstrap-CDY-Vz8q.cjs → bootstrap-DBJB0y-H.cjs} +2 -2
- package/dist/{browser-vb0k1zfI.mjs → browser-BGxDRhHy.mjs} +1 -1
- package/dist/{browser-D1yzC0Tu.cjs → browser-CLJWcodR.cjs} +1 -1
- package/dist/{claudeLocal-2dJIiTIq.cjs → claudeLocal-B6YDYlnY.cjs} +4 -4
- package/dist/{claudeLocal-Bid_rC_v.mjs → claudeLocal-Ux31hZyC.mjs} +5 -5
- package/dist/{claudeLocalLauncher-5pzpETxd.mjs → claudeLocalLauncher-D06QijMw.mjs} +10 -10
- package/dist/{claudeLocalLauncher-Jm5oQX5Z.cjs → claudeLocalLauncher-DFvmF8rC.cjs} +9 -9
- package/dist/{claudeSessionFork-DzecSBO4.mjs → claudeSessionFork-D2GI7P59.mjs} +1 -1
- package/dist/{claudeSessionFork-DsbcuDEJ.cjs → claudeSessionFork-DTLZ2rek.cjs} +1 -1
- package/dist/{client-D0aYWt53.cjs → client-Bffkrs5p.cjs} +2 -2
- package/dist/{client-BNmFaRXZ.cjs → client-CARZ_lNS.cjs} +3 -3
- package/dist/{client-DIfxYk7B.cjs → client-CMKGrnmT.cjs} +2 -2
- package/dist/{client-B161HwAk.mjs → client-CnGNYidN.mjs} +2 -2
- package/dist/{client-C9Ecbtko.mjs → client-CtL0Vtww.mjs} +4 -4
- package/dist/{client-CvjjadIE.mjs → client-DZkBUoh9.mjs} +2 -2
- package/dist/codex/happyMcpStdioBridge.cjs +15 -15
- package/dist/codex/happyMcpStdioBridge.mjs +16 -16
- package/dist/{codexAppServerClient-BlVmpjR-.mjs → codexAppServerClient-CLc5nhLT.mjs} +13 -6
- package/dist/{codexAppServerClient-CO9f4Jr8.cjs → codexAppServerClient-CpT9F6EM.cjs} +13 -6
- package/dist/{codexCommand-BfoRP6E9.cjs → codexCommand-39kH99SJ.cjs} +72 -48
- package/dist/{codexCommand-CAMR4g5o.mjs → codexCommand-Dliq3EBv.mjs} +69 -45
- package/dist/{codexTermination-IrLZQzKC.cjs → codexTermination-ByW7tRjr.cjs} +1 -1
- package/dist/{codexTermination-BvGlN02_.mjs → codexTermination-ORIw0gpU.mjs} +1 -1
- package/dist/{codexThreadFork-DNekT4nQ.cjs → codexThreadFork-5kwoKjMu.cjs} +11 -17
- package/dist/{codexThreadFork-R76RU5H0.mjs → codexThreadFork-DobPd19R.mjs} +11 -17
- package/dist/{config-BGFqQGvh.cjs → config-CeIzCsfj.cjs} +3 -3
- package/dist/{config-CtMgGPvf.mjs → config-CxSsGO1Z.mjs} +3 -3
- package/dist/{configuration-1FabKklB.mjs → configuration-Dechcvd-.mjs} +1 -1
- package/dist/{configuration-C0ctLGW2.cjs → configuration-Dt5lKW3P.cjs} +1 -1
- package/dist/{connect-DSw-2f52.cjs → connect-NPDzIVC6.cjs} +12 -12
- package/dist/{connect-0lSugpjf.mjs → connect-UwQHvCpR.mjs} +13 -13
- package/dist/{context-D-hEk5pC.cjs → context-BdZssgF0.cjs} +1 -1
- package/dist/{context-BgxbXWKS.mjs → context-C9JbJoNe.mjs} +1 -1
- package/dist/{controlClient-F7hAEEy2.cjs → controlClient-BRk65BRO.cjs} +3 -3
- package/dist/{controlClient-DwNnNAUx.mjs → controlClient-D7NGfmtq.mjs} +3 -3
- package/dist/{createSessionMetadata-DezS33OM.cjs → createSessionMetadata-B_HZCDj_.cjs} +2 -2
- package/dist/{createSessionMetadata-CG6Klinp.mjs → createSessionMetadata-DyhFKAby.mjs} +2 -2
- package/dist/defaultPermissionMode-BnxJPVHT.mjs +4 -0
- package/dist/defaultPermissionMode-CxmTXUQR.cjs +7 -0
- package/dist/{deterministicJson-D0LU_XbO.cjs → deterministicJson-BEygolBQ.cjs} +12 -12
- package/dist/{deterministicJson-BMwgK21e.mjs → deterministicJson-DNmMVhFu.mjs} +13 -13
- package/dist/{doctor-wVNvRarN.cjs → doctor-B9lW1WlG.cjs} +7 -7
- package/dist/{doctor-D16hySse.mjs → doctor-BdBi7TFZ.mjs} +7 -7
- package/dist/{downloadTarget-C6tqaXGm.mjs → downloadTarget-CGojGjaN.mjs} +6 -6
- package/dist/{downloadTarget-aNcCxVRL.cjs → downloadTarget-DS0zT2AU.cjs} +6 -6
- package/dist/{ensureDaemonRunning-DZq8bvsp.mjs → ensureDaemonRunning-BOdbryDM.mjs} +5 -5
- package/dist/{ensureDaemonRunning-CIghxgDR.cjs → ensureDaemonRunning-Bibp6vhe.cjs} +5 -5
- package/dist/exitAfterFlush-AbKNZM0N.mjs +23 -0
- package/dist/exitAfterFlush-DIT_sIxR.cjs +25 -0
- package/dist/{handleResumeCommand-BNnD7EuD.mjs → handleResumeCommand-CgLzBYne.mjs} +5 -5
- package/dist/{handleResumeCommand-CMUTygsm.cjs → handleResumeCommand-DXOuWr4p.cjs} +5 -5
- package/dist/{agentAttachments-Dbw8iMCZ.cjs → heldInput-BOtqFO2r.cjs} +27 -0
- package/dist/heldInput-C69lA2dH.mjs +44 -0
- package/dist/{index-De02DNu5.cjs → index-Bs5FD8JF.cjs} +4 -4
- package/dist/{index-BuiG8hmg.mjs → index-CBHfkQNY.mjs} +133 -54
- package/dist/{index-4TpmBb2Q.cjs → index-CwRW11hT.cjs} +3 -3
- package/dist/{index-Df0bc_et.mjs → index-DUByZsKe.mjs} +4 -4
- package/dist/{index-B81qV_F_.cjs → index-DXSIi6j_.cjs} +4 -4
- package/dist/{index-BCQr-5Ei.mjs → index-Db0HIC-k.mjs} +4 -4
- package/dist/{index-WKyN-bNy.mjs → index-DmqsRnV7.mjs} +1 -1
- package/dist/{index-CnzsOD19.cjs → index-f8oDidjV.cjs} +131 -52
- package/dist/{index-CKd20r1W.mjs → index-rNTX33in.mjs} +3 -3
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +2 -2
- package/dist/{install-DNbIEJUk.cjs → install-CXIL_FYx.cjs} +3 -3
- package/dist/{install-23ehAdTD.mjs → install-DfPrEWGG.mjs} +3 -3
- package/dist/lib.cjs +11 -11
- package/dist/lib.d.cts +53 -1
- package/dist/lib.d.mts +53 -1
- package/dist/lib.mjs +12 -12
- package/dist/{lidState-q5Its2Hm.mjs → lidState-D0DF20oG.mjs} +1 -1
- package/dist/{lidState-B4dHJCeS.cjs → lidState-q_XFYg33.cjs} +1 -1
- package/dist/{localHappyAgentAuth-C_G5u5lY.mjs → localHappyAgentAuth-BBhM4Qk1.mjs} +1 -1
- package/dist/{localHappyAgentAuth-CG2nPD_H.cjs → localHappyAgentAuth-CKNW-MXw.cjs} +1 -1
- package/dist/{logger-BP1SW7Cs.cjs → logger-BBRTTVsQ.cjs} +2 -2
- package/dist/{logger-DOKH3Zbh.mjs → logger-CL7pin9b.mjs} +2 -2
- package/dist/{machineMetadata-D-5qeIqd.mjs → machineMetadata-DP06qdBk.mjs} +3 -3
- package/dist/{machineMetadata-BKX3ov9g.cjs → machineMetadata-DnFNlrVK.cjs} +3 -3
- package/dist/{main-ndpVIaSG.cjs → main-DLOXykOR.cjs} +49 -48
- package/dist/{main-DODz8DQE.mjs → main-DO7nRvhf.mjs} +49 -48
- package/dist/{mcp-BBwbSODp.mjs → mcp-C-4sPTae.mjs} +15 -15
- package/dist/{mcp-Bc4U4exu.cjs → mcp-Du0MgR7e.cjs} +14 -14
- package/dist/{mirrorProtocol-CiA3hO2y.cjs → mirrorProtocol-GuWMxLkh.cjs} +2 -2
- package/dist/{mirrorProtocol-D2vTWteS.mjs → mirrorProtocol-dkq2ZENA.mjs} +3 -3
- package/dist/{package-DTcaIhjW.mjs → package-C6uiXULx.mjs} +7 -7
- package/dist/{package-CYDdLA6R.cjs → package-DrY090nZ.cjs} +7 -7
- package/dist/{panels-C2xZ8rqU.cjs → panels-4DRBKHZP.cjs} +5 -5
- package/dist/{panels-DCaLxlSL.mjs → panels-DXYdJA6n.mjs} +5 -5
- package/dist/{peerTools-B4315xjX.cjs → peerTools-5ZM4spcZ.cjs} +5 -5
- package/dist/{peerTools-BtrUnSwz.mjs → peerTools-dY1aJez4.mjs} +5 -5
- package/dist/{persistence-CrzC7yr_.cjs → persistence-Bl5S3TLB.cjs} +6 -2
- package/dist/{persistence-0INrP3aB.mjs → persistence-Dogj7JIp.mjs} +6 -3
- package/dist/{piRunnerArgs-BtzW_kfh.cjs → piRunnerArgs-C3jZ1M6b.cjs} +1 -1
- package/dist/{piRunnerArgs-DRuxMlX1.mjs → piRunnerArgs-D8nN_Iit.mjs} +1 -1
- package/dist/{piRuntime-DEbPE_kW.cjs → piRuntime-Bd9-eq6M.cjs} +1 -1
- package/dist/{piRuntime-BMAFpIBV.mjs → piRuntime-BoeMsAXK.mjs} +1 -1
- package/dist/{piTerminal-MtxDtBE2.cjs → piTerminal-C3j1ca3x.cjs} +16 -16
- package/dist/{piTerminal-DQXV8_we.mjs → piTerminal-GEPkIGD4.mjs} +17 -17
- package/dist/{pushNotifications-CalIS9sq.cjs → pushNotifications-CfspRcl-.cjs} +20 -2
- package/dist/{pushNotifications-Cq1s8YVK.mjs → pushNotifications-dUceOIni.mjs} +21 -3
- package/dist/{query-CE2XDhhw.cjs → query-DjsVgG3E.cjs} +1 -1
- package/dist/{query-BYiPBHPC.mjs → query-iYH-tm7L.mjs} +1 -1
- package/dist/{rateLimitReporter-BKmoOZQi.cjs → rateLimitReporter-DUu2KydZ.cjs} +3 -3
- package/dist/{rateLimitReporter-DR5LXuiQ.mjs → rateLimitReporter-jeVi-fym.mjs} +3 -3
- package/dist/{rateLimitWindows-Cs56YJCH.cjs → rateLimitWindows-Bx3ROBP5.cjs} +1 -1
- package/dist/{rateLimitWindows-5vIuNjko.mjs → rateLimitWindows-CEn0DXaX.mjs} +1 -1
- package/dist/{registerCommonHandlers-DZPozYxc.cjs → registerCommonHandlers-Beun-cQv.cjs} +2 -2
- package/dist/{registerCommonHandlers-DWkTysjD.mjs → registerCommonHandlers-DWZ7mfdt.mjs} +2 -2
- package/dist/{registerKillSessionHandler-DhCjrs44.cjs → registerKillSessionHandler-CA1FFr_F.cjs} +15 -5
- package/dist/{registerKillSessionHandler-CSCTRIbI.mjs → registerKillSessionHandler-CzgklwLG.mjs} +16 -6
- package/dist/{remoteSessionClient-Vfj_5g2-.mjs → remoteSessionClient-BiC2KDew.mjs} +5 -5
- package/dist/{remoteSessionClient-Dq8XTLQP.cjs → remoteSessionClient-DGFI__5Z.cjs} +5 -5
- package/dist/{reportProgressTool-B7zmX7NJ.mjs → reportProgressTool-CgPy6n_7.mjs} +3 -3
- package/dist/{reportProgressTool-DznxPKES.cjs → reportProgressTool-CvPGov1F.cjs} +2 -2
- package/dist/{run-DSfNcR62.mjs → run-B_gFgJVB.mjs} +392 -42
- package/dist/{run-Ca8BiNCp.cjs → run-rPqQwDi_.cjs} +389 -39
- package/dist/{runClaude-hoepv-0X.mjs → runClaude-CykqeXK7.mjs} +26 -23
- package/dist/{runClaude-ClQQcgoO.cjs → runClaude-DM8gm8iu.cjs} +27 -24
- package/dist/{runClaudeDeps-D_v8t2SK.mjs → runClaudeDeps-D2phXGut.mjs} +101 -44
- package/dist/{runClaudeDeps-ck5_GYlP.cjs → runClaudeDeps-DGAomimZ.cjs} +94 -37
- package/dist/{runGemini-Cj0XsMiM.cjs → runGemini-CXTeSOZp.cjs} +32 -32
- package/dist/{runGemini-CTr2-cYG.mjs → runGemini-CtWCVkj5.mjs} +33 -33
- package/dist/{runOpenClaw-CdDMntiV.mjs → runOpenClaw-BBdjlViJ.mjs} +18 -18
- package/dist/{runOpenClaw-BoN1e3lP.cjs → runOpenClaw-CH_9_RyZ.cjs} +17 -17
- package/dist/{sandbox-BY2h19gc.cjs → sandbox-Bb5IMun3.cjs} +4 -4
- package/dist/{sandbox-DcaWB-Ou.mjs → sandbox-DGmXZ6Zz.mjs} +4 -4
- package/dist/selfCheck-BfK945YQ.mjs +86 -0
- package/dist/{selfCheck-DFS_GUaQ.cjs → selfCheck-CccwNTTK.cjs} +37 -37
- package/dist/{send-UBTHHNvZ.mjs → send-B6rHg8GT.mjs} +8 -8
- package/dist/{send-BMsUYU6g.cjs → send-BpiXPkDo.cjs} +8 -8
- package/dist/{server-Dt3mCtfQ.mjs → server-BkdAyHhC.mjs} +4 -4
- package/dist/{server-YrHMHNz1.cjs → server-DHUzjApC.cjs} +6 -6
- package/dist/{sessionLock-DSqiP2lH.cjs → sessionLock-BFBReiKq.cjs} +134 -3
- package/dist/{sessionLock-tEFvFXLD.mjs → sessionLock-Ca_bIo50.mjs} +121 -4
- package/dist/{sessionOps-CljctDs5.mjs → sessionOps-CA2kpm66.mjs} +13 -5
- package/dist/{sessionOps-BzeOKIEF.cjs → sessionOps-DeWVqpe4.cjs} +13 -4
- package/dist/{sessionProvider-ORgzmkXy.cjs → sessionProvider-VFbtUmMR.cjs} +5 -5
- package/dist/{sessionProvider-BnUFSJXM.mjs → sessionProvider-g18IiK74.mjs} +5 -5
- package/dist/{sessionScanner-Cr6PJ3PT.cjs → sessionScanner-CGzsN8V6.cjs} +3 -3
- package/dist/{sessionScanner-DZUlkdF6.mjs → sessionScanner-DDDud5re.mjs} +3 -3
- package/dist/{sessions-15cag-su.mjs → sessions-B4d50sCI.mjs} +35 -26
- package/dist/{sessions-aIo_HjmY.cjs → sessions-CKJPWFgu.cjs} +36 -25
- package/dist/{setupOfflineReconnection-B7I8R2Ex.mjs → setupOfflineReconnection-CyPNgyCe.mjs} +2 -2
- package/dist/{setupOfflineReconnection-tV0Q1dgR.cjs → setupOfflineReconnection-DPXRo_zf.cjs} +2 -2
- package/dist/{spawn-VG-HjJiR.cjs → spawn-CgSJzzWS.cjs} +13 -13
- package/dist/{spawn-ByrQgruJ.mjs → spawn-CrYN_OOT.mjs} +15 -15
- package/dist/{spawnAgents-Bh1RPShN.mjs → spawnAgents-DWCDYCQ1.mjs} +1 -1
- package/dist/{spawnHappyCLI-CxiR2Qoy.cjs → spawnHappyCLI-CTy3p6V_.cjs} +1 -1
- package/dist/{spawnHappyCLI-CEsXwz5V.mjs → spawnHappyCLI-DjbkiSH1.mjs} +1 -1
- package/dist/{startFileWatcher-C-XCZ5t2.cjs → startFileWatcher-BQs0cJA-.cjs} +1 -1
- package/dist/{startFileWatcher-DkEeeAtL.mjs → startFileWatcher-Dedtu1vq.mjs} +1 -1
- package/dist/{defaultPermissionMode-e2bIIJG4.mjs → startupSessionCreate-BKFU4v_h.mjs} +25 -6
- package/dist/{defaultPermissionMode-5EvgRq38.cjs → startupSessionCreate-Dxy3X4DG.cjs} +25 -7
- package/dist/{streamRelay-CqBynIon.mjs → streamRelay-P9e7Sohm.mjs} +1 -1
- package/dist/{sync-CoChLEIg.cjs → sync-DtWB7RzA.cjs} +1 -1
- package/dist/{sync-BvDMkKAN.mjs → sync-eZkXnsW_.mjs} +1 -1
- package/dist/{systemPrompt-Dy_Rf-0Z.cjs → systemPrompt-2XOpZ1j6.cjs} +1 -1
- package/dist/{systemPrompt-CgDaPigN.mjs → systemPrompt-Bn6g6aCH.mjs} +2 -2
- package/dist/{teams-DPvfLAk8.cjs → teams-ecFay4Gn.cjs} +6 -6
- package/dist/{teams-BC4_e5hR.mjs → teams-nadkqrbW.mjs} +7 -7
- package/dist/{template-CEK8MEjo.mjs → template-BiTD-jI9.mjs} +1 -1
- package/dist/{time-CUK37wiV.mjs → time-CN3TuSVG.mjs} +1 -1
- package/dist/{time-XwEZxKGc.cjs → time-gPD_EmA-.cjs} +1 -1
- package/dist/{titleGenerator-DWRVdqMU.mjs → titleGenerator-DgzTQdn2.mjs} +1 -1
- package/dist/{titleGenerator-DVX0NZUn.cjs → titleGenerator-lT5ldPuN.cjs} +2 -2
- package/dist/{todo-CKGrSrRE.cjs → todo-B1VeMk5A.cjs} +5 -5
- package/dist/{todo-BNMGXneA.mjs → todo-BIxd7l2Q.mjs} +6 -6
- package/dist/{tools-CjMafO_D.cjs → tools-DvqbLsCF.cjs} +1 -1
- package/dist/{tools-CCIEAVbB.mjs → tools-zXJpxiG_.mjs} +1 -1
- package/dist/{uninstall-CJvJ7gjr.mjs → uninstall-9htK6mb7.mjs} +3 -3
- package/dist/{uninstall-BdFbTXnL.cjs → uninstall-CvIOpwB5.cjs} +3 -3
- package/package.json +7 -7
- package/dist/agentAttachments-M_B5qEF2.mjs +0 -18
- package/dist/selfCheck-BQ_H2Sns.mjs +0 -86
- package/dist/startupSessionCreate-CYc8mra-.cjs +0 -26
- package/dist/startupSessionCreate-npXe2TdN.mjs +0 -24
|
@@ -1,62 +1,63 @@
|
|
|
1
1
|
import os from 'node:os';
|
|
2
|
-
import { c as claimSessionOrExit, a as applyServerSnapshot, b as applyReconnectReplay, w as withoutServerSnapshot, m as mergeReconnectMetadata, e as exitCursorStamp } from './sessionLock-
|
|
3
|
-
import { r as readSettings, H as HIBERNATION_CAPABILITY, a as resolveCheckMs, l as latchKeepAwake, e as evaluateWrapperIdle } from './persistence-
|
|
4
|
-
import {
|
|
2
|
+
import { A as AUTO_RESTART_CAPABILITY, c as claimSessionOrExit, a as applyServerSnapshot, b as applyReconnectReplay, w as withoutServerSnapshot, m as mergeReconnectMetadata, t as takeAutoRestartedEvent, e as exitCursorStamp } from './sessionLock-Ca_bIo50.mjs';
|
|
3
|
+
import { r as readSettings, H as HIBERNATION_CAPABILITY, a as resolveCheckMs, l as latchKeepAwake, e as evaluateWrapperIdle } from './persistence-Dogj7JIp.mjs';
|
|
4
|
+
import { c as createSessionForStartup, H as HibernationProbe, a as commitHibernation } from './startupSessionCreate-BKFU4v_h.mjs';
|
|
5
5
|
import { randomUUID } from 'node:crypto';
|
|
6
|
-
import { c as connectionState, A as ApiClient, s as startOfflineReconnection } from './api-
|
|
7
|
-
import { l as logger } from './logger-
|
|
8
|
-
import { s as spawnOriginTags, a as sessionWorktreeMetadata } from './createSessionMetadata-
|
|
9
|
-
import { p as packageJson } from './package-
|
|
10
|
-
import { P as PROMPT_QUEUE_CAPABILITY, a as PROJECT_SESSION_CAPABILITY } from './index-
|
|
6
|
+
import { c as connectionState, A as ApiClient, s as startOfflineReconnection } from './api-Dw8gFsQi.mjs';
|
|
7
|
+
import { l as logger } from './logger-CL7pin9b.mjs';
|
|
8
|
+
import { s as spawnOriginTags, a as sessionWorktreeMetadata } from './createSessionMetadata-DyhFKAby.mjs';
|
|
9
|
+
import { p as packageJson } from './package-C6uiXULx.mjs';
|
|
10
|
+
import { P as PROMPT_QUEUE_CAPABILITY, a as PROJECT_SESSION_CAPABILITY } from './index-DmqsRnV7.mjs';
|
|
11
11
|
import { F as FORK_BACKFILL_CAPABILITY, p as publishForkBackfillWhenCommitted } from './forkBackfill-DYIjlN1Z.mjs';
|
|
12
|
-
import { c as configuration } from './configuration-
|
|
12
|
+
import { c as configuration } from './configuration-Dechcvd-.mjs';
|
|
13
13
|
import { l as loadSessionProvider, a as applyProviderEnv } from './providerBinding-CYubGg-Z.mjs';
|
|
14
|
-
import { n as notifyDaemonSessionStarted, c as checkDaemonHibernation } from './controlClient-
|
|
15
|
-
import { g as getInitialMachineMetadata } from './machineMetadata-
|
|
14
|
+
import { n as notifyDaemonSessionStarted, c as checkDaemonHibernation } from './controlClient-D7NGfmtq.mjs';
|
|
15
|
+
import { g as getInitialMachineMetadata } from './machineMetadata-DP06qdBk.mjs';
|
|
16
16
|
import { p as projectPath } from './projectPath-BTBIMB57.mjs';
|
|
17
17
|
import { resolve, join } from 'node:path';
|
|
18
|
-
import { c as createSessionForStartup } from './startupSessionCreate-npXe2TdN.mjs';
|
|
19
18
|
import { a as applySandboxPermissionPolicy, r as resolveInitialClaudePermissionMode, m as mapToClaudeMode, b as reconcilePublishedPermissionMode } from './permissionMode-CH4FoZfU.mjs';
|
|
20
19
|
import { d as decodeBase64, e as encodeBase64 } from './authRelay-DhQhkBvX.mjs';
|
|
21
20
|
import { readFile } from 'node:fs/promises';
|
|
22
|
-
import {
|
|
21
|
+
import { D as DEFAULT_CLAUDE_PERMISSION_MODE } from './defaultPermissionMode-BnxJPVHT.mjs';
|
|
22
|
+
import { C as CLAUDE_ATTACHMENT_KINDS, s as stripAttachmentManifest } from './attachmentContent-CC4yIrSm.mjs';
|
|
23
23
|
import { T as TranscriptPathHints } from './transcriptCursor-B7T_gkQ0.mjs';
|
|
24
24
|
import { p as planClaudeStartup } from './startupPlan-DFMyNgAs.mjs';
|
|
25
|
+
import './cliUpdate-Y34VGe9Y.mjs';
|
|
25
26
|
import 'node:fs';
|
|
26
27
|
import './processTreeSnapshot-CuLJDNC-.mjs';
|
|
27
28
|
import 'node:child_process';
|
|
28
29
|
import 'zod';
|
|
29
30
|
import 'axios';
|
|
30
|
-
import './lidState-
|
|
31
|
+
import './lidState-D0DF20oG.mjs';
|
|
31
32
|
import 'os';
|
|
32
33
|
import 'child_process';
|
|
33
34
|
import 'node:events';
|
|
34
35
|
import 'socket.io-client';
|
|
35
|
-
import './pushNotifications-
|
|
36
|
+
import './pushNotifications-dUceOIni.mjs';
|
|
36
37
|
import './contentLogMetadata-BlWI0egu.mjs';
|
|
37
38
|
import './limits-DIo7rEBR.mjs';
|
|
38
|
-
import './time-
|
|
39
|
-
import './registerCommonHandlers-
|
|
39
|
+
import './time-CN3TuSVG.mjs';
|
|
40
|
+
import './registerCommonHandlers-DWZ7mfdt.mjs';
|
|
40
41
|
import 'util';
|
|
41
42
|
import 'fs/promises';
|
|
42
43
|
import 'crypto';
|
|
43
44
|
import 'path';
|
|
44
45
|
import 'cross-spawn';
|
|
45
46
|
import '@paralleldrive/cuid2';
|
|
46
|
-
import './sync-
|
|
47
|
+
import './sync-eZkXnsW_.mjs';
|
|
47
48
|
import './backgroundTaskActivity-8PdPxrvy.mjs';
|
|
48
49
|
import 'chalk';
|
|
49
50
|
import 'node:util';
|
|
50
51
|
import './detectCLI-CSGMlV51.mjs';
|
|
51
52
|
import 'fs';
|
|
52
|
-
import './localHappyAgentAuth-
|
|
53
|
+
import './localHappyAgentAuth-BBhM4Qk1.mjs';
|
|
53
54
|
import 'tweetnacl';
|
|
54
55
|
import './fsMkdir-DumgLTzR.mjs';
|
|
55
56
|
import 'url';
|
|
56
57
|
|
|
57
58
|
const DEFAULT_CLAUDE_MODEL = void 0;
|
|
58
59
|
const DEFAULT_CLAUDE_EFFORT = void 0;
|
|
59
|
-
const importRunClaudeDeps = () => import('./runClaudeDeps-
|
|
60
|
+
const importRunClaudeDeps = () => import('./runClaudeDeps-D2phXGut.mjs');
|
|
60
61
|
async function runClaude(credentials, options = {}) {
|
|
61
62
|
logger.debug(`[CLAUDE] ===== CLAUDE MODE STARTING =====`);
|
|
62
63
|
logger.debug(`[CLAUDE] This is the Claude agent, NOT Gemini`);
|
|
@@ -70,7 +71,7 @@ async function runClaude(credentials, options = {}) {
|
|
|
70
71
|
const isAssistantVariant = process.env.HAPPY_SESSION_VARIANT === "assistant";
|
|
71
72
|
if (isAssistantVariant) {
|
|
72
73
|
try {
|
|
73
|
-
const { bootstrapAssistantHome } = await import('./bootstrap-
|
|
74
|
+
const { bootstrapAssistantHome } = await import('./bootstrap-Ct9Nb4sv.mjs');
|
|
74
75
|
await bootstrapAssistantHome();
|
|
75
76
|
} catch (error) {
|
|
76
77
|
logger.debug("[START] Assistant home bootstrap failed:", error);
|
|
@@ -145,7 +146,7 @@ async function runClaude(credentials, options = {}) {
|
|
|
145
146
|
// a brand-new session cannot pick a PDF until after sending once.
|
|
146
147
|
attachmentKinds: [...CLAUDE_ATTACHMENT_KINDS],
|
|
147
148
|
queueCancellation: true,
|
|
148
|
-
capabilities: ["claude-steer-v1", "claude-live-permission-v1", "claude-live-permission-v2", "claude-btw-v1", "claude-runtime-controls-v1", "claude-opus-5-5-v1", PROMPT_QUEUE_CAPABILITY, FORK_BACKFILL_CAPABILITY, HIBERNATION_CAPABILITY, PROJECT_SESSION_CAPABILITY],
|
|
149
|
+
capabilities: ["claude-steer-v1", "claude-live-permission-v1", "claude-live-permission-v2", "claude-btw-v1", "claude-runtime-controls-v1", "claude-opus-5-5-v1", PROMPT_QUEUE_CAPABILITY, FORK_BACKFILL_CAPABILITY, HIBERNATION_CAPABILITY, AUTO_RESTART_CAPABILITY, PROJECT_SESSION_CAPABILITY],
|
|
149
150
|
// Effective mode this process enforces. Kept current by
|
|
150
151
|
// publishPermissionMode below; the web renders it instead of guessing.
|
|
151
152
|
permissionMode: mapToClaudeMode(initialPermissionMode ?? "default"),
|
|
@@ -190,7 +191,7 @@ async function runClaude(credentials, options = {}) {
|
|
|
190
191
|
}
|
|
191
192
|
if (!response) {
|
|
192
193
|
let offlineSessionId = null;
|
|
193
|
-
const { claudeLocal } = await import('./claudeLocal-
|
|
194
|
+
const { claudeLocal } = await import('./claudeLocal-Ux31hZyC.mjs');
|
|
194
195
|
const { createSessionScanner: createSessionScanner2 } = await loadDeps();
|
|
195
196
|
const reconnection = startOfflineReconnection({
|
|
196
197
|
serverUrl: configuration.serverUrl,
|
|
@@ -919,6 +920,8 @@ async function runClaude(credentials, options = {}) {
|
|
|
919
920
|
});
|
|
920
921
|
hibernationProbe.start();
|
|
921
922
|
}
|
|
923
|
+
const autoUpdated = takeAutoRestartedEvent(process.env);
|
|
924
|
+
if (autoUpdated) session.sendSessionEvent(autoUpdated);
|
|
922
925
|
const exitCode = await loop({
|
|
923
926
|
path: workingDirectory,
|
|
924
927
|
model: options.model,
|
|
@@ -1,64 +1,65 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var os = require('node:os');
|
|
4
|
-
var sessionLock = require('./sessionLock-
|
|
5
|
-
var persistence = require('./persistence-
|
|
6
|
-
var
|
|
4
|
+
var sessionLock = require('./sessionLock-BFBReiKq.cjs');
|
|
5
|
+
var persistence = require('./persistence-Bl5S3TLB.cjs');
|
|
6
|
+
var startupSessionCreate = require('./startupSessionCreate-Dxy3X4DG.cjs');
|
|
7
7
|
var node_crypto = require('node:crypto');
|
|
8
|
-
var api = require('./api-
|
|
9
|
-
var logger = require('./logger-
|
|
10
|
-
var createSessionMetadata = require('./createSessionMetadata-
|
|
11
|
-
var _package = require('./package-
|
|
8
|
+
var api = require('./api-CXL6jp-p.cjs');
|
|
9
|
+
var logger = require('./logger-BBRTTVsQ.cjs');
|
|
10
|
+
var createSessionMetadata = require('./createSessionMetadata-B_HZCDj_.cjs');
|
|
11
|
+
var _package = require('./package-DrY090nZ.cjs');
|
|
12
12
|
var index = require('./index-BOe6dKnL.cjs');
|
|
13
13
|
var forkBackfill = require('./forkBackfill-8eLDeS73.cjs');
|
|
14
|
-
var configuration = require('./configuration-
|
|
14
|
+
var configuration = require('./configuration-Dt5lKW3P.cjs');
|
|
15
15
|
var providerBinding = require('./providerBinding-B-Qbx9W2.cjs');
|
|
16
|
-
var controlClient = require('./controlClient-
|
|
17
|
-
var machineMetadata = require('./machineMetadata-
|
|
16
|
+
var controlClient = require('./controlClient-BRk65BRO.cjs');
|
|
17
|
+
var machineMetadata = require('./machineMetadata-DnFNlrVK.cjs');
|
|
18
18
|
var projectPath = require('./projectPath-C3ioB4Bu.cjs');
|
|
19
19
|
var path = require('node:path');
|
|
20
|
-
var startupSessionCreate = require('./startupSessionCreate-CYc8mra-.cjs');
|
|
21
20
|
var permissionMode = require('./permissionMode-CrV-XuMs.cjs');
|
|
22
21
|
var authRelay = require('./authRelay-Dy1qU9td.cjs');
|
|
23
22
|
var promises = require('node:fs/promises');
|
|
24
|
-
var
|
|
23
|
+
var defaultPermissionMode = require('./defaultPermissionMode-CxmTXUQR.cjs');
|
|
24
|
+
var attachmentContent = require('./attachmentContent-NmVfKp-B.cjs');
|
|
25
25
|
var transcriptCursor = require('./transcriptCursor-DcXGLeSc.cjs');
|
|
26
26
|
var startupPlan = require('./startupPlan-BLMbfQIH.cjs');
|
|
27
|
+
require('./cliUpdate-DsKXPFYp.cjs');
|
|
27
28
|
require('node:fs');
|
|
28
29
|
require('./processTreeSnapshot-mDbnuojn.cjs');
|
|
29
30
|
require('node:child_process');
|
|
30
31
|
require('zod');
|
|
31
32
|
require('axios');
|
|
32
|
-
require('./lidState-
|
|
33
|
+
require('./lidState-q_XFYg33.cjs');
|
|
33
34
|
require('os');
|
|
34
35
|
require('child_process');
|
|
35
36
|
require('node:events');
|
|
36
37
|
require('socket.io-client');
|
|
37
|
-
require('./pushNotifications-
|
|
38
|
+
require('./pushNotifications-CfspRcl-.cjs');
|
|
38
39
|
require('./contentLogMetadata-ZSFk_NjQ.cjs');
|
|
39
40
|
require('./limits-C-a7gr04.cjs');
|
|
40
|
-
require('./time-
|
|
41
|
-
require('./registerCommonHandlers-
|
|
41
|
+
require('./time-gPD_EmA-.cjs');
|
|
42
|
+
require('./registerCommonHandlers-Beun-cQv.cjs');
|
|
42
43
|
require('util');
|
|
43
44
|
require('fs/promises');
|
|
44
45
|
require('crypto');
|
|
45
46
|
require('path');
|
|
46
47
|
require('cross-spawn');
|
|
47
48
|
require('@paralleldrive/cuid2');
|
|
48
|
-
require('./sync-
|
|
49
|
+
require('./sync-DtWB7RzA.cjs');
|
|
49
50
|
require('./backgroundTaskActivity-CBvUdj39.cjs');
|
|
50
51
|
require('chalk');
|
|
51
52
|
require('node:util');
|
|
52
53
|
require('./detectCLI-BuYR_Qxe.cjs');
|
|
53
54
|
require('fs');
|
|
54
|
-
require('./localHappyAgentAuth-
|
|
55
|
+
require('./localHappyAgentAuth-CKNW-MXw.cjs');
|
|
55
56
|
require('tweetnacl');
|
|
56
57
|
require('./fsMkdir-0K3yENml.cjs');
|
|
57
58
|
require('url');
|
|
58
59
|
|
|
59
60
|
const DEFAULT_CLAUDE_MODEL = void 0;
|
|
60
61
|
const DEFAULT_CLAUDE_EFFORT = void 0;
|
|
61
|
-
const importRunClaudeDeps = () => Promise.resolve().then(function () { return require('./runClaudeDeps-
|
|
62
|
+
const importRunClaudeDeps = () => Promise.resolve().then(function () { return require('./runClaudeDeps-DGAomimZ.cjs'); });
|
|
62
63
|
async function runClaude(credentials, options = {}) {
|
|
63
64
|
logger.logger.debug(`[CLAUDE] ===== CLAUDE MODE STARTING =====`);
|
|
64
65
|
logger.logger.debug(`[CLAUDE] This is the Claude agent, NOT Gemini`);
|
|
@@ -72,7 +73,7 @@ async function runClaude(credentials, options = {}) {
|
|
|
72
73
|
const isAssistantVariant = process.env.HAPPY_SESSION_VARIANT === "assistant";
|
|
73
74
|
if (isAssistantVariant) {
|
|
74
75
|
try {
|
|
75
|
-
const { bootstrapAssistantHome } = await Promise.resolve().then(function () { return require('./bootstrap-
|
|
76
|
+
const { bootstrapAssistantHome } = await Promise.resolve().then(function () { return require('./bootstrap-DBJB0y-H.cjs'); });
|
|
76
77
|
await bootstrapAssistantHome();
|
|
77
78
|
} catch (error) {
|
|
78
79
|
logger.logger.debug("[START] Assistant home bootstrap failed:", error);
|
|
@@ -147,7 +148,7 @@ async function runClaude(credentials, options = {}) {
|
|
|
147
148
|
// a brand-new session cannot pick a PDF until after sending once.
|
|
148
149
|
attachmentKinds: [...attachmentContent.CLAUDE_ATTACHMENT_KINDS],
|
|
149
150
|
queueCancellation: true,
|
|
150
|
-
capabilities: ["claude-steer-v1", "claude-live-permission-v1", "claude-live-permission-v2", "claude-btw-v1", "claude-runtime-controls-v1", "claude-opus-5-5-v1", index.PROMPT_QUEUE_CAPABILITY, forkBackfill.FORK_BACKFILL_CAPABILITY, persistence.HIBERNATION_CAPABILITY, index.PROJECT_SESSION_CAPABILITY],
|
|
151
|
+
capabilities: ["claude-steer-v1", "claude-live-permission-v1", "claude-live-permission-v2", "claude-btw-v1", "claude-runtime-controls-v1", "claude-opus-5-5-v1", index.PROMPT_QUEUE_CAPABILITY, forkBackfill.FORK_BACKFILL_CAPABILITY, persistence.HIBERNATION_CAPABILITY, sessionLock.AUTO_RESTART_CAPABILITY, index.PROJECT_SESSION_CAPABILITY],
|
|
151
152
|
// Effective mode this process enforces. Kept current by
|
|
152
153
|
// publishPermissionMode below; the web renders it instead of guessing.
|
|
153
154
|
permissionMode: permissionMode.mapToClaudeMode(initialPermissionMode ?? "default"),
|
|
@@ -192,7 +193,7 @@ async function runClaude(credentials, options = {}) {
|
|
|
192
193
|
}
|
|
193
194
|
if (!response) {
|
|
194
195
|
let offlineSessionId = null;
|
|
195
|
-
const { claudeLocal } = await Promise.resolve().then(function () { return require('./claudeLocal-
|
|
196
|
+
const { claudeLocal } = await Promise.resolve().then(function () { return require('./claudeLocal-B6YDYlnY.cjs'); });
|
|
196
197
|
const { createSessionScanner: createSessionScanner2 } = await loadDeps();
|
|
197
198
|
const reconnection = api.startOfflineReconnection({
|
|
198
199
|
serverUrl: configuration.configuration.serverUrl,
|
|
@@ -894,11 +895,11 @@ async function runClaude(credentials, options = {}) {
|
|
|
894
895
|
};
|
|
895
896
|
};
|
|
896
897
|
if (options.startedBy === "daemon" && options.startingMode === "remote" && !isAssistantVariant) {
|
|
897
|
-
hibernationProbe = new
|
|
898
|
+
hibernationProbe = new startupSessionCreate.HibernationProbe({
|
|
898
899
|
checkMs: persistence.resolveCheckMs(),
|
|
899
900
|
snapshot: hibernationSnapshot,
|
|
900
901
|
ask: (report) => controlClient.checkDaemonHibernation({ sessionId: session.sessionId, pid: process.pid, report }),
|
|
901
|
-
commit: (idleMs) =>
|
|
902
|
+
commit: (idleMs) => startupSessionCreate.commitHibernation({
|
|
902
903
|
client: session,
|
|
903
904
|
claimExit: () => exitGate.claim("hibernate") !== null,
|
|
904
905
|
exitRequested: () => exitGate.exitRequested,
|
|
@@ -921,6 +922,8 @@ async function runClaude(credentials, options = {}) {
|
|
|
921
922
|
});
|
|
922
923
|
hibernationProbe.start();
|
|
923
924
|
}
|
|
925
|
+
const autoUpdated = sessionLock.takeAutoRestartedEvent(process.env);
|
|
926
|
+
if (autoUpdated) session.sendSessionEvent(autoUpdated);
|
|
924
927
|
const exitCode = await loop({
|
|
925
928
|
path: workingDirectory,
|
|
926
929
|
model: options.model,
|
|
@@ -1,81 +1,81 @@
|
|
|
1
|
-
import { l as logger } from './logger-
|
|
2
|
-
import { q as notifyDaemonSessionEvent, t as notifyDaemonClaudeAuthFailed } from './controlClient-
|
|
3
|
-
export { k as reportSessionEditToDaemon } from './controlClient-
|
|
1
|
+
import { l as logger } from './logger-CL7pin9b.mjs';
|
|
2
|
+
import { q as notifyDaemonSessionEvent, t as notifyDaemonClaudeAuthFailed } from './controlClient-D7NGfmtq.mjs';
|
|
3
|
+
export { k as reportSessionEditToDaemon } from './controlClient-D7NGfmtq.mjs';
|
|
4
4
|
import { s as sameBackgroundTasks, c as createBackgroundTaskTracker } from './backgroundTaskActivity-8PdPxrvy.mjs';
|
|
5
|
-
import { c as createProjectInjector, h as hashObject, l as leadBoardFor } from './deterministicJson-
|
|
6
|
-
export { s as startHappyServer } from './deterministicJson-
|
|
7
|
-
import { s as sharedProjectsClient } from './client-
|
|
5
|
+
import { c as createProjectInjector, h as hashObject, l as leadBoardFor } from './deterministicJson-DNmMVhFu.mjs';
|
|
6
|
+
export { s as startHappyServer } from './deterministicJson-DNmMVhFu.mjs';
|
|
7
|
+
import { s as sharedProjectsClient } from './client-CnGNYidN.mjs';
|
|
8
8
|
import { randomInt, randomUUID, createHash } from 'node:crypto';
|
|
9
9
|
import { a as parseSpecialCommand } from './specialCommands-MXUN0wfI.mjs';
|
|
10
10
|
import { M as MessageBuffer } from './sessionExitLifecycle-CzkLIgNZ.mjs';
|
|
11
11
|
export { S as SessionExitGate, e as exitIntentFromArchiveFlag, s as settleSessionOnExit } from './sessionExitLifecycle-CzkLIgNZ.mjs';
|
|
12
|
-
import { q as query } from './query-
|
|
12
|
+
import { q as query } from './query-iYH-tm7L.mjs';
|
|
13
13
|
import { AbortError } from '@anthropic-ai/claude-agent-sdk';
|
|
14
14
|
import { m as mapToClaudeMode, p as parseClaudePermissionMode, c as resolveRemoteClaudePermissionMode } from './permissionMode-CH4FoZfU.mjs';
|
|
15
|
-
import { c as claudeCheckSession, s as systemPrompt } from './systemPrompt-
|
|
15
|
+
import { c as claudeCheckSession, s as systemPrompt } from './systemPrompt-Bn6g6aCH.mjs';
|
|
16
16
|
import { join, resolve, dirname } from 'node:path';
|
|
17
17
|
import 'axios';
|
|
18
18
|
import 'node:events';
|
|
19
19
|
import 'socket.io-client';
|
|
20
|
-
import { A as AsyncLock } from './pushNotifications-
|
|
20
|
+
import { A as AsyncLock } from './pushNotifications-dUceOIni.mjs';
|
|
21
21
|
import 'tweetnacl';
|
|
22
|
-
import { c as configuration, e as ensurePrivateDirectory } from './configuration-
|
|
23
|
-
import './index-
|
|
24
|
-
import './registerCommonHandlers-
|
|
22
|
+
import { c as configuration, e as ensurePrivateDirectory } from './configuration-Dechcvd-.mjs';
|
|
23
|
+
import './index-DmqsRnV7.mjs';
|
|
24
|
+
import './registerCommonHandlers-DWZ7mfdt.mjs';
|
|
25
25
|
import 'os';
|
|
26
26
|
import 'child_process';
|
|
27
27
|
import '@paralleldrive/cuid2';
|
|
28
|
-
import './persistence-
|
|
28
|
+
import './persistence-Dogj7JIp.mjs';
|
|
29
29
|
import { c as contentLogMetadata } from './contentLogMetadata-BlWI0egu.mjs';
|
|
30
30
|
import 'chalk';
|
|
31
31
|
import { R as RawJSONLinesSchema } from './types-CkqAACXx.mjs';
|
|
32
32
|
import { g as getProjectPath } from './path-D2wdaNSk.mjs';
|
|
33
33
|
import { access } from 'fs/promises';
|
|
34
|
-
import { d as delay } from './time-
|
|
34
|
+
import { d as delay } from './time-CN3TuSVG.mjs';
|
|
35
35
|
import { mkdirSync, writeFileSync, readFileSync, unlinkSync, renameSync, statSync, existsSync } from 'node:fs';
|
|
36
|
-
import { F as Future, d as describeClaudeProcessExit } from './sessionScanner-
|
|
37
|
-
export { c as createSessionScanner } from './sessionScanner-
|
|
36
|
+
import { F as Future, d as describeClaudeProcessExit } from './sessionScanner-DDDud5re.mjs';
|
|
37
|
+
export { c as createSessionScanner } from './sessionScanner-DDDud5re.mjs';
|
|
38
38
|
import { execSync } from 'node:child_process';
|
|
39
|
-
import { S as StreamRelay } from './streamRelay-
|
|
40
|
-
import { C as CLAUDE_ATTACHMENT_KINDS, c as chatAttachmentDirectory, a as stageClaudeAttachments, b as appendStagedAttachmentsToPrompt } from './attachmentContent-
|
|
39
|
+
import { S as StreamRelay } from './streamRelay-P9e7Sohm.mjs';
|
|
40
|
+
import { C as CLAUDE_ATTACHMENT_KINDS, c as chatAttachmentDirectory, a as stageClaudeAttachments, b as appendStagedAttachmentsToPrompt } from './attachmentContent-CC4yIrSm.mjs';
|
|
41
41
|
import { writeFile, rename, unlink, readFile } from 'node:fs/promises';
|
|
42
|
-
import { F as ForkSourceMissingError } from './claudeSessionFork-
|
|
43
|
-
import { w as wrapperRateLimitReporter } from './rateLimitReporter-
|
|
44
|
-
export { M as MessageQueue2, r as registerKillSessionHandler } from './registerKillSessionHandler-
|
|
45
|
-
export { g as getEnvironmentInfo } from './doctor-
|
|
42
|
+
import { F as ForkSourceMissingError } from './claudeSessionFork-D2GI7P59.mjs';
|
|
43
|
+
import { w as wrapperRateLimitReporter } from './rateLimitReporter-jeVi-fym.mjs';
|
|
44
|
+
export { M as MessageQueue2, r as registerKillSessionHandler } from './registerKillSessionHandler-CzgklwLG.mjs';
|
|
45
|
+
export { g as getEnvironmentInfo } from './doctor-BdBi7TFZ.mjs';
|
|
46
46
|
import { createServer } from 'node:http';
|
|
47
47
|
export { E as EditReportThrottle, b as extractClaudeEditPaths } from './editPaths-BVfS_FFL.mjs';
|
|
48
48
|
import { p as projectPath } from './projectPath-BTBIMB57.mjs';
|
|
49
49
|
export { s as snapshotTree, t as terminateSurvivors } from './processTreeSnapshot-CuLJDNC-.mjs';
|
|
50
|
-
import { r as resolveClaudeBinary, a as runClaudeOneShot } from './titleGenerator-
|
|
51
|
-
export { T as TitleGenerator } from './titleGenerator-
|
|
50
|
+
import { r as resolveClaudeBinary, a as runClaudeOneShot } from './titleGenerator-DgzTQdn2.mjs';
|
|
51
|
+
export { T as TitleGenerator } from './titleGenerator-DgzTQdn2.mjs';
|
|
52
52
|
import { B as BOARD_ANALYZER_PROMPT_PREFIX } from './oneShotPrompts-DT4p6RNd.mjs';
|
|
53
|
-
import { i as isSelfReportFresh } from './reportProgressTool-
|
|
54
|
-
export { c as createSelfReportState } from './reportProgressTool-
|
|
53
|
+
import { i as isSelfReportFresh } from './reportProgressTool-CgPy6n_7.mjs';
|
|
54
|
+
export { c as createSelfReportState } from './reportProgressTool-CgPy6n_7.mjs';
|
|
55
55
|
import 'node:util';
|
|
56
56
|
import './prompt-QHuFx9j6.mjs';
|
|
57
57
|
import 'node:os';
|
|
58
58
|
import 'zod';
|
|
59
59
|
import './pi-CqyoZMjI.mjs';
|
|
60
60
|
import './fileStore-5qpetZS0.mjs';
|
|
61
|
-
import './client-
|
|
62
|
-
import './context-
|
|
63
|
-
import './sessionOps-
|
|
61
|
+
import './client-CtL0Vtww.mjs';
|
|
62
|
+
import './context-C9JbJoNe.mjs';
|
|
63
|
+
import './sessionOps-CA2kpm66.mjs';
|
|
64
64
|
import './authRelay-DhQhkBvX.mjs';
|
|
65
65
|
import './resources-CLP_MpK4.mjs';
|
|
66
|
-
import './tools-
|
|
67
|
-
import './peerTools-
|
|
66
|
+
import './tools-zXJpxiG_.mjs';
|
|
67
|
+
import './peerTools-dY1aJez4.mjs';
|
|
68
68
|
import './ids-DU6sLx4C.mjs';
|
|
69
|
-
import './remoteSessionClient-
|
|
69
|
+
import './remoteSessionClient-BiC2KDew.mjs';
|
|
70
70
|
import '@modelcontextprotocol/sdk/server/mcp.js';
|
|
71
71
|
import '@modelcontextprotocol/sdk/server/streamableHttp.js';
|
|
72
72
|
import './limits-DIo7rEBR.mjs';
|
|
73
|
-
import './downloadTarget-
|
|
73
|
+
import './downloadTarget-CGojGjaN.mjs';
|
|
74
74
|
import './terminals-Dlg0x3nY.mjs';
|
|
75
75
|
import './terminalTitleSuggest-CeKsX_V6.mjs';
|
|
76
76
|
import './tmuxSocket-B8Yx20sT.mjs';
|
|
77
|
-
import './bootstrap-
|
|
78
|
-
import './package-
|
|
77
|
+
import './bootstrap-Ct9Nb4sv.mjs';
|
|
78
|
+
import './package-C6uiXULx.mjs';
|
|
79
79
|
import './agentGuidance-BDYt2Qy2.mjs';
|
|
80
80
|
import './trimIdent-BAjmv_TG.mjs';
|
|
81
81
|
import './webPanels-B2_C2-3g.mjs';
|
|
@@ -85,22 +85,22 @@ import './promptCacheTtl-Ce0TVbrx.mjs';
|
|
|
85
85
|
import 'util';
|
|
86
86
|
import 'path';
|
|
87
87
|
import 'cross-spawn';
|
|
88
|
-
import './sync-
|
|
88
|
+
import './sync-eZkXnsW_.mjs';
|
|
89
89
|
import './transcriptCursor-B7T_gkQ0.mjs';
|
|
90
|
-
import './startFileWatcher-
|
|
90
|
+
import './startFileWatcher-Dedtu1vq.mjs';
|
|
91
91
|
import 'node:readline';
|
|
92
|
-
import './rateLimitWindows-
|
|
92
|
+
import './rateLimitWindows-CEn0DXaX.mjs';
|
|
93
93
|
import './doctor-BPkYWSuq.mjs';
|
|
94
94
|
import 'ps-list';
|
|
95
95
|
import './doctorReadiness-C208SMN9.mjs';
|
|
96
96
|
import './detectCLI-CSGMlV51.mjs';
|
|
97
97
|
import 'fs';
|
|
98
98
|
import './cliUpdate-Y34VGe9Y.mjs';
|
|
99
|
-
import './piRunnerArgs-
|
|
100
|
-
import './acpSessionResume-
|
|
99
|
+
import './piRunnerArgs-D8nN_Iit.mjs';
|
|
100
|
+
import './acpSessionResume-CcpDuIO5.mjs';
|
|
101
101
|
import 'url';
|
|
102
102
|
import 'node:module';
|
|
103
|
-
import './client-
|
|
103
|
+
import './client-DZkBUoh9.mjs';
|
|
104
104
|
import './precheckCompat-DeEbilbr.mjs';
|
|
105
105
|
|
|
106
106
|
const SCHEDULE_WAKEUP_GRACE_MS = 6e4;
|
|
@@ -772,6 +772,10 @@ function planUnconfirmedCommands(commands, context) {
|
|
|
772
772
|
tombstone: commands.filter((_, i) => i !== index).map((c) => c.uuid)
|
|
773
773
|
};
|
|
774
774
|
}
|
|
775
|
+
function planUndeliveredMessage(message, context) {
|
|
776
|
+
if (context.exiting || !context.parkFree) return null;
|
|
777
|
+
return { ...message, finalized: true };
|
|
778
|
+
}
|
|
775
779
|
|
|
776
780
|
const AUTH_FAILURE_RESULT_TEXT = /Failed to authenticate|OAuth session expired/i;
|
|
777
781
|
const QUERY_RECYCLE_NOTICE = {
|
|
@@ -1633,11 +1637,17 @@ async function claudeRemote(opts) {
|
|
|
1633
1637
|
if (initialUserMessage.uuid) commandTracker.track(initialUserMessage.uuid, { message: initial.message, mode: initial.mode });
|
|
1634
1638
|
let modelUnconfirmed = false;
|
|
1635
1639
|
let pullingNext = false;
|
|
1640
|
+
let queryClosed = false;
|
|
1641
|
+
const inputClosed = () => queryClosed || messages.done;
|
|
1636
1642
|
const pullNextMessage = () => {
|
|
1637
1643
|
if (pullingNext) {
|
|
1638
1644
|
logger.debug("[claudeRemote] Already waiting for the next message");
|
|
1639
1645
|
return;
|
|
1640
1646
|
}
|
|
1647
|
+
if (inputClosed()) {
|
|
1648
|
+
logger.debug("[claudeRemote] Input closed; the next message belongs to the next launch");
|
|
1649
|
+
return;
|
|
1650
|
+
}
|
|
1641
1651
|
pullingNext = true;
|
|
1642
1652
|
opts.nextMessage().then(async (pulled) => {
|
|
1643
1653
|
let next = withoutRetiredModel(pulled);
|
|
@@ -1646,6 +1656,16 @@ async function claudeRemote(opts) {
|
|
|
1646
1656
|
messages.end();
|
|
1647
1657
|
return;
|
|
1648
1658
|
}
|
|
1659
|
+
const handBack = (message) => {
|
|
1660
|
+
pullingNext = false;
|
|
1661
|
+
logger.debug("[claudeRemote] Query input closed before the pulled message was sent; handing it back to the launcher");
|
|
1662
|
+
if (opts.onUndeliveredMessage) opts.onUndeliveredMessage(message);
|
|
1663
|
+
else logger.warn("[claudeRemote] Pulled message could not be delivered and no owner took it back");
|
|
1664
|
+
};
|
|
1665
|
+
if (inputClosed()) {
|
|
1666
|
+
handBack(next);
|
|
1667
|
+
return;
|
|
1668
|
+
}
|
|
1649
1669
|
if (modelUnconfirmed || needsModelSwitch(mode.model, next.mode.model)) {
|
|
1650
1670
|
try {
|
|
1651
1671
|
await withTimeout(response.setModel(modelTarget(next.mode.model)), SET_MODEL_TIMEOUT_MS, "set_model");
|
|
@@ -1653,11 +1673,19 @@ async function claudeRemote(opts) {
|
|
|
1653
1673
|
logger.debug(`[claudeRemote] Model switched to ${modelTarget(next.mode.model) ?? "default"}`);
|
|
1654
1674
|
} catch (e) {
|
|
1655
1675
|
logger.debug(`[claudeRemote] setModel failed: ${e instanceof Error ? e.message : String(e)}`);
|
|
1676
|
+
if (inputClosed()) {
|
|
1677
|
+
handBack(next);
|
|
1678
|
+
return;
|
|
1679
|
+
}
|
|
1656
1680
|
opts.onCompletionEvent?.(modelSwitchFailureNotice(next.mode.model, e));
|
|
1657
1681
|
if (e instanceof TimeoutError) modelUnconfirmed = true;
|
|
1658
1682
|
next = { ...next, mode: { ...next.mode, model: mode.model } };
|
|
1659
1683
|
}
|
|
1660
1684
|
}
|
|
1685
|
+
if (inputClosed()) {
|
|
1686
|
+
handBack(next);
|
|
1687
|
+
return;
|
|
1688
|
+
}
|
|
1661
1689
|
mode = next.mode;
|
|
1662
1690
|
updateThinking(true);
|
|
1663
1691
|
turn.pushed();
|
|
@@ -1837,6 +1865,7 @@ async function claudeRemote(opts) {
|
|
|
1837
1865
|
}
|
|
1838
1866
|
} finally {
|
|
1839
1867
|
updateThinking(false);
|
|
1868
|
+
queryClosed = true;
|
|
1840
1869
|
if (cliCapabilities.has(MSG_LIFECYCLE_CAPABILITY)) {
|
|
1841
1870
|
const unconfirmed = commandTracker.takeUnconfirmed();
|
|
1842
1871
|
if (unconfirmed.length > 0) {
|
|
@@ -4145,6 +4174,10 @@ async function claudeRemoteLauncher(session, onPermissionModeChange, onEffective
|
|
|
4145
4174
|
const parked = modeGate.takeParked();
|
|
4146
4175
|
if (parked) {
|
|
4147
4176
|
permissionHandler.handleModeChange(parked.mode.permissionMode);
|
|
4177
|
+
if (parked.finalized) {
|
|
4178
|
+
if (typeof parked.message === "string") onPromptFinalized?.(parked.message);
|
|
4179
|
+
return parked;
|
|
4180
|
+
}
|
|
4148
4181
|
if (typeof parked.message === "string") return { ...parked, message: await finalize(parked.message) };
|
|
4149
4182
|
return parked;
|
|
4150
4183
|
}
|
|
@@ -4271,13 +4304,32 @@ async function claudeRemoteLauncher(session, onPermissionModeChange, onEffective
|
|
|
4271
4304
|
if (plan.redeliver) {
|
|
4272
4305
|
redeliveredCommands.add(plan.redeliver.uuid);
|
|
4273
4306
|
logger.debug(`[remote]: re-sending unconfirmed user message ${plan.redeliver.uuid} into the next launch`);
|
|
4274
|
-
modeGate.park({ message: plan.redeliver.payload.message, mode: plan.redeliver.payload.mode, uuid: plan.redeliver.uuid });
|
|
4307
|
+
modeGate.park({ message: plan.redeliver.payload.message, mode: plan.redeliver.payload.mode, uuid: plan.redeliver.uuid, finalized: true });
|
|
4275
4308
|
}
|
|
4276
4309
|
if (plan.tombstone.length > 0) {
|
|
4277
4310
|
logger.debug(`[remote]: ${plan.tombstone.length} user message(s) never started before the query ended`);
|
|
4278
4311
|
session.client.sendQueueCancelReason(plan.tombstone, "aborted");
|
|
4279
4312
|
}
|
|
4280
4313
|
},
|
|
4314
|
+
// B-853: the Query's input closed while this message was in
|
|
4315
|
+
// hand — it never reached Claude Code. Run it first in the
|
|
4316
|
+
// next launch (it was pulled before anything still queued);
|
|
4317
|
+
// only when that slot is taken does the web get a tombstone
|
|
4318
|
+
// it can put back and resend, never silence. Leaving remote
|
|
4319
|
+
// mode is the user's stop (`aborted`); otherwise the Query
|
|
4320
|
+
// was replaced before it took the message (`restarted`).
|
|
4321
|
+
onUndeliveredMessage: (message) => {
|
|
4322
|
+
const parked = planUndeliveredMessage(message, { parkFree: !modeGate.hasParked, exiting: exitReason !== null });
|
|
4323
|
+
if (parked) {
|
|
4324
|
+
logger.debug("[remote]: pulled message missed its Query; replaying it in the next launch");
|
|
4325
|
+
modeGate.park(parked);
|
|
4326
|
+
} else if (message.uuid) {
|
|
4327
|
+
logger.debug(`[remote]: pulled message ${message.uuid} missed its Query and cannot be replayed`);
|
|
4328
|
+
session.client.sendQueueCancelReason([message.uuid], exitReason !== null ? "aborted" : "restarted");
|
|
4329
|
+
} else {
|
|
4330
|
+
logger.warn("[remote]: pulled message missed its Query and carries no uuid to tombstone");
|
|
4331
|
+
}
|
|
4332
|
+
},
|
|
4281
4333
|
onCommandsDropped: (uuids) => {
|
|
4282
4334
|
logger.debug(`[remote]: ${uuids.length} user message(s) never read before the turn ended`);
|
|
4283
4335
|
session.client.sendQueueCancelReason(uuids, "aborted");
|
|
@@ -4371,6 +4423,11 @@ async function claudeRemoteLauncher(session, onPermissionModeChange, onEffective
|
|
|
4371
4423
|
modeGate.reset();
|
|
4372
4424
|
}
|
|
4373
4425
|
}
|
|
4426
|
+
const stranded = modeGate.takeParked();
|
|
4427
|
+
if (stranded?.uuid) {
|
|
4428
|
+
logger.debug(`[remote]: leaving remote mode with parked message ${stranded.uuid}; tombstoning it`);
|
|
4429
|
+
session.client.sendQueueCancelReason([stranded.uuid], "aborted");
|
|
4430
|
+
}
|
|
4374
4431
|
} finally {
|
|
4375
4432
|
session.client.off("message", observeSessionRecord);
|
|
4376
4433
|
rewindReconciler.dispose();
|
|
@@ -4423,7 +4480,7 @@ async function loop(opts) {
|
|
|
4423
4480
|
logger.debug(`[loop] Iteration with mode: ${mode}`);
|
|
4424
4481
|
switch (mode) {
|
|
4425
4482
|
case "local": {
|
|
4426
|
-
const { claudeLocalLauncher } = await import('./claudeLocalLauncher-
|
|
4483
|
+
const { claudeLocalLauncher } = await import('./claudeLocalLauncher-D06QijMw.mjs');
|
|
4427
4484
|
const result = await claudeLocalLauncher(session);
|
|
4428
4485
|
switch (result.type) {
|
|
4429
4486
|
case "switch":
|
|
@@ -4764,7 +4821,7 @@ function registerSideQuestionHandler(rpc, deps) {
|
|
|
4764
4821
|
const retainMs = deps.retainMs ?? SIDE_QUESTION_RETAIN_MS;
|
|
4765
4822
|
const maxRunMs = deps.maxRunMs ?? SIDE_QUESTION_MAX_RUN_MS;
|
|
4766
4823
|
const fork = deps.run ?? (async (input) => {
|
|
4767
|
-
const { query } = await import('./index-
|
|
4824
|
+
const { query } = await import('./index-Db0HIC-k.mjs');
|
|
4768
4825
|
return runSideQuestion(query, input);
|
|
4769
4826
|
});
|
|
4770
4827
|
const run = async (input, live) => {
|