svamp-cli 0.2.244 → 0.2.246
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/{agentCommands-DvLTS2bk.mjs → agentCommands-wOdV4Do1.mjs} +5 -5
- package/dist/{auth-JDjru_js.mjs → auth-Bg0Z_bP-.mjs} +1 -1
- package/dist/cli.mjs +61 -61
- package/dist/{commands-CnVo5S8W.mjs → commands-BhLGBhBS.mjs} +1 -1
- package/dist/{commands-CRsGX1t1.mjs → commands-Bi_LZXPe.mjs} +1 -1
- package/dist/{commands-QyDnDry4.mjs → commands-CkduYG4a.mjs} +2 -2
- package/dist/{commands-Bt8pK8MS.mjs → commands-CniwP5Tm.mjs} +1 -1
- package/dist/{commands-jFRw1VYy.mjs → commands-CudvGpEz.mjs} +6 -6
- package/dist/{commands-CIa6EEAk.mjs → commands-D9khoYtI.mjs} +2 -2
- package/dist/{commands-DfTq3rS3.mjs → commands-Z8Ki8iA9.mjs} +1 -1
- package/dist/{fleet-gkqGOfvU.mjs → fleet-DCMPBC7b.mjs} +1 -1
- package/dist/{frpc-Dp9dDwDE.mjs → frpc-nvGz8fWs.mjs} +5 -2
- package/dist/{headlessCli-BIOe8SSK.mjs → headlessCli-d6XjdG6n.mjs} +2 -2
- package/dist/{httpServer-B1KVQJfm.mjs → httpServer-CSMZTpoh.mjs} +25 -3
- package/dist/index.mjs +1 -1
- package/dist/{package-mhgf18rF.mjs → package-CUTX-CB-.mjs} +4 -3
- package/dist/{rpc-Wp_ufnPT.mjs → rpc-CDI7i151.mjs} +2 -2
- package/dist/{rpc-CdbgL61q.mjs → rpc-s_Hibfpl.mjs} +1 -1
- package/dist/{run-BgPz-Shl.mjs → run-BPZ_1RCI.mjs} +20 -23
- package/dist/{run-hCQkcg9-.mjs → run-DRR6psuh.mjs} +1 -1
- package/dist/{runStore-BKgHQGNO.mjs → runStore-DKC_bMSi.mjs} +1 -1
- package/dist/{scheduler-BUo_8paQ.mjs → scheduler-E1Bw4HUY.mjs} +30 -4
- package/dist/{serveCommands-bEavErQo.mjs → serveCommands-Af_7qqzA.mjs} +5 -5
- package/dist/{serveManager-3zR_v1Xj.mjs → serveManager-DGRpRAFM.mjs} +36 -19
- package/dist/{sideband-l39JbmHM.mjs → sideband-C-0cCNeL.mjs} +1 -1
- package/package.json +4 -3
|
@@ -2,7 +2,7 @@ import { existsSync, readFileSync, mkdirSync, writeFileSync, renameSync } from '
|
|
|
2
2
|
import { join, dirname } from 'node:path';
|
|
3
3
|
import os from 'node:os';
|
|
4
4
|
import { requireNotSandboxed } from './sandboxDetect-DNTcbgWD.mjs';
|
|
5
|
-
import { A as shortId } from './run-
|
|
5
|
+
import { A as shortId } from './run-BPZ_1RCI.mjs';
|
|
6
6
|
import 'os';
|
|
7
7
|
import 'fs/promises';
|
|
8
8
|
import 'fs';
|
|
@@ -96,7 +96,7 @@ async function sessionSetTitle(title) {
|
|
|
96
96
|
}
|
|
97
97
|
async function sessionSetProjectDescription(description) {
|
|
98
98
|
const dir = process.cwd();
|
|
99
|
-
const { projectName, writeProjectInfo, sanitizeDescription, projectInfoPath } = await import('./run-
|
|
99
|
+
const { projectName, writeProjectInfo, sanitizeDescription, projectInfoPath } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.a9; });
|
|
100
100
|
const desc = sanitizeDescription(description, 240);
|
|
101
101
|
if (!desc) {
|
|
102
102
|
console.error("Project description is empty.");
|
|
@@ -327,7 +327,7 @@ async function sessionBroadcast(action, args) {
|
|
|
327
327
|
console.log(`Broadcast sent: ${action}`);
|
|
328
328
|
}
|
|
329
329
|
async function connectToMachineService() {
|
|
330
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
330
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
331
331
|
return connectAndGetMachine();
|
|
332
332
|
}
|
|
333
333
|
function buildInboxMessage(args) {
|
|
@@ -405,7 +405,7 @@ async function inboxSend(targetSessionId, opts) {
|
|
|
405
405
|
console.error("Message body is required.");
|
|
406
406
|
process.exit(1);
|
|
407
407
|
}
|
|
408
|
-
const { connectAndResolveSession } = await import('./commands-
|
|
408
|
+
const { connectAndResolveSession } = await import('./commands-BhLGBhBS.mjs');
|
|
409
409
|
let server;
|
|
410
410
|
try {
|
|
411
411
|
const { targetId, messageId } = await inboxSendCore(
|
|
@@ -459,7 +459,7 @@ async function inboxReply(messageId, body) {
|
|
|
459
459
|
console.error("SVAMP_SESSION_ID not set. This command must be run inside a Svamp session.");
|
|
460
460
|
process.exit(1);
|
|
461
461
|
}
|
|
462
|
-
const { connectAndResolveSession } = await import('./commands-
|
|
462
|
+
const { connectAndResolveSession } = await import('./commands-BhLGBhBS.mjs');
|
|
463
463
|
const { server: localServer, machine: localMachine } = await connectToMachineService();
|
|
464
464
|
let localDisconnected = false;
|
|
465
465
|
const disconnectLocal = async () => {
|
package/dist/cli.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { e as clearStopMarker, f as stopMarkerExists, s as startDaemon, b as stopDaemon, d as daemonStatus } from './run-
|
|
1
|
+
import { e as clearStopMarker, f as stopMarkerExists, s as startDaemon, b as stopDaemon, d as daemonStatus } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import { ensureSupervisorViaServiceManager, LAUNCHD_LABEL } from './serviceManager-hlOVxkhW.mjs';
|
|
3
3
|
import 'os';
|
|
4
4
|
import 'fs/promises';
|
|
@@ -34,7 +34,7 @@ const subcommand = args[0];
|
|
|
34
34
|
let daemonSubcommand = args[1];
|
|
35
35
|
async function main() {
|
|
36
36
|
try {
|
|
37
|
-
const { getLoadedConfig } = await import('./run-
|
|
37
|
+
const { getLoadedConfig } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.af; });
|
|
38
38
|
getLoadedConfig();
|
|
39
39
|
} catch {
|
|
40
40
|
}
|
|
@@ -51,7 +51,7 @@ async function main() {
|
|
|
51
51
|
console.error(`svamp daemon restart: ${err.message || err}`);
|
|
52
52
|
process.exit(1);
|
|
53
53
|
}
|
|
54
|
-
const { restartDaemon } = await import('./run-
|
|
54
|
+
const { restartDaemon } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ah; });
|
|
55
55
|
await restartDaemon();
|
|
56
56
|
process.exit(0);
|
|
57
57
|
}
|
|
@@ -344,7 +344,7 @@ async function main() {
|
|
|
344
344
|
console.error("svamp service: Service commands are not available in sandboxed sessions.");
|
|
345
345
|
process.exit(1);
|
|
346
346
|
}
|
|
347
|
-
const { handleServiceCommand } = await import('./commands-
|
|
347
|
+
const { handleServiceCommand } = await import('./commands-CudvGpEz.mjs');
|
|
348
348
|
await handleServiceCommand();
|
|
349
349
|
} else if (subcommand === "serve") {
|
|
350
350
|
const { isSandboxed: isSandboxedServe } = await import('./sandboxDetect-DNTcbgWD.mjs');
|
|
@@ -352,7 +352,7 @@ async function main() {
|
|
|
352
352
|
console.error("svamp serve: Serve commands are not available in sandboxed sessions.");
|
|
353
353
|
process.exit(1);
|
|
354
354
|
}
|
|
355
|
-
const { handleServeCommand } = await import('./serveCommands-
|
|
355
|
+
const { handleServeCommand } = await import('./serveCommands-Af_7qqzA.mjs');
|
|
356
356
|
await handleServeCommand();
|
|
357
357
|
process.exit(0);
|
|
358
358
|
} else if (subcommand === "process" || subcommand === "proc") {
|
|
@@ -361,7 +361,7 @@ async function main() {
|
|
|
361
361
|
console.error("svamp process: Process commands are not available in sandboxed sessions.");
|
|
362
362
|
process.exit(1);
|
|
363
363
|
}
|
|
364
|
-
const { processCommand } = await import('./commands-
|
|
364
|
+
const { processCommand } = await import('./commands-CkduYG4a.mjs');
|
|
365
365
|
let machineId;
|
|
366
366
|
const processArgs = args.slice(1);
|
|
367
367
|
const mIdx = processArgs.findIndex((a) => a === "--machine" || a === "-m");
|
|
@@ -375,18 +375,18 @@ async function main() {
|
|
|
375
375
|
}), machineId);
|
|
376
376
|
process.exit(0);
|
|
377
377
|
} else if (subcommand === "issue" || subcommand === "issues") {
|
|
378
|
-
const { issueCommand } = await import('./commands-
|
|
378
|
+
const { issueCommand } = await import('./commands-Bi_LZXPe.mjs');
|
|
379
379
|
await issueCommand(args.slice(1));
|
|
380
380
|
process.exit(0);
|
|
381
381
|
} else if (subcommand === "workflow" || subcommand === "workflows") {
|
|
382
|
-
const { workflowCommand } = await import('./commands-
|
|
382
|
+
const { workflowCommand } = await import('./commands-CniwP5Tm.mjs');
|
|
383
383
|
await workflowCommand(args.slice(1));
|
|
384
384
|
process.exit(0);
|
|
385
385
|
} else if (subcommand === "wise-agent" || subcommand === "wise") {
|
|
386
386
|
await handleWiseAgentCommand(args.slice(1));
|
|
387
387
|
process.exit(0);
|
|
388
388
|
} else if (subcommand === "feature" || subcommand === "crew") {
|
|
389
|
-
const { crewCommand } = await import('./commands-
|
|
389
|
+
const { crewCommand } = await import('./commands-D9khoYtI.mjs');
|
|
390
390
|
await crewCommand(args.slice(1));
|
|
391
391
|
process.exit(0);
|
|
392
392
|
} else if (subcommand === "--help" || subcommand === "-h") {
|
|
@@ -394,7 +394,7 @@ async function main() {
|
|
|
394
394
|
} else if (!subcommand || subcommand === "start") {
|
|
395
395
|
await handleInteractiveCommand();
|
|
396
396
|
} else if (subcommand === "--version" || subcommand === "-v") {
|
|
397
|
-
const pkg = await import('./package-
|
|
397
|
+
const pkg = await import('./package-CUTX-CB-.mjs').catch(() => ({ default: { version: "unknown" } }));
|
|
398
398
|
console.log(`svamp version: ${pkg.default.version}`);
|
|
399
399
|
} else {
|
|
400
400
|
console.error(`Unknown command: ${subcommand}`);
|
|
@@ -403,7 +403,7 @@ async function main() {
|
|
|
403
403
|
}
|
|
404
404
|
}
|
|
405
405
|
async function handleInteractiveCommand() {
|
|
406
|
-
const { runInteractive } = await import('./run-
|
|
406
|
+
const { runInteractive } = await import('./run-DRR6psuh.mjs');
|
|
407
407
|
const interactiveArgs = subcommand === "start" ? args.slice(1) : args;
|
|
408
408
|
let directory = process.cwd();
|
|
409
409
|
let resumeSessionId;
|
|
@@ -448,7 +448,7 @@ async function handleAgentCommand() {
|
|
|
448
448
|
return;
|
|
449
449
|
}
|
|
450
450
|
if (agentArgs[0] === "list") {
|
|
451
|
-
const { KNOWN_ACP_AGENTS, KNOWN_MCP_AGENTS: KNOWN_MCP_AGENTS2 } = await import('./run-
|
|
451
|
+
const { KNOWN_ACP_AGENTS, KNOWN_MCP_AGENTS: KNOWN_MCP_AGENTS2 } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ac; });
|
|
452
452
|
console.log("Known agents:");
|
|
453
453
|
for (const [name, config2] of Object.entries(KNOWN_ACP_AGENTS)) {
|
|
454
454
|
console.log(` ${name.padEnd(12)} ${config2.command} ${config2.args.join(" ")} (ACP)`);
|
|
@@ -460,7 +460,7 @@ async function handleAgentCommand() {
|
|
|
460
460
|
console.log('Use "svamp agent -- <command> [args]" for a custom ACP agent.');
|
|
461
461
|
return;
|
|
462
462
|
}
|
|
463
|
-
const { resolveAcpAgentConfig, KNOWN_MCP_AGENTS } = await import('./run-
|
|
463
|
+
const { resolveAcpAgentConfig, KNOWN_MCP_AGENTS } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ac; });
|
|
464
464
|
let cwd = process.cwd();
|
|
465
465
|
const filteredArgs = [];
|
|
466
466
|
for (let i = 0; i < agentArgs.length; i++) {
|
|
@@ -484,12 +484,12 @@ async function handleAgentCommand() {
|
|
|
484
484
|
console.log(`Starting ${config.agentName} agent in ${cwd}...`);
|
|
485
485
|
let backend;
|
|
486
486
|
if (KNOWN_MCP_AGENTS[config.agentName]) {
|
|
487
|
-
const { CodexMcpBackend } = await import('./run-
|
|
487
|
+
const { CodexMcpBackend } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ad; });
|
|
488
488
|
backend = new CodexMcpBackend({ cwd, log: logFn });
|
|
489
489
|
} else {
|
|
490
|
-
const { AcpBackend } = await import('./run-
|
|
491
|
-
const { GeminiTransport } = await import('./run-
|
|
492
|
-
const { DefaultTransport } = await import('./run-
|
|
490
|
+
const { AcpBackend } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ab; });
|
|
491
|
+
const { GeminiTransport } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ae; });
|
|
492
|
+
const { DefaultTransport } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.aa; });
|
|
493
493
|
const transportHandler = config.agentName === "gemini" ? new GeminiTransport() : new DefaultTransport(config.agentName);
|
|
494
494
|
backend = new AcpBackend({
|
|
495
495
|
agentName: config.agentName,
|
|
@@ -616,7 +616,7 @@ async function handleSessionCommand() {
|
|
|
616
616
|
process.exit(1);
|
|
617
617
|
}
|
|
618
618
|
}
|
|
619
|
-
const { sessionList, sessionWhoami, sessionSpawn, sessionArchive, sessionResume, sessionDelete, sessionInfo, sessionMessages, sessionAttach, sessionMachines, sessionSend, sessionWait, sessionShare, sessionLoopStart, sessionLoopCancel, sessionLoopStatus, sessionInboxSend, sessionInboxList, sessionInboxRead, sessionInboxReply, sessionInboxClear } = await import('./commands-
|
|
619
|
+
const { sessionList, sessionWhoami, sessionSpawn, sessionArchive, sessionResume, sessionDelete, sessionInfo, sessionMessages, sessionAttach, sessionMachines, sessionSend, sessionWait, sessionShare, sessionLoopStart, sessionLoopCancel, sessionLoopStatus, sessionInboxSend, sessionInboxList, sessionInboxRead, sessionInboxReply, sessionInboxClear } = await import('./commands-BhLGBhBS.mjs');
|
|
620
620
|
const parseFlagStr = (flag, shortFlag) => {
|
|
621
621
|
for (let i = 1; i < sessionArgs.length; i++) {
|
|
622
622
|
if ((sessionArgs[i] === flag || shortFlag) && i + 1 < sessionArgs.length) {
|
|
@@ -684,7 +684,7 @@ async function handleSessionCommand() {
|
|
|
684
684
|
allowDomain.push(sessionArgs[++i]);
|
|
685
685
|
}
|
|
686
686
|
}
|
|
687
|
-
const { parseShareArg } = await import('./commands-
|
|
687
|
+
const { parseShareArg } = await import('./commands-BhLGBhBS.mjs');
|
|
688
688
|
const shareEntries = share.map((s) => parseShareArg(s));
|
|
689
689
|
await sessionSpawn(agent, dir, targetMachineId, {
|
|
690
690
|
message,
|
|
@@ -772,7 +772,7 @@ async function handleSessionCommand() {
|
|
|
772
772
|
console.error(" Rewinds history: rewrites the message + drops everything after it, then restarts Claude.");
|
|
773
773
|
process.exit(1);
|
|
774
774
|
}
|
|
775
|
-
const { sessionEditMessage } = await import('./commands-
|
|
775
|
+
const { sessionEditMessage } = await import('./commands-BhLGBhBS.mjs');
|
|
776
776
|
await sessionEditMessage(sessionArgs[1], sessionArgs[2], sessionArgs[3], targetMachineId);
|
|
777
777
|
} else if (sessionSubcommand === "refine") {
|
|
778
778
|
if (!sessionArgs[1] || !sessionArgs[2]) {
|
|
@@ -780,7 +780,7 @@ async function handleSessionCommand() {
|
|
|
780
780
|
console.error(" Asks the agent to revise its latest reply in place (no extra round).");
|
|
781
781
|
process.exit(1);
|
|
782
782
|
}
|
|
783
|
-
const { sessionRefineLastReply } = await import('./commands-
|
|
783
|
+
const { sessionRefineLastReply } = await import('./commands-BhLGBhBS.mjs');
|
|
784
784
|
await sessionRefineLastReply(sessionArgs[1], sessionArgs[2], targetMachineId);
|
|
785
785
|
} else if (sessionSubcommand === "undo-edit" || sessionSubcommand === "undo") {
|
|
786
786
|
if (!sessionArgs[1]) {
|
|
@@ -788,7 +788,7 @@ async function handleSessionCommand() {
|
|
|
788
788
|
console.error(" Reverts the most recent edit/refine, restoring the pre-edit history.");
|
|
789
789
|
process.exit(1);
|
|
790
790
|
}
|
|
791
|
-
const { sessionUndoEdit } = await import('./commands-
|
|
791
|
+
const { sessionUndoEdit } = await import('./commands-BhLGBhBS.mjs');
|
|
792
792
|
await sessionUndoEdit(sessionArgs[1], targetMachineId);
|
|
793
793
|
} else if (sessionSubcommand === "query") {
|
|
794
794
|
const dir = sessionArgs[1];
|
|
@@ -798,7 +798,7 @@ async function handleSessionCommand() {
|
|
|
798
798
|
console.error(" Spawns a stateless Claude session in <directory>, sends <prompt>, prints the answer, then deletes the session.");
|
|
799
799
|
process.exit(1);
|
|
800
800
|
}
|
|
801
|
-
const { sessionQuery } = await import('./commands-
|
|
801
|
+
const { sessionQuery } = await import('./commands-BhLGBhBS.mjs');
|
|
802
802
|
await sessionQuery(dir, prompt, targetMachineId, {
|
|
803
803
|
timeout: parseFlagInt("--timeout"),
|
|
804
804
|
json: hasFlag("--json"),
|
|
@@ -831,7 +831,7 @@ async function handleSessionCommand() {
|
|
|
831
831
|
console.error("Usage: svamp session approve <session-id> [request-id] [--json]");
|
|
832
832
|
process.exit(1);
|
|
833
833
|
}
|
|
834
|
-
const { sessionApprove } = await import('./commands-
|
|
834
|
+
const { sessionApprove } = await import('./commands-BhLGBhBS.mjs');
|
|
835
835
|
const approveReqId = sessionArgs[2] && !sessionArgs[2].startsWith("--") ? sessionArgs[2] : void 0;
|
|
836
836
|
await sessionApprove(sessionArgs[1], approveReqId, targetMachineId, {
|
|
837
837
|
json: hasFlag("--json")
|
|
@@ -841,7 +841,7 @@ async function handleSessionCommand() {
|
|
|
841
841
|
console.error("Usage: svamp session deny <session-id> [request-id] [--json]");
|
|
842
842
|
process.exit(1);
|
|
843
843
|
}
|
|
844
|
-
const { sessionDeny } = await import('./commands-
|
|
844
|
+
const { sessionDeny } = await import('./commands-BhLGBhBS.mjs');
|
|
845
845
|
const denyReqId = sessionArgs[2] && !sessionArgs[2].startsWith("--") ? sessionArgs[2] : void 0;
|
|
846
846
|
await sessionDeny(sessionArgs[1], denyReqId, targetMachineId, {
|
|
847
847
|
json: hasFlag("--json")
|
|
@@ -886,7 +886,7 @@ async function handleSessionCommand() {
|
|
|
886
886
|
console.error("Usage: svamp session set-title <title>");
|
|
887
887
|
process.exit(1);
|
|
888
888
|
}
|
|
889
|
-
const { sessionSetTitle } = await import('./agentCommands-
|
|
889
|
+
const { sessionSetTitle } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
890
890
|
await sessionSetTitle(title);
|
|
891
891
|
} else if (sessionSubcommand === "set-project-description" || sessionSubcommand === "set-project") {
|
|
892
892
|
const desc = sessionArgs.slice(1).filter((a) => !a.startsWith("--")).join(" ");
|
|
@@ -894,7 +894,7 @@ async function handleSessionCommand() {
|
|
|
894
894
|
console.error("Usage: svamp session set-project-description <text>");
|
|
895
895
|
process.exit(1);
|
|
896
896
|
}
|
|
897
|
-
const { sessionSetProjectDescription } = await import('./agentCommands-
|
|
897
|
+
const { sessionSetProjectDescription } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
898
898
|
await sessionSetProjectDescription(desc);
|
|
899
899
|
} else if (sessionSubcommand === "set-link") {
|
|
900
900
|
const url = sessionArgs[1];
|
|
@@ -903,11 +903,11 @@ async function handleSessionCommand() {
|
|
|
903
903
|
process.exit(1);
|
|
904
904
|
}
|
|
905
905
|
const label = sessionArgs[2] && !sessionArgs[2].startsWith("--") ? sessionArgs[2] : void 0;
|
|
906
|
-
const { sessionSetLink } = await import('./agentCommands-
|
|
906
|
+
const { sessionSetLink } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
907
907
|
await sessionSetLink(url, label);
|
|
908
908
|
} else if (sessionSubcommand === "link") {
|
|
909
909
|
const op = sessionArgs[1];
|
|
910
|
-
const lm = await import('./agentCommands-
|
|
910
|
+
const lm = await import('./agentCommands-wOdV4Do1.mjs');
|
|
911
911
|
if (op === "add") {
|
|
912
912
|
const url = sessionArgs[2];
|
|
913
913
|
if (!url || url.startsWith("--")) {
|
|
@@ -942,7 +942,7 @@ async function handleSessionCommand() {
|
|
|
942
942
|
process.exit(1);
|
|
943
943
|
}
|
|
944
944
|
const level = parseFlagStr("--level") || "info";
|
|
945
|
-
const { sessionNotify } = await import('./agentCommands-
|
|
945
|
+
const { sessionNotify } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
946
946
|
await sessionNotify(message, level);
|
|
947
947
|
} else if (sessionSubcommand === "broadcast") {
|
|
948
948
|
const action = sessionArgs[1];
|
|
@@ -950,7 +950,7 @@ async function handleSessionCommand() {
|
|
|
950
950
|
console.error("Usage: svamp session broadcast <action> [args...]\nActions: open-canvas <url> [label], close-canvas, toast <message>");
|
|
951
951
|
process.exit(1);
|
|
952
952
|
}
|
|
953
|
-
const { sessionBroadcast } = await import('./agentCommands-
|
|
953
|
+
const { sessionBroadcast } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
954
954
|
await sessionBroadcast(action, sessionArgs.slice(2).filter((a) => !a.startsWith("--")));
|
|
955
955
|
} else if (sessionSubcommand === "inbox") {
|
|
956
956
|
const inboxSubcmd = sessionArgs[1];
|
|
@@ -961,7 +961,7 @@ async function handleSessionCommand() {
|
|
|
961
961
|
process.exit(1);
|
|
962
962
|
}
|
|
963
963
|
if (agentSessionId) {
|
|
964
|
-
const { inboxSend } = await import('./agentCommands-
|
|
964
|
+
const { inboxSend } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
965
965
|
await inboxSend(sessionArgs[2], {
|
|
966
966
|
body: sessionArgs[3],
|
|
967
967
|
subject: parseFlagStr("--subject"),
|
|
@@ -976,7 +976,7 @@ async function handleSessionCommand() {
|
|
|
976
976
|
}
|
|
977
977
|
} else if (inboxSubcmd === "list" || inboxSubcmd === "ls") {
|
|
978
978
|
if (agentSessionId && !sessionArgs[2]) {
|
|
979
|
-
const { inboxList } = await import('./agentCommands-
|
|
979
|
+
const { inboxList } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
980
980
|
await inboxList({
|
|
981
981
|
unread: hasFlag("--unread"),
|
|
982
982
|
limit: parseFlagInt("--limit"),
|
|
@@ -998,7 +998,7 @@ async function handleSessionCommand() {
|
|
|
998
998
|
process.exit(1);
|
|
999
999
|
}
|
|
1000
1000
|
if (agentSessionId && !sessionArgs[3]) {
|
|
1001
|
-
const { inboxList } = await import('./agentCommands-
|
|
1001
|
+
const { inboxList } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
1002
1002
|
await sessionInboxRead(agentSessionId, sessionArgs[2], targetMachineId);
|
|
1003
1003
|
} else if (sessionArgs[3]) {
|
|
1004
1004
|
await sessionInboxRead(sessionArgs[2], sessionArgs[3], targetMachineId);
|
|
@@ -1008,7 +1008,7 @@ async function handleSessionCommand() {
|
|
|
1008
1008
|
}
|
|
1009
1009
|
} else if (inboxSubcmd === "reply") {
|
|
1010
1010
|
if (agentSessionId && sessionArgs[2] && sessionArgs[3] && !sessionArgs[4]) {
|
|
1011
|
-
const { inboxReply } = await import('./agentCommands-
|
|
1011
|
+
const { inboxReply } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
1012
1012
|
await inboxReply(sessionArgs[2], sessionArgs[3]);
|
|
1013
1013
|
} else if (sessionArgs[2] && sessionArgs[3] && sessionArgs[4]) {
|
|
1014
1014
|
await sessionInboxReply(sessionArgs[2], sessionArgs[3], sessionArgs[4], targetMachineId);
|
|
@@ -1046,7 +1046,7 @@ async function handleMachineCommand() {
|
|
|
1046
1046
|
return;
|
|
1047
1047
|
}
|
|
1048
1048
|
if (machineSubcommand === "share") {
|
|
1049
|
-
const { machineShare } = await import('./commands-
|
|
1049
|
+
const { machineShare } = await import('./commands-BhLGBhBS.mjs');
|
|
1050
1050
|
let machineId;
|
|
1051
1051
|
const shareArgs = [];
|
|
1052
1052
|
for (let i = 1; i < machineArgs.length; i++) {
|
|
@@ -1097,14 +1097,14 @@ async function handleMachineCommand() {
|
|
|
1097
1097
|
process.exit(1);
|
|
1098
1098
|
}
|
|
1099
1099
|
if (all) {
|
|
1100
|
-
const { fleetExec } = await import('./fleet-
|
|
1100
|
+
const { fleetExec } = await import('./fleet-DCMPBC7b.mjs');
|
|
1101
1101
|
await fleetExec(command, { cwd });
|
|
1102
1102
|
} else {
|
|
1103
|
-
const { machineExec } = await import('./commands-
|
|
1103
|
+
const { machineExec } = await import('./commands-BhLGBhBS.mjs');
|
|
1104
1104
|
await machineExec(machineId, command, cwd);
|
|
1105
1105
|
}
|
|
1106
1106
|
} else if (machineSubcommand === "info") {
|
|
1107
|
-
const { machineInfo } = await import('./commands-
|
|
1107
|
+
const { machineInfo } = await import('./commands-BhLGBhBS.mjs');
|
|
1108
1108
|
let machineId;
|
|
1109
1109
|
for (let i = 1; i < machineArgs.length; i++) {
|
|
1110
1110
|
if ((machineArgs[i] === "--machine" || machineArgs[i] === "-m") && i + 1 < machineArgs.length) {
|
|
@@ -1124,10 +1124,10 @@ async function handleMachineCommand() {
|
|
|
1124
1124
|
level = machineArgs[++i];
|
|
1125
1125
|
}
|
|
1126
1126
|
}
|
|
1127
|
-
const { machineNotify } = await import('./agentCommands-
|
|
1127
|
+
const { machineNotify } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
1128
1128
|
await machineNotify(message, level);
|
|
1129
1129
|
} else if (machineSubcommand === "ls") {
|
|
1130
|
-
const { machineLs } = await import('./commands-
|
|
1130
|
+
const { machineLs } = await import('./commands-BhLGBhBS.mjs');
|
|
1131
1131
|
let machineId;
|
|
1132
1132
|
let showHidden = false;
|
|
1133
1133
|
let path;
|
|
@@ -1183,20 +1183,20 @@ Examples:
|
|
|
1183
1183
|
};
|
|
1184
1184
|
const hasFlag = (name) => fleetArgs.includes(`--${name}`);
|
|
1185
1185
|
if (sub === "status") {
|
|
1186
|
-
const { fleetStatus } = await import('./fleet-
|
|
1186
|
+
const { fleetStatus } = await import('./fleet-DCMPBC7b.mjs');
|
|
1187
1187
|
await fleetStatus();
|
|
1188
1188
|
} else if (sub === "upgrade-claude") {
|
|
1189
|
-
const { fleetUpgradeClaude } = await import('./fleet-
|
|
1189
|
+
const { fleetUpgradeClaude } = await import('./fleet-DCMPBC7b.mjs');
|
|
1190
1190
|
await fleetUpgradeClaude({ version: flag("version", "-v") });
|
|
1191
1191
|
} else if (sub === "upgrade-svamp") {
|
|
1192
|
-
const { fleetUpgradeSvamp } = await import('./fleet-
|
|
1192
|
+
const { fleetUpgradeSvamp } = await import('./fleet-DCMPBC7b.mjs');
|
|
1193
1193
|
await fleetUpgradeSvamp({ version: flag("version", "-v"), excludeSelf: hasFlag("exclude-self") });
|
|
1194
1194
|
} else if (sub === "daemon-restart") {
|
|
1195
|
-
const { fleetDaemonRestart } = await import('./fleet-
|
|
1195
|
+
const { fleetDaemonRestart } = await import('./fleet-DCMPBC7b.mjs');
|
|
1196
1196
|
await fleetDaemonRestart({ graceful: !hasFlag("cleanup") });
|
|
1197
1197
|
} else if (sub === "push-skill") {
|
|
1198
1198
|
const name = fleetArgs[1];
|
|
1199
|
-
const { fleetPushSkill } = await import('./fleet-
|
|
1199
|
+
const { fleetPushSkill } = await import('./fleet-DCMPBC7b.mjs');
|
|
1200
1200
|
await fleetPushSkill(name);
|
|
1201
1201
|
} else {
|
|
1202
1202
|
console.error(`Unknown fleet subcommand: ${sub}`);
|
|
@@ -1212,7 +1212,7 @@ async function handleSkillsCommand() {
|
|
|
1212
1212
|
await printSkillsHelp();
|
|
1213
1213
|
return;
|
|
1214
1214
|
}
|
|
1215
|
-
const { skillsFind, skillsInstall, skillsList, skillsRemove, skillsPublish } = await import('./commands-
|
|
1215
|
+
const { skillsFind, skillsInstall, skillsList, skillsRemove, skillsPublish } = await import('./commands-Z8Ki8iA9.mjs');
|
|
1216
1216
|
if (skillsSubcommand === "find" || skillsSubcommand === "search") {
|
|
1217
1217
|
const query = skillsArgs.slice(1).filter((a) => !a.startsWith("--")).join(" ");
|
|
1218
1218
|
if (!query) {
|
|
@@ -1259,7 +1259,7 @@ async function loginToHypha() {
|
|
|
1259
1259
|
process.exit(1);
|
|
1260
1260
|
}
|
|
1261
1261
|
const anchor = anchorArg.replace(/\/+$/, "");
|
|
1262
|
-
const { loadInstanceConfig } = await import('./run-
|
|
1262
|
+
const { loadInstanceConfig } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.af; });
|
|
1263
1263
|
let cfg = null;
|
|
1264
1264
|
try {
|
|
1265
1265
|
cfg = await loadInstanceConfig({ anchor, force: true });
|
|
@@ -1370,7 +1370,7 @@ async function logoutFromHypha() {
|
|
|
1370
1370
|
} catch {
|
|
1371
1371
|
}
|
|
1372
1372
|
try {
|
|
1373
|
-
const { clearInstanceConfigCache } = await import('./run-
|
|
1373
|
+
const { clearInstanceConfigCache } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.af; });
|
|
1374
1374
|
clearInstanceConfigCache();
|
|
1375
1375
|
} catch {
|
|
1376
1376
|
}
|
|
@@ -1708,7 +1708,7 @@ async function applyClaudeAuthFlags(argv) {
|
|
|
1708
1708
|
"--use-hypha-proxy, --use-claude-login, and --anthropic-base-url/--anthropic-api-key are mutually exclusive"
|
|
1709
1709
|
);
|
|
1710
1710
|
}
|
|
1711
|
-
const mod = await import('./run-
|
|
1711
|
+
const mod = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.a8; });
|
|
1712
1712
|
if (hasHypha) {
|
|
1713
1713
|
let url;
|
|
1714
1714
|
const hyphaIdx = argv.indexOf("--use-hypha-proxy");
|
|
@@ -1762,7 +1762,7 @@ async function applyDaemonShareFlag(argv) {
|
|
|
1762
1762
|
}
|
|
1763
1763
|
}
|
|
1764
1764
|
if (collected.length === 0) return;
|
|
1765
|
-
const { updateEnvFile } = await import('./run-
|
|
1765
|
+
const { updateEnvFile } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.a8; });
|
|
1766
1766
|
const seen = /* @__PURE__ */ new Set();
|
|
1767
1767
|
const deduped = collected.filter((e) => {
|
|
1768
1768
|
const k = e.toLowerCase();
|
|
@@ -1795,7 +1795,7 @@ async function handleWiseAgentCommand(rest) {
|
|
|
1795
1795
|
}
|
|
1796
1796
|
});
|
|
1797
1797
|
const message = rest.slice(1).map((a, idx) => ({ a, idx: idx + 1 })).filter(({ a, idx }) => !a.startsWith("-") && !consumed.has(String(idx))).map(({ a }) => a).join(" ");
|
|
1798
|
-
const { wiseAskCli } = await import('./commands-
|
|
1798
|
+
const { wiseAskCli } = await import('./commands-BhLGBhBS.mjs');
|
|
1799
1799
|
await wiseAskCli(machineId, message, sessionId, { json });
|
|
1800
1800
|
return;
|
|
1801
1801
|
}
|
|
@@ -1807,7 +1807,7 @@ async function handleWiseAgentCommand(rest) {
|
|
|
1807
1807
|
}
|
|
1808
1808
|
return void 0;
|
|
1809
1809
|
};
|
|
1810
|
-
const { runWiseVoiceCli } = await import('./headlessCli-
|
|
1810
|
+
const { runWiseVoiceCli } = await import('./headlessCli-d6XjdG6n.mjs');
|
|
1811
1811
|
await runWiseVoiceCli({ voice: valueOf(["--voice"]), wakeKeywordPath: valueOf(["--wake"]), model: valueOf(["--model"]) });
|
|
1812
1812
|
return;
|
|
1813
1813
|
}
|
|
@@ -1825,7 +1825,7 @@ async function handleWiseAgentCommand(rest) {
|
|
|
1825
1825
|
const mode = valueOf(["--mode"]);
|
|
1826
1826
|
const mission = valueOf(["--mission"]);
|
|
1827
1827
|
const url = rest.slice(1).find((a) => /^https?:\/\//.test(a)) || "";
|
|
1828
|
-
const { wiseJoinMeetingCli } = await import('./commands-
|
|
1828
|
+
const { wiseJoinMeetingCli } = await import('./commands-BhLGBhBS.mjs');
|
|
1829
1829
|
await wiseJoinMeetingCli(machineId, url, sessionId, { json, mode, mission });
|
|
1830
1830
|
return;
|
|
1831
1831
|
}
|
|
@@ -1837,7 +1837,7 @@ async function handleWiseAgentCommand(rest) {
|
|
|
1837
1837
|
}
|
|
1838
1838
|
return void 0;
|
|
1839
1839
|
};
|
|
1840
|
-
const { wiseLeaveMeetingCli } = await import('./commands-
|
|
1840
|
+
const { wiseLeaveMeetingCli } = await import('./commands-BhLGBhBS.mjs');
|
|
1841
1841
|
await wiseLeaveMeetingCli(valueOf(["--machine", "-m"]), valueOf(["--session", "-s"]), { json: rest.includes("--json") });
|
|
1842
1842
|
return;
|
|
1843
1843
|
}
|
|
@@ -1861,7 +1861,7 @@ async function handleWiseAgentCommand(rest) {
|
|
|
1861
1861
|
}
|
|
1862
1862
|
});
|
|
1863
1863
|
const text = rest.slice(1).map((a, idx) => ({ a, idx: idx + 1 })).filter(({ a, idx }) => !a.startsWith("-") && !consumed.has(String(idx))).map(({ a }) => a).join(" ");
|
|
1864
|
-
const { wiseAnnounceCli } = await import('./commands-
|
|
1864
|
+
const { wiseAnnounceCli } = await import('./commands-BhLGBhBS.mjs');
|
|
1865
1865
|
await wiseAnnounceCli(machineId, text, sessionId, { json });
|
|
1866
1866
|
return;
|
|
1867
1867
|
}
|
|
@@ -1873,7 +1873,7 @@ async function handleWiseAgentCommand(rest) {
|
|
|
1873
1873
|
}
|
|
1874
1874
|
return void 0;
|
|
1875
1875
|
};
|
|
1876
|
-
const { wiseMeetingsCli } = await import('./commands-
|
|
1876
|
+
const { wiseMeetingsCli } = await import('./commands-BhLGBhBS.mjs');
|
|
1877
1877
|
await wiseMeetingsCli(valueOf(["--machine", "-m"]), { json: rest.includes("--json") });
|
|
1878
1878
|
return;
|
|
1879
1879
|
}
|
|
@@ -1923,7 +1923,7 @@ If none is set, hitting a WISE Agent channel returns a clear "not configured" er
|
|
|
1923
1923
|
return;
|
|
1924
1924
|
}
|
|
1925
1925
|
const authArgs = rest.slice(1);
|
|
1926
|
-
const mod = await import('./auth-
|
|
1926
|
+
const mod = await import('./auth-Bg0Z_bP-.mjs');
|
|
1927
1927
|
let action;
|
|
1928
1928
|
try {
|
|
1929
1929
|
action = mod.parseWiseAgentAuthArgs(authArgs);
|
|
@@ -1933,7 +1933,7 @@ If none is set, hitting a WISE Agent channel returns a clear "not configured" er
|
|
|
1933
1933
|
return;
|
|
1934
1934
|
}
|
|
1935
1935
|
if (action) {
|
|
1936
|
-
const { updateEnvFile } = await import('./run-
|
|
1936
|
+
const { updateEnvFile } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.a8; });
|
|
1937
1937
|
const updates = mod.buildWiseAgentEnvUpdates(action);
|
|
1938
1938
|
updateEnvFile(updates);
|
|
1939
1939
|
for (const [k, v] of Object.entries(updates)) {
|
|
@@ -1947,7 +1947,7 @@ If none is set, hitting a WISE Agent channel returns a clear "not configured" er
|
|
|
1947
1947
|
}
|
|
1948
1948
|
async function handleDaemonAuthCommand(argv) {
|
|
1949
1949
|
const sub = (argv[0] || "status").toLowerCase();
|
|
1950
|
-
const mod = await import('./run-
|
|
1950
|
+
const mod = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.a8; });
|
|
1951
1951
|
if (sub === "--help" || sub === "-h" || sub === "help") {
|
|
1952
1952
|
console.log(`
|
|
1953
1953
|
svamp daemon auth \u2014 Configure how Claude subprocesses authenticate
|
|
@@ -2261,7 +2261,7 @@ Examples:
|
|
|
2261
2261
|
async function printSkillsHelp() {
|
|
2262
2262
|
let browseUrl = "<HYPHA_SERVER_URL>/<workspace>/artifacts/marketplace (set HYPHA_SERVER_URL)";
|
|
2263
2263
|
try {
|
|
2264
|
-
const { getArtifactBaseUrl, getSkillsCollectionName } = await import('./run-
|
|
2264
|
+
const { getArtifactBaseUrl, getSkillsCollectionName } = await import('./run-BPZ_1RCI.mjs').then(function (n) { return n.ag; });
|
|
2265
2265
|
browseUrl = `${getArtifactBaseUrl()}/${getSkillsCollectionName()}`;
|
|
2266
2266
|
} catch {
|
|
2267
2267
|
}
|
|
@@ -2,7 +2,7 @@ import { existsSync, readFileSync, writeFileSync } from 'node:fs';
|
|
|
2
2
|
import { execSync } from 'node:child_process';
|
|
3
3
|
import { basename, resolve, join, isAbsolute } from 'node:path';
|
|
4
4
|
import os from 'node:os';
|
|
5
|
-
import { Q as formatHandle, T as normalizeAllowedUser, U as loadSecurityContextConfig, V as resolveSecurityContext, W as buildSecurityContextFromFlags, X as mergeSecurityContexts, c as connectToHypha, Y as buildSessionShareUrl, Z as computeOutboundHop, A as shortId, _ as registerAwaitingReply, $ as buildMachineShareUrl, a0 as parseHandle, a1 as handleMatchesMetadata } from './run-
|
|
5
|
+
import { Q as formatHandle, T as normalizeAllowedUser, U as loadSecurityContextConfig, V as resolveSecurityContext, W as buildSecurityContextFromFlags, X as mergeSecurityContexts, c as connectToHypha, Y as buildSessionShareUrl, Z as computeOutboundHop, A as shortId, _ as registerAwaitingReply, $ as buildMachineShareUrl, a0 as parseHandle, a1 as handleMatchesMetadata } from './run-BPZ_1RCI.mjs';
|
|
6
6
|
import 'os';
|
|
7
7
|
import 'fs/promises';
|
|
8
8
|
import 'fs';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { execSync } from 'node:child_process';
|
|
2
2
|
import { existsSync, readFileSync } from 'node:fs';
|
|
3
3
|
import { join } from 'node:path';
|
|
4
|
-
import { m as resolveProjectRoot, w as searchIssues, v as listIssues, o as resumeIssue, p as pauseIssue, q as addComment, u as updateIssue, n as getIssue, x as isVisibleTo, z as summarize, t as addIssue } from './run-
|
|
4
|
+
import { m as resolveProjectRoot, w as searchIssues, v as listIssues, o as resumeIssue, p as pauseIssue, q as addComment, u as updateIssue, n as getIssue, x as isVisibleTo, z as summarize, t as addIssue } from './run-BPZ_1RCI.mjs';
|
|
5
5
|
import 'os';
|
|
6
6
|
import 'fs/promises';
|
|
7
7
|
import 'fs';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { writeFileSync, readFileSync } from 'fs';
|
|
2
2
|
import { resolve } from 'path';
|
|
3
|
-
import { connectAndGetMachine } from './commands-
|
|
3
|
+
import { connectAndGetMachine } from './commands-BhLGBhBS.mjs';
|
|
4
4
|
import 'node:fs';
|
|
5
5
|
import 'node:child_process';
|
|
6
6
|
import 'node:path';
|
|
7
7
|
import 'node:os';
|
|
8
|
-
import './run-
|
|
8
|
+
import './run-BPZ_1RCI.mjs';
|
|
9
9
|
import 'os';
|
|
10
10
|
import 'fs/promises';
|
|
11
11
|
import 'url';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { spawnSync } from 'node:child_process';
|
|
2
|
-
import { m as resolveProjectRoot } from './run-
|
|
2
|
+
import { m as resolveProjectRoot } from './run-BPZ_1RCI.mjs';
|
|
3
3
|
import { c as workflowSteps, s as setWorkflowEnabled, i as isWorkflowEnabled, r as removeWorkflow, g as getWorkflow, l as listWorkflows, a as saveWorkflow, b as rawWorkflow } from './store-BTs0H_y0.mjs';
|
|
4
4
|
import 'os';
|
|
5
5
|
import 'fs/promises';
|
|
@@ -58,7 +58,7 @@ async function serviceExpose(args) {
|
|
|
58
58
|
process.exit(1);
|
|
59
59
|
}
|
|
60
60
|
if (foreground) {
|
|
61
|
-
const { runFrpcTunnel } = await import('./frpc-
|
|
61
|
+
const { runFrpcTunnel } = await import('./frpc-nvGz8fWs.mjs');
|
|
62
62
|
await runFrpcTunnel(name, ports, void 0, {
|
|
63
63
|
group,
|
|
64
64
|
groupKey,
|
|
@@ -68,7 +68,7 @@ async function serviceExpose(args) {
|
|
|
68
68
|
});
|
|
69
69
|
return;
|
|
70
70
|
}
|
|
71
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
71
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
72
72
|
const { server, machine } = await connectAndGetMachine();
|
|
73
73
|
try {
|
|
74
74
|
const status = await machine.tunnelStart({
|
|
@@ -90,7 +90,7 @@ async function serviceExpose(args) {
|
|
|
90
90
|
console.log(` port ${port}: ${url}`);
|
|
91
91
|
}
|
|
92
92
|
if (process.env.SVAMP_SESSION_ID) {
|
|
93
|
-
const { autoAddSessionLink } = await import('./agentCommands-
|
|
93
|
+
const { autoAddSessionLink } = await import('./agentCommands-wOdV4Do1.mjs');
|
|
94
94
|
let added = 0;
|
|
95
95
|
for (const [port, url] of urlEntries) {
|
|
96
96
|
const label = urlEntries.length > 1 ? `${name}:${port}` : name;
|
|
@@ -136,7 +136,7 @@ async function serviceServe(args) {
|
|
|
136
136
|
};
|
|
137
137
|
process.on("SIGINT", cleanup);
|
|
138
138
|
process.on("SIGTERM", cleanup);
|
|
139
|
-
const { runFrpcTunnel } = await import('./frpc-
|
|
139
|
+
const { runFrpcTunnel } = await import('./frpc-nvGz8fWs.mjs');
|
|
140
140
|
await runFrpcTunnel(name, [caddyPort]);
|
|
141
141
|
} catch (err) {
|
|
142
142
|
console.error(`Error serving directory: ${err.message}`);
|
|
@@ -145,7 +145,7 @@ async function serviceServe(args) {
|
|
|
145
145
|
}
|
|
146
146
|
async function serviceList(_args) {
|
|
147
147
|
try {
|
|
148
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
148
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
149
149
|
const { server, machine } = await connectAndGetMachine();
|
|
150
150
|
try {
|
|
151
151
|
const tunnels = await machine.tunnelList({});
|
|
@@ -185,7 +185,7 @@ async function serviceDelete(args) {
|
|
|
185
185
|
process.exit(1);
|
|
186
186
|
}
|
|
187
187
|
try {
|
|
188
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
188
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
189
189
|
const { server, machine } = await connectAndGetMachine();
|
|
190
190
|
try {
|
|
191
191
|
await machine.tunnelStop({ name });
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { existsSync } from 'node:fs';
|
|
2
2
|
import { resolve } from 'node:path';
|
|
3
|
-
import { connectAndGetMachine, resolveSessionId, createWorktree, connectAndResolveSession } from './commands-
|
|
3
|
+
import { connectAndGetMachine, resolveSessionId, createWorktree, connectAndResolveSession } from './commands-BhLGBhBS.mjs';
|
|
4
4
|
import { execSync } from 'node:child_process';
|
|
5
|
-
import { u as updateIssue, q as addComment, t as addIssue, A as shortId } from './run-
|
|
5
|
+
import { u as updateIssue, q as addComment, t as addIssue, A as shortId } from './run-BPZ_1RCI.mjs';
|
|
6
6
|
import 'node:os';
|
|
7
7
|
import 'os';
|
|
8
8
|
import 'fs/promises';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import os from 'os';
|
|
2
2
|
import fs__default from 'fs';
|
|
3
3
|
import { resolve, join, relative } from 'path';
|
|
4
|
-
import { F as parseFrontmatter, G as getSkillsServer, H as getSkillsWorkspaceName, I as getSkillsCollectionName, J as fetchWithTimeout, K as searchSkills, L as SKILLS_DIR, M as getSkillInfo, N as downloadSkillFile, O as listSkillFiles } from './run-
|
|
4
|
+
import { F as parseFrontmatter, G as getSkillsServer, H as getSkillsWorkspaceName, I as getSkillsCollectionName, J as fetchWithTimeout, K as searchSkills, L as SKILLS_DIR, M as getSkillInfo, N as downloadSkillFile, O as listSkillFiles } from './run-BPZ_1RCI.mjs';
|
|
5
5
|
import 'fs/promises';
|
|
6
6
|
import 'url';
|
|
7
7
|
import 'child_process';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { existsSync, readFileSync } from 'node:fs';
|
|
2
2
|
import { join } from 'node:path';
|
|
3
3
|
import os from 'node:os';
|
|
4
|
-
import { c as connectToHypha } from './run-
|
|
4
|
+
import { c as connectToHypha } from './run-BPZ_1RCI.mjs';
|
|
5
5
|
import { PINNED_CLAUDE_CODE_VERSION } from './pinnedClaudeCode-ivV7xAp3.mjs';
|
|
6
6
|
import 'os';
|
|
7
7
|
import 'fs/promises';
|
|
@@ -4,7 +4,7 @@ import { mkdirSync, writeFileSync, unlinkSync, existsSync, chmodSync, readFileSy
|
|
|
4
4
|
import { join } from 'path';
|
|
5
5
|
import { homedir, platform, arch } from 'os';
|
|
6
6
|
import { randomUUID, createHash } from 'crypto';
|
|
7
|
-
import { h as getFrpsSubdomainHost, i as getFrpsServerPort, j as getFrpsServerAddr } from './run-
|
|
7
|
+
import { h as getFrpsSubdomainHost, i as getFrpsServerPort, j as getFrpsServerAddr } from './run-BPZ_1RCI.mjs';
|
|
8
8
|
import 'fs/promises';
|
|
9
9
|
import 'url';
|
|
10
10
|
import 'node:crypto';
|
|
@@ -339,7 +339,6 @@ class FrpcTunnel {
|
|
|
339
339
|
if (!this._connected) {
|
|
340
340
|
this._connected = true;
|
|
341
341
|
this._lastConnectedAt = Date.now();
|
|
342
|
-
this._restartAttempts = 0;
|
|
343
342
|
this._consecutiveErrors = 0;
|
|
344
343
|
this._firstErrorAt = 0;
|
|
345
344
|
this.options.onConnect?.();
|
|
@@ -375,6 +374,10 @@ class FrpcTunnel {
|
|
|
375
374
|
reject(new Error(`frpc exited with code ${code}`));
|
|
376
375
|
}
|
|
377
376
|
if (!this._destroyed && code !== 0) {
|
|
377
|
+
const STABILITY_WINDOW_MS = 3e4;
|
|
378
|
+
if (this._lastConnectedAt > 0 && Date.now() - this._lastConnectedAt >= STABILITY_WINDOW_MS) {
|
|
379
|
+
this._restartAttempts = 0;
|
|
380
|
+
}
|
|
378
381
|
this._restartAttempts++;
|
|
379
382
|
const delay = Math.min(3e3 * Math.pow(2, this._restartAttempts - 1), 6e4);
|
|
380
383
|
this.log(`frpc exited with code ${code}, restarting in ${Math.round(delay / 1e3)}s (attempt ${this._restartAttempts})...`);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { P as resolveModel, a2 as describeMisconfiguration, a3 as buildMachineDeps } from './run-
|
|
2
|
-
import { handleRealtimeEvent, initMachineVoiceSession } from './sideband-
|
|
1
|
+
import { P as resolveModel, a2 as describeMisconfiguration, a3 as buildMachineDeps } from './run-BPZ_1RCI.mjs';
|
|
2
|
+
import { handleRealtimeEvent, initMachineVoiceSession } from './sideband-C-0cCNeL.mjs';
|
|
3
3
|
import { WebSocket } from 'ws';
|
|
4
4
|
import { execSync, spawn } from 'child_process';
|
|
5
5
|
import 'os';
|
|
@@ -86,7 +86,8 @@ function createChannelHttpServer(deps) {
|
|
|
86
86
|
}
|
|
87
87
|
m = u.pathname.match(/^\/channel\/([\w.-]+)\/events$/);
|
|
88
88
|
if (m) {
|
|
89
|
-
const
|
|
89
|
+
const cid = m[1];
|
|
90
|
+
let rpc2 = await findOwner(deps, cid);
|
|
90
91
|
if (!rpc2?.channelReceive) {
|
|
91
92
|
res.writeHead(404).end("not found");
|
|
92
93
|
return;
|
|
@@ -100,8 +101,25 @@ function createChannelHttpServer(deps) {
|
|
|
100
101
|
req.on("close", () => {
|
|
101
102
|
closed = true;
|
|
102
103
|
});
|
|
104
|
+
const MIN_LOOP_MS = 1e3;
|
|
103
105
|
while (!closed) {
|
|
104
|
-
const
|
|
106
|
+
const started = Date.now();
|
|
107
|
+
let out;
|
|
108
|
+
try {
|
|
109
|
+
out = await rpc2.channelReceive({ channel: cid, key, from, cursor, wait: 25 });
|
|
110
|
+
} catch (e) {
|
|
111
|
+
const re = await findOwner(deps, cid).catch(() => null);
|
|
112
|
+
if (re?.channelReceive && !closed) {
|
|
113
|
+
rpc2 = re;
|
|
114
|
+
await new Promise((r) => setTimeout(r, MIN_LOOP_MS));
|
|
115
|
+
continue;
|
|
116
|
+
}
|
|
117
|
+
res.write(`event: error
|
|
118
|
+
data: ${JSON.stringify({ error: e?.message || String(e) })}
|
|
119
|
+
|
|
120
|
+
`);
|
|
121
|
+
break;
|
|
122
|
+
}
|
|
105
123
|
if (out?.error) {
|
|
106
124
|
res.write(`event: error
|
|
107
125
|
data: ${JSON.stringify({ error: out.error })}
|
|
@@ -113,7 +131,11 @@ data: ${JSON.stringify({ error: out.error })}
|
|
|
113
131
|
|
|
114
132
|
`);
|
|
115
133
|
cursor = out.cursor ?? cursor;
|
|
116
|
-
if (!(out.replies || []).length)
|
|
134
|
+
if (!(out.replies || []).length) {
|
|
135
|
+
res.write(": keepalive\n\n");
|
|
136
|
+
const elapsed = Date.now() - started;
|
|
137
|
+
if (elapsed < MIN_LOOP_MS) await new Promise((r) => setTimeout(r, MIN_LOOP_MS - elapsed));
|
|
138
|
+
}
|
|
117
139
|
}
|
|
118
140
|
try {
|
|
119
141
|
res.end();
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { c as connectToHypha, a as createSessionStore, d as daemonStatus, g as getHyphaServerUrl, r as registerMachineService, s as startDaemon, b as stopDaemon } from './run-
|
|
1
|
+
export { c as connectToHypha, a as createSessionStore, d as daemonStatus, g as getHyphaServerUrl, r as registerMachineService, s as startDaemon, b as stopDaemon } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import 'os';
|
|
3
3
|
import 'fs/promises';
|
|
4
4
|
import 'fs';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var name = "svamp-cli";
|
|
2
|
-
var version = "0.2.
|
|
2
|
+
var version = "0.2.246";
|
|
3
3
|
var description = "Svamp CLI — AI workspace daemon on Hypha Cloud";
|
|
4
4
|
var author = "Amun AI AB";
|
|
5
5
|
var license = "SEE LICENSE IN LICENSE";
|
|
@@ -19,12 +19,13 @@ var exports$1 = {
|
|
|
19
19
|
var scripts = {
|
|
20
20
|
build: "rm -rf dist bin/skills bin/commands && mkdir -p bin/skills && cp -r ../../skills/artifact bin/skills/artifact && cp -r ../../skills/crew bin/skills/crew && cp -r ../../commands bin/commands && tsc --noEmit && pkgroll",
|
|
21
21
|
typecheck: "tsc --noEmit",
|
|
22
|
-
test: "npx tsx test/test-context-window.mjs && npx tsx test/test-ratelimit-retry.mjs && npx tsx test/test-instance-config.mjs && npx tsx test/test-authorize.mjs && npx tsx test/test-normalize-allowed-user.mjs && npx tsx test/test-share-url.mjs && npx tsx test/test-update-sharing-normalization.mjs && npx tsx test/test-sharing-notify-sync.mjs && npx tsx test/test-staged-homes-sweep.mjs && npx tsx test/test-session-helpers.mjs && npx tsx test/test-cli-routing.mjs && npx tsx test/test-security-context.mjs && npx tsx test/test-isolation-decision.mjs && npx tsx test/test-message-helpers.mjs && npx tsx test/test-agent-config.mjs && npx tsx test/test-wrap-command.mjs && npx tsx test/test-credential-staging.mjs && npx tsx test/test-claude-auth.mjs && npx tsx test/test-btw-proxy-env.mjs && npx tsx test/test-output-formatters.mjs && npx tsx test/test-inbox-guard.mjs && npx tsx test/test-auto-topic.mjs && npx tsx test/test-project-info.mjs && npx tsx test/test-agent-types.mjs && npx tsx test/test-transport.mjs && npx tsx test/test-session-update-handlers.mjs && npx tsx test/test-session-scanner.mjs && npx tsx test/test-hypha-client.mjs && npx tsx test/test-hook-settings.mjs && npx tsx test/test-session-service-logic.mjs && npx tsx test/test-daemon-persistence.mjs && npx tsx test/test-detect-isolation.mjs && npx tsx test/test-machine-service-logic.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-backend.mjs && npx tsx test/test-acp-backend.mjs && npx tsx test/test-acp-bridge.mjs && npx tsx test/test-hook-server.mjs && npx tsx test/test-session-commands.mjs && npx tsx test/test-interactive-console.mjs && npx tsx test/test-session-messages.mjs && npx tsx test/test-session-send-query.mjs && npx tsx test/test-skills.mjs && npx tsx test/test-agent-grouping.mjs && npx tsx test/test-machine-list-directory.mjs && npx tsx test/test-service-commands.mjs && npx tsx test/test-supervisor.mjs && npx tsx test/test-supervisor-lock.mjs && node test/test-supervisor-restart.mjs && npx tsx test/test-clear-detection.mjs && npx tsx test/test-session-consolidation.mjs && npx tsx test/test-inbox-store.mjs && npx tsx test/test-inbox.mjs && npx tsx test/test-inbox-cross-machine.mjs && npx tsx test/test-issue-store.mjs && npx tsx test/test-issue-close-gate.mjs && npx tsx test/test-loop-verify.mjs && npx tsx test/test-issue-rpc.mjs && npx tsx test/test-issue-pause.mjs && npx tsx test/test-workflow-store.mjs && npx tsx test/test-workflow-rpc.mjs && npx tsx test/test-workflow-scheduler.mjs && npx tsx test/test-workflow-runs.mjs && npx tsx test/test-serve-link-subdomain.mjs && npx tsx test/test-short-id.mjs && npx tsx test/test-transcript-edit.mjs && npx tsx test/test-edit-history.mjs && npx tsx test/test-friendly-name.mjs && npx tsx test/test-session-rpc-dispatch.mjs && npx tsx test/test-sandbox-cli.mjs && npx tsx test/test-serve-manager.mjs && npx tsx test/test-serve-stability.mjs && npx tsx test/test-frpc-e2e.mjs --unit-only && npx tsx test/test-frpc-status.mjs && node test/pinnedClaudeCode.test.mjs && node test/fleet.test.mjs && npx tsx test/test-session-file.mjs && npx tsx test/test-channel-rpc.mjs && npx tsx test/test-wise-agent.mjs && npx tsx test/test-channel-agent.mjs && npx tsx test/test-channels-service.mjs && npx tsx test/test-hotreload-seam.mjs && npx tsx test/test-hot-reload.mjs && npx tsx test/test-hot-reload-live.mjs && npx tsx test/test-session-core.mjs && npx tsx test/test-channel-async-reply.mjs && npx tsx test/test-channel-binding.mjs && npx tsx test/test-channel-identity.mjs && npx tsx test/test-shared-session-identity.mjs && npx tsx test/test-wise-agent-auth.mjs && npx tsx test/test-channel-http.mjs && npx tsx test/test-channel-upload.mjs && npx tsx test/test-wise-voice.mjs && npx tsx test/test-wise-headless.mjs && npx tsx test/test-wise-machine.mjs && npx tsx test/test-crew-merge.mjs && npx tsx test/test-crew-verdict-routing.mjs && npx tsx test/test-crew-standalone.mjs && npx tsx test/test-session-links.mjs && npx tsx test/test-issue-loop-pause-guard.mjs && npx tsx test/test-artifact-guard.mjs",
|
|
22
|
+
test: "npx tsx test/test-context-window.mjs && npx tsx test/test-ratelimit-retry.mjs && npx tsx test/test-instance-config.mjs && npx tsx test/test-authorize.mjs && npx tsx test/test-normalize-allowed-user.mjs && npx tsx test/test-share-url.mjs && npx tsx test/test-update-sharing-normalization.mjs && npx tsx test/test-sharing-notify-sync.mjs && npx tsx test/test-staged-homes-sweep.mjs && npx tsx test/test-session-helpers.mjs && npx tsx test/test-cli-routing.mjs && npx tsx test/test-security-context.mjs && npx tsx test/test-isolation-decision.mjs && npx tsx test/test-message-helpers.mjs && npx tsx test/test-agent-config.mjs && npx tsx test/test-wrap-command.mjs && npx tsx test/test-credential-staging.mjs && npx tsx test/test-claude-auth.mjs && npx tsx test/test-btw-proxy-env.mjs && npx tsx test/test-output-formatters.mjs && npx tsx test/test-inbox-guard.mjs && npx tsx test/test-auto-topic.mjs && npx tsx test/test-project-info.mjs && npx tsx test/test-agent-types.mjs && npx tsx test/test-transport.mjs && npx tsx test/test-session-update-handlers.mjs && npx tsx test/test-session-scanner.mjs && npx tsx test/test-hypha-client.mjs && npx tsx test/test-hook-settings.mjs && npx tsx test/test-session-service-logic.mjs && npx tsx test/test-daemon-persistence.mjs && npx tsx test/test-detect-isolation.mjs && npx tsx test/test-machine-service-logic.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-backend.mjs && npx tsx test/test-acp-backend.mjs && npx tsx test/test-acp-bridge.mjs && npx tsx test/test-hook-server.mjs && npx tsx test/test-session-commands.mjs && npx tsx test/test-interactive-console.mjs && npx tsx test/test-session-messages.mjs && npx tsx test/test-session-send-query.mjs && npx tsx test/test-skills.mjs && npx tsx test/test-agent-grouping.mjs && npx tsx test/test-machine-list-directory.mjs && npx tsx test/test-service-commands.mjs && npx tsx test/test-supervisor.mjs && npx tsx test/test-supervisor-lock.mjs && node test/test-supervisor-restart.mjs && npx tsx test/test-clear-detection.mjs && npx tsx test/test-session-consolidation.mjs && npx tsx test/test-inbox-store.mjs && npx tsx test/test-inbox.mjs && npx tsx test/test-inbox-cross-machine.mjs && npx tsx test/test-issue-store.mjs && npx tsx test/test-issue-close-gate.mjs && npx tsx test/test-loop-verify.mjs && npx tsx test/test-issue-rpc.mjs && npx tsx test/test-issue-pause.mjs && npx tsx test/test-workflow-store.mjs && npx tsx test/test-workflow-rpc.mjs && npx tsx test/test-workflow-scheduler.mjs && npx tsx test/test-cron.mjs && npx tsx test/test-workflow-runs.mjs && npx tsx test/test-serve-link-subdomain.mjs && npx tsx test/test-short-id.mjs && npx tsx test/test-transcript-edit.mjs && npx tsx test/test-edit-history.mjs && npx tsx test/test-friendly-name.mjs && npx tsx test/test-session-rpc-dispatch.mjs && npx tsx test/test-sandbox-cli.mjs && npx tsx test/test-serve-manager.mjs && npx tsx test/test-serve-stability.mjs && npx tsx test/test-frpc-e2e.mjs --unit-only && npx tsx test/test-frpc-status.mjs && node test/pinnedClaudeCode.test.mjs && node test/fleet.test.mjs && npx tsx test/test-session-file.mjs && npx tsx test/test-channel-rpc.mjs && npx tsx test/test-wise-agent.mjs && npx tsx test/test-channel-agent.mjs && npx tsx test/test-channels-service.mjs && npx tsx test/test-hotreload-seam.mjs && npx tsx test/test-hot-reload.mjs && npx tsx test/test-hot-reload-live.mjs && npx tsx test/test-session-core.mjs && npx tsx test/test-channel-async-reply.mjs && npx tsx test/test-channel-binding.mjs && npx tsx test/test-channel-identity.mjs && npx tsx test/test-shared-session-identity.mjs && npx tsx test/test-wise-agent-auth.mjs && npx tsx test/test-channel-http.mjs && npx tsx test/test-channel-upload.mjs && npx tsx test/test-wise-voice.mjs && npx tsx test/test-wise-headless.mjs && npx tsx test/test-wise-machine.mjs && npx tsx test/test-crew-merge.mjs && npx tsx test/test-crew-verdict-routing.mjs && npx tsx test/test-crew-standalone.mjs && npx tsx test/test-session-links.mjs && npx tsx test/test-issue-loop-pause-guard.mjs && npx tsx test/test-artifact-guard.mjs",
|
|
23
23
|
"test:hypha": "node --no-warnings test/test-hypha-service.mjs",
|
|
24
24
|
dev: "tsx src/cli.ts",
|
|
25
25
|
"dev:daemon": "tsx src/cli.ts daemon start-sync",
|
|
26
26
|
"test:e2e": "node --no-warnings test/e2e-session-tests.mjs",
|
|
27
|
-
"test:frpc": "npx tsx test/test-frpc-e2e.mjs"
|
|
27
|
+
"test:frpc": "npx tsx test/test-frpc-e2e.mjs",
|
|
28
|
+
prepublishOnly: "yarn build"
|
|
28
29
|
};
|
|
29
30
|
var dependencies = {
|
|
30
31
|
"@agentclientprotocol/sdk": "^0.14.1",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { m as resolveProjectRoot } from './run-
|
|
1
|
+
import { m as resolveProjectRoot } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import { g as getWorkflow, s as setWorkflowEnabled, r as removeWorkflow, a as saveWorkflow, b as rawWorkflow, l as listWorkflows } from './store-BTs0H_y0.mjs';
|
|
3
|
-
import { g as getRun, l as listRuns, r as runWorkflow } from './runStore-
|
|
3
|
+
import { g as getRun, l as listRuns, r as runWorkflow } from './runStore-DKC_bMSi.mjs';
|
|
4
4
|
import 'os';
|
|
5
5
|
import 'fs/promises';
|
|
6
6
|
import 'fs';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { m as resolveProjectRoot, u as updateIssue, n as getIssue, o as resumeIssue, p as pauseIssue, q as addComment, t as addIssue, v as listIssues, w as searchIssues, x as isVisibleTo } from './run-
|
|
1
|
+
import { m as resolveProjectRoot, u as updateIssue, n as getIssue, o as resumeIssue, p as pauseIssue, q as addComment, t as addIssue, v as listIssues, w as searchIssues, x as isVisibleTo } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import 'os';
|
|
3
3
|
import 'fs/promises';
|
|
4
4
|
import 'fs';
|
|
@@ -1201,10 +1201,15 @@ function parseField(token, [min, max]) {
|
|
|
1201
1201
|
for (let i = min; i <= max; i++) set.add(i);
|
|
1202
1202
|
} else if (m = part.match(/^\*\/(\d+)$/)) {
|
|
1203
1203
|
const s = +m[1];
|
|
1204
|
+
if (s <= 0) throw new Error(`invalid cron step (must be >= 1): "${token}"`);
|
|
1204
1205
|
for (let i = min; i <= max; i += s) set.add(i);
|
|
1205
1206
|
} else if (m = part.match(/^(\d+)-(\d+)\/(\d+)$/)) {
|
|
1206
|
-
|
|
1207
|
+
const s = +m[3];
|
|
1208
|
+
if (s <= 0) throw new Error(`invalid cron step (must be >= 1): "${token}"`);
|
|
1209
|
+
if (+m[1] > +m[2]) throw new Error(`invalid cron range (start > end): "${token}"`);
|
|
1210
|
+
for (let i = +m[1]; i <= +m[2]; i += s) set.add(i);
|
|
1207
1211
|
} else if (m = part.match(/^(\d+)-(\d+)$/)) {
|
|
1212
|
+
if (+m[1] > +m[2]) throw new Error(`invalid cron range (start > end): "${token}"`);
|
|
1208
1213
|
for (let i = +m[1]; i <= +m[2]; i++) set.add(i);
|
|
1209
1214
|
} else if (m = part.match(/^(\d+)$/)) {
|
|
1210
1215
|
set.add(+m[1]);
|
|
@@ -2991,7 +2996,7 @@ async function registerMachineService(server, machineId, metadata, daemonState,
|
|
|
2991
2996
|
const tunnels = handlers.tunnels;
|
|
2992
2997
|
if (!tunnels) throw new Error("Tunnel management not available");
|
|
2993
2998
|
if (tunnels.has(params.name)) throw new Error(`Tunnel '${params.name}' already running`);
|
|
2994
|
-
const { FrpcTunnel } = await import('./frpc-
|
|
2999
|
+
const { FrpcTunnel } = await import('./frpc-nvGz8fWs.mjs');
|
|
2995
3000
|
const tunnel = new FrpcTunnel({
|
|
2996
3001
|
name: params.name,
|
|
2997
3002
|
ports: params.ports,
|
|
@@ -3442,7 +3447,7 @@ QUESTION: ${params.question || "Summarize this concisely."}` }
|
|
|
3442
3447
|
}
|
|
3443
3448
|
const deps = buildSessionDeps(rpc, { cwd, ownerEmail: owner });
|
|
3444
3449
|
const sender = { name: context?.user?.email || context?.user?.id || "user", kind: "user", verified: true };
|
|
3445
|
-
const { toolsForRole } = await import('./sideband-
|
|
3450
|
+
const { toolsForRole } = await import('./sideband-C-0cCNeL.mjs');
|
|
3446
3451
|
const r2 = await runWiseAgent({ message: params.message, sender, config: { tools: toolsForRole(role2) }, deps, transport, model: resolved.model });
|
|
3447
3452
|
return fmt(r2);
|
|
3448
3453
|
}
|
|
@@ -3541,7 +3546,7 @@ QUESTION: ${params.question || "Summarize this concisely."}` }
|
|
|
3541
3546
|
if (r.error || !r.sender) return { error: r.error || "unauthorized" };
|
|
3542
3547
|
const callId = "call_" + Math.random().toString(16).slice(2, 12);
|
|
3543
3548
|
const rendered = renderMessage(c, { sender: r.sender, body: { message: kwargs.message }, callId });
|
|
3544
|
-
const { queryCore } = await import('./commands-
|
|
3549
|
+
const { queryCore } = await import('./commands-BhLGBhBS.mjs');
|
|
3545
3550
|
const timeout = c.reply?.timeout_sec || 120;
|
|
3546
3551
|
let result;
|
|
3547
3552
|
try {
|
|
@@ -3748,15 +3753,7 @@ function writeInboundContext(sessionId, ctx) {
|
|
|
3748
3753
|
mkdirSync(join(SVAMP_HOME$2, "inbound"), { recursive: true });
|
|
3749
3754
|
const tmp = p + ".tmp";
|
|
3750
3755
|
writeFileSync(tmp, JSON.stringify({ ...ctx, deliveredAt: Date.now() }));
|
|
3751
|
-
|
|
3752
|
-
rmSync(p, { force: true });
|
|
3753
|
-
} catch {
|
|
3754
|
-
}
|
|
3755
|
-
writeFileSync(p, readFileSync(tmp));
|
|
3756
|
-
try {
|
|
3757
|
-
rmSync(tmp, { force: true });
|
|
3758
|
-
} catch {
|
|
3759
|
-
}
|
|
3756
|
+
renameSync(tmp, p);
|
|
3760
3757
|
} catch {
|
|
3761
3758
|
}
|
|
3762
3759
|
}
|
|
@@ -5402,7 +5399,7 @@ function createSessionStore(server, sessionId, initialMetadata, initialAgentStat
|
|
|
5402
5399
|
},
|
|
5403
5400
|
// ── BTW (By The Way) — ephemeral side-channel ──
|
|
5404
5401
|
btw: async (question, context) => {
|
|
5405
|
-
authorizeRequest(context, metadata.sharing, "
|
|
5402
|
+
authorizeRequest(context, metadata.sharing, "admin");
|
|
5406
5403
|
if (!question || typeof question !== "string") {
|
|
5407
5404
|
return { success: false, error: "Question is required" };
|
|
5408
5405
|
}
|
|
@@ -11000,7 +10997,7 @@ const HOUR_MS = 36e5;
|
|
|
11000
10997
|
function sumUsageTokens(usage) {
|
|
11001
10998
|
if (!usage || typeof usage !== "object") return 0;
|
|
11002
10999
|
const n = (v) => typeof v === "number" && Number.isFinite(v) && v > 0 ? v : 0;
|
|
11003
|
-
return n(usage.input_tokens) + n(usage.output_tokens) + n(usage.cache_creation_input_tokens);
|
|
11000
|
+
return n(usage.input_tokens) + n(usage.output_tokens) + n(usage.cache_creation_input_tokens) + Math.round(n(usage.cache_read_input_tokens) * 0.1);
|
|
11004
11001
|
}
|
|
11005
11002
|
function accumulateLedger(prev, sample) {
|
|
11006
11003
|
const base = prev && typeof prev === "object" ? { turns: prev.turns || 0, tokens: prev.tokens || 0, window: Array.isArray(prev.window) ? prev.window : [] } : { turns: 0, tokens: 0, window: [] };
|
|
@@ -12831,7 +12828,7 @@ async function startDaemon(options) {
|
|
|
12831
12828
|
saveExposedTunnels(list);
|
|
12832
12829
|
}
|
|
12833
12830
|
async function createExposedTunnel(spec) {
|
|
12834
|
-
const { FrpcTunnel } = await import('./frpc-
|
|
12831
|
+
const { FrpcTunnel } = await import('./frpc-nvGz8fWs.mjs');
|
|
12835
12832
|
const tunnel = new FrpcTunnel({
|
|
12836
12833
|
name: spec.name,
|
|
12837
12834
|
ports: spec.ports,
|
|
@@ -12851,7 +12848,7 @@ async function startDaemon(options) {
|
|
|
12851
12848
|
return tunnel;
|
|
12852
12849
|
}
|
|
12853
12850
|
const tunnelRecreateState = /* @__PURE__ */ new Map();
|
|
12854
|
-
const { ServeManager } = await import('./serveManager-
|
|
12851
|
+
const { ServeManager } = await import('./serveManager-DGRpRAFM.mjs');
|
|
12855
12852
|
const serveManager = new ServeManager(SVAMP_HOME, (msg) => logger.log(`[SERVE] ${msg}`), hyphaServerUrl);
|
|
12856
12853
|
ensureAutoInstalledSkills(logger).catch(() => {
|
|
12857
12854
|
});
|
|
@@ -14876,11 +14873,11 @@ ${capturedError}${buildClaudeErrorHint(capturedError)}`;
|
|
|
14876
14873
|
});
|
|
14877
14874
|
},
|
|
14878
14875
|
onIssue: async (params) => {
|
|
14879
|
-
const { issueRpc } = await import('./rpc-
|
|
14876
|
+
const { issueRpc } = await import('./rpc-s_Hibfpl.mjs');
|
|
14880
14877
|
return issueRpc(params?.cwd || directory, params || {}, { notifySession: notifyIssueOwner, rekickLoopOwner });
|
|
14881
14878
|
},
|
|
14882
14879
|
onWorkflow: async (params) => {
|
|
14883
|
-
const { workflowRpc } = await import('./rpc-
|
|
14880
|
+
const { workflowRpc } = await import('./rpc-CDI7i151.mjs');
|
|
14884
14881
|
return workflowRpc(params?.cwd || directory, params || {});
|
|
14885
14882
|
},
|
|
14886
14883
|
onRipgrep: async (args, cwd) => {
|
|
@@ -15413,11 +15410,11 @@ ${capturedError}${buildClaudeErrorHint(capturedError)}`;
|
|
|
15413
15410
|
});
|
|
15414
15411
|
},
|
|
15415
15412
|
onIssue: async (params) => {
|
|
15416
|
-
const { issueRpc } = await import('./rpc-
|
|
15413
|
+
const { issueRpc } = await import('./rpc-s_Hibfpl.mjs');
|
|
15417
15414
|
return issueRpc(params?.cwd || directory, params || {}, { notifySession: notifyIssueOwner, rekickLoopOwner });
|
|
15418
15415
|
},
|
|
15419
15416
|
onWorkflow: async (params) => {
|
|
15420
|
-
const { workflowRpc } = await import('./rpc-
|
|
15417
|
+
const { workflowRpc } = await import('./rpc-CDI7i151.mjs');
|
|
15421
15418
|
return workflowRpc(params?.cwd || directory, params || {});
|
|
15422
15419
|
},
|
|
15423
15420
|
onRipgrep: async (args, cwd) => {
|
|
@@ -16034,7 +16031,7 @@ ${oracle.output.trim().slice(0, 500)}`, "\u{1F501} Continuing loop");
|
|
|
16034
16031
|
const channelHttpPort = Number(process.env.SVAMP_CHANNEL_HTTP_PORT) || 0;
|
|
16035
16032
|
if (channelHttpPort > 0) {
|
|
16036
16033
|
try {
|
|
16037
|
-
const { createChannelHttpServer } = await import('./httpServer-
|
|
16034
|
+
const { createChannelHttpServer } = await import('./httpServer-CSMZTpoh.mjs');
|
|
16038
16035
|
const channelHttpServer = createChannelHttpServer({
|
|
16039
16036
|
getSessionIds: () => {
|
|
16040
16037
|
const ids = [];
|
|
@@ -16294,7 +16291,7 @@ ${oracle.output.trim().slice(0, 500)}`, "\u{1F501} Continuing loop");
|
|
|
16294
16291
|
const PING_TIMEOUT_MS = 15e3;
|
|
16295
16292
|
const POST_RECONNECT_GRACE_MS = 2e4;
|
|
16296
16293
|
const RECONNECT_JITTER_MS = 2500;
|
|
16297
|
-
const { WorkflowScheduler } = await import('./scheduler-
|
|
16294
|
+
const { WorkflowScheduler } = await import('./scheduler-E1Bw4HUY.mjs');
|
|
16298
16295
|
const workflowScheduler = new WorkflowScheduler({
|
|
16299
16296
|
projectRoots: () => {
|
|
16300
16297
|
const dirs = /* @__PURE__ */ new Set();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{createRequire as _pkgrollCR}from"node:module";const require=_pkgrollCR(import.meta.url);import { a4 as applyClaudeProxyEnv, a5 as composeSessionId, a6 as generateFriendlyName, c as connectToHypha, a as createSessionStore, r as registerMachineService, a7 as generateHookSettings } from './run-
|
|
1
|
+
import{createRequire as _pkgrollCR}from"node:module";const require=_pkgrollCR(import.meta.url);import { a4 as applyClaudeProxyEnv, a5 as composeSessionId, a6 as generateFriendlyName, c as connectToHypha, a as createSessionStore, r as registerMachineService, a7 as generateHookSettings } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import os from 'node:os';
|
|
3
3
|
import { resolve, join } from 'node:path';
|
|
4
4
|
import { existsSync, readFileSync, watch } from 'node:fs';
|
|
@@ -3,7 +3,7 @@ import { existsSync, readFileSync, mkdirSync, writeFileSync, renameSync } from '
|
|
|
3
3
|
import { randomBytes } from 'node:crypto';
|
|
4
4
|
import { join } from 'node:path';
|
|
5
5
|
import { c as workflowSteps, d as workflowsDir } from './store-BTs0H_y0.mjs';
|
|
6
|
-
import { v as listIssues, t as addIssue } from './run-
|
|
6
|
+
import { v as listIssues, t as addIssue } from './run-BPZ_1RCI.mjs';
|
|
7
7
|
|
|
8
8
|
const MAX_RUNS_PER_WORKFLOW = 50;
|
|
9
9
|
function maxRunsPerWorkflow() {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { m as resolveProjectRoot, y as cronMatches } from './run-
|
|
1
|
+
import { m as resolveProjectRoot, y as cronMatches } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import { l as listWorkflows, i as isWorkflowEnabled, w as workflowCrons } from './store-BTs0H_y0.mjs';
|
|
3
|
-
import { r as runWorkflow } from './runStore-
|
|
3
|
+
import { r as runWorkflow } from './runStore-DKC_bMSi.mjs';
|
|
4
4
|
import 'os';
|
|
5
5
|
import 'fs/promises';
|
|
6
6
|
import 'fs';
|
|
@@ -38,8 +38,18 @@ class WorkflowScheduler {
|
|
|
38
38
|
// Wall-clock minute we last processed, so multiple sub-minute ticks fire a workflow at most once
|
|
39
39
|
// per minute (cron granularity is one minute).
|
|
40
40
|
lastMinuteKey = null;
|
|
41
|
+
// Epoch ms of the last tick we processed — used to detect and catch up wall-clock minutes that were
|
|
42
|
+
// SKIPPED between two ticks (host sleep / suspend / a >60s event-loop stall), since setInterval does
|
|
43
|
+
// not fire while the process is suspended (#0243).
|
|
44
|
+
lastTickMs = null;
|
|
41
45
|
// In-flight runs (fire-and-forget). `idle()` awaits them — used by tests; harmless in prod.
|
|
42
46
|
pending = /* @__PURE__ */ new Set();
|
|
47
|
+
// Default cap on how many skipped minutes we look back over on a single tick. Deliberately small: it
|
|
48
|
+
// rescues genuine short gaps (a >60s event-loop stall, a brief suspend) without resurrecting daily
|
|
49
|
+
// crons hours late after a long sleep — multi-hour catch-up needs persisted last-fire state, out of
|
|
50
|
+
// scope here. Per-workflow dedup means even an every-minute cron fires at most once per sweep (no
|
|
51
|
+
// stampede). Override via SVAMP_SCHEDULER_MAX_CATCHUP_MIN (0 disables catch-up entirely).
|
|
52
|
+
static DEFAULT_MAX_CATCHUP_MINUTES = 5;
|
|
43
53
|
/** Await all in-flight scheduled runs (test helper; the daemon never needs to block on these). */
|
|
44
54
|
async idle() {
|
|
45
55
|
await Promise.all([...this.pending]);
|
|
@@ -47,11 +57,27 @@ class WorkflowScheduler {
|
|
|
47
57
|
static minuteKey(d) {
|
|
48
58
|
return `${d.getFullYear()}-${d.getMonth()}-${d.getDate()}-${d.getHours()}-${d.getMinutes()}`;
|
|
49
59
|
}
|
|
50
|
-
|
|
60
|
+
static maxCatchupMinutes() {
|
|
61
|
+
const raw = Number(process.env.SVAMP_SCHEDULER_MAX_CATCHUP_MIN);
|
|
62
|
+
if (Number.isFinite(raw) && raw >= 0) return Math.min(Math.floor(raw), 1440);
|
|
63
|
+
return WorkflowScheduler.DEFAULT_MAX_CATCHUP_MINUTES;
|
|
64
|
+
}
|
|
65
|
+
/** Fire all scheduled workflows whose cron matches `now` (or any skipped minute since the last tick).
|
|
66
|
+
* Returns the names fired (for tests/logs). */
|
|
51
67
|
tick(now) {
|
|
52
68
|
const key = WorkflowScheduler.minuteKey(now);
|
|
53
69
|
if (key === this.lastMinuteKey) return [];
|
|
70
|
+
const nowMs = now.getTime();
|
|
71
|
+
const curBoundary = Math.floor(nowMs / 6e4) * 6e4;
|
|
72
|
+
const minutes = [];
|
|
73
|
+
if (this.lastTickMs != null) {
|
|
74
|
+
const earliest = nowMs - WorkflowScheduler.maxCatchupMinutes() * 6e4;
|
|
75
|
+
let t = Math.floor(Math.max(this.lastTickMs + 6e4, earliest) / 6e4) * 6e4;
|
|
76
|
+
for (; t < curBoundary; t += 6e4) minutes.push(new Date(t));
|
|
77
|
+
}
|
|
78
|
+
minutes.push(now);
|
|
54
79
|
this.lastMinuteKey = key;
|
|
80
|
+
this.lastTickMs = nowMs;
|
|
55
81
|
const fired = [];
|
|
56
82
|
const seen = /* @__PURE__ */ new Set();
|
|
57
83
|
for (const dir of this.deps.projectRoots()) {
|
|
@@ -73,7 +99,7 @@ class WorkflowScheduler {
|
|
|
73
99
|
if (!isWorkflowEnabled(wf)) continue;
|
|
74
100
|
const crons = workflowCrons(wf);
|
|
75
101
|
if (!crons.length) continue;
|
|
76
|
-
if (crons.some((c) => cronMatchesSafe(c,
|
|
102
|
+
if (minutes.some((m) => crons.some((c) => cronMatchesSafe(c, m)))) {
|
|
77
103
|
this.fire(root, wf);
|
|
78
104
|
fired.push(wf.name);
|
|
79
105
|
}
|
|
@@ -54,7 +54,7 @@ async function handleServeCommand() {
|
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
async function serveAdd(args, machineId) {
|
|
57
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
57
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
58
58
|
const pos = positionalArgs(args);
|
|
59
59
|
const name = pos[0];
|
|
60
60
|
if (!name) {
|
|
@@ -93,7 +93,7 @@ async function serveAdd(args, machineId) {
|
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
async function serveApply(args, machineId) {
|
|
96
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
96
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
97
97
|
const fs = await import('fs');
|
|
98
98
|
const yaml = await import('yaml');
|
|
99
99
|
const file = positionalArgs(args)[0];
|
|
@@ -182,7 +182,7 @@ async function serveApply(args, machineId) {
|
|
|
182
182
|
}
|
|
183
183
|
}
|
|
184
184
|
async function serveRemove(args, machineId) {
|
|
185
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
185
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
186
186
|
const pos = positionalArgs(args);
|
|
187
187
|
const name = pos[0];
|
|
188
188
|
if (!name) {
|
|
@@ -202,7 +202,7 @@ async function serveRemove(args, machineId) {
|
|
|
202
202
|
}
|
|
203
203
|
}
|
|
204
204
|
async function serveList(args, machineId) {
|
|
205
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
205
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
206
206
|
const all = hasFlag(args, "--all", "-a");
|
|
207
207
|
const json = hasFlag(args, "--json");
|
|
208
208
|
const sessionId = getFlag(args, "--session");
|
|
@@ -235,7 +235,7 @@ async function serveList(args, machineId) {
|
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
237
|
async function serveInfo(machineId) {
|
|
238
|
-
const { connectAndGetMachine } = await import('./commands-
|
|
238
|
+
const { connectAndGetMachine } = await import('./commands-BhLGBhBS.mjs');
|
|
239
239
|
const { machine, server } = await connectAndGetMachine(machineId);
|
|
240
240
|
try {
|
|
241
241
|
const info = await machine.serveInfo();
|
|
@@ -4,7 +4,7 @@ import * as fs from 'fs';
|
|
|
4
4
|
import * as http from 'http';
|
|
5
5
|
import * as net from 'net';
|
|
6
6
|
import * as path from 'path';
|
|
7
|
-
import { k as getHyphaServerUrl, S as ServeAuth, l as hasCookieToken } from './run-
|
|
7
|
+
import { k as getHyphaServerUrl, S as ServeAuth, l as hasCookieToken } from './run-BPZ_1RCI.mjs';
|
|
8
8
|
import 'os';
|
|
9
9
|
import 'fs/promises';
|
|
10
10
|
import 'url';
|
|
@@ -599,23 +599,40 @@ class ServeManager {
|
|
|
599
599
|
}
|
|
600
600
|
this.log(`Auth OK '${mountName}': ${userEmail}`);
|
|
601
601
|
}
|
|
602
|
-
|
|
603
|
-
const
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
res.
|
|
613
|
-
|
|
614
|
-
}
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
602
|
+
const resolveContained = () => {
|
|
603
|
+
const base = path.resolve(mount.directory);
|
|
604
|
+
const fp = path.resolve(path.join(base, basePath));
|
|
605
|
+
if (fp !== base && !fp.startsWith(base + path.sep)) return null;
|
|
606
|
+
return fp;
|
|
607
|
+
};
|
|
608
|
+
if ((req.method === "PUT" || req.method === "DELETE") && mount && mount.directory) {
|
|
609
|
+
if (mount.access === "public") {
|
|
610
|
+
this.log(`Write DENY '${mountName}': ${req.method} not allowed on a public (unauthenticated) mount`);
|
|
611
|
+
res.writeHead(403, { "Content-Type": "text/plain" });
|
|
612
|
+
res.end("Write access denied: public mounts are read-only.");
|
|
613
|
+
return;
|
|
614
|
+
}
|
|
615
|
+
const filePath = resolveContained();
|
|
616
|
+
if (!filePath) {
|
|
617
|
+
this.log(`Write DENY '${mountName}': path escapes mount root (${basePath})`);
|
|
618
|
+
res.writeHead(403, { "Content-Type": "text/plain" });
|
|
619
|
+
res.end("Forbidden: path escapes mount root.");
|
|
620
|
+
return;
|
|
621
|
+
}
|
|
622
|
+
if (req.method === "PUT") {
|
|
623
|
+
fs.mkdirSync(path.dirname(filePath), { recursive: true });
|
|
624
|
+
const ws = fs.createWriteStream(filePath);
|
|
625
|
+
req.pipe(ws);
|
|
626
|
+
ws.on("finish", () => {
|
|
627
|
+
res.writeHead(201);
|
|
628
|
+
res.end();
|
|
629
|
+
});
|
|
630
|
+
ws.on("error", (err) => {
|
|
631
|
+
res.writeHead(500);
|
|
632
|
+
res.end(err.message);
|
|
633
|
+
});
|
|
634
|
+
return;
|
|
635
|
+
}
|
|
619
636
|
try {
|
|
620
637
|
fs.unlinkSync(filePath);
|
|
621
638
|
res.writeHead(204);
|
|
@@ -733,7 +750,7 @@ class ServeManager {
|
|
|
733
750
|
const mount = this.mounts.get(mountName);
|
|
734
751
|
const subdomainOverride = mount?.access === "link" && mount.linkToken ? /* @__PURE__ */ new Map([[this.port, buildLinkSubdomain(subdomainSafe, mount.linkToken)]]) : void 0;
|
|
735
752
|
try {
|
|
736
|
-
const { FrpcTunnel } = await import('./frpc-
|
|
753
|
+
const { FrpcTunnel } = await import('./frpc-nvGz8fWs.mjs');
|
|
737
754
|
let tunnel;
|
|
738
755
|
tunnel = new FrpcTunnel({
|
|
739
756
|
name: tunnelName,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { R as READ_ONLY_TOOLS, B as loadMachineContext, C as buildMachineInstructions, D as machineToolsForRole, E as buildMachineTools } from './run-
|
|
1
|
+
import { R as READ_ONLY_TOOLS, B as loadMachineContext, C as buildMachineInstructions, D as machineToolsForRole, E as buildMachineTools } from './run-BPZ_1RCI.mjs';
|
|
2
2
|
import 'node:child_process';
|
|
3
3
|
import 'os';
|
|
4
4
|
import 'fs/promises';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "svamp-cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.246",
|
|
4
4
|
"description": "Svamp CLI — AI workspace daemon on Hypha Cloud",
|
|
5
5
|
"author": "Amun AI AB",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -20,12 +20,13 @@
|
|
|
20
20
|
"scripts": {
|
|
21
21
|
"build": "rm -rf dist bin/skills bin/commands && mkdir -p bin/skills && cp -r ../../skills/artifact bin/skills/artifact && cp -r ../../skills/crew bin/skills/crew && cp -r ../../commands bin/commands && tsc --noEmit && pkgroll",
|
|
22
22
|
"typecheck": "tsc --noEmit",
|
|
23
|
-
"test": "npx tsx test/test-context-window.mjs && npx tsx test/test-ratelimit-retry.mjs && npx tsx test/test-instance-config.mjs && npx tsx test/test-authorize.mjs && npx tsx test/test-normalize-allowed-user.mjs && npx tsx test/test-share-url.mjs && npx tsx test/test-update-sharing-normalization.mjs && npx tsx test/test-sharing-notify-sync.mjs && npx tsx test/test-staged-homes-sweep.mjs && npx tsx test/test-session-helpers.mjs && npx tsx test/test-cli-routing.mjs && npx tsx test/test-security-context.mjs && npx tsx test/test-isolation-decision.mjs && npx tsx test/test-message-helpers.mjs && npx tsx test/test-agent-config.mjs && npx tsx test/test-wrap-command.mjs && npx tsx test/test-credential-staging.mjs && npx tsx test/test-claude-auth.mjs && npx tsx test/test-btw-proxy-env.mjs && npx tsx test/test-output-formatters.mjs && npx tsx test/test-inbox-guard.mjs && npx tsx test/test-auto-topic.mjs && npx tsx test/test-project-info.mjs && npx tsx test/test-agent-types.mjs && npx tsx test/test-transport.mjs && npx tsx test/test-session-update-handlers.mjs && npx tsx test/test-session-scanner.mjs && npx tsx test/test-hypha-client.mjs && npx tsx test/test-hook-settings.mjs && npx tsx test/test-session-service-logic.mjs && npx tsx test/test-daemon-persistence.mjs && npx tsx test/test-detect-isolation.mjs && npx tsx test/test-machine-service-logic.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-backend.mjs && npx tsx test/test-acp-backend.mjs && npx tsx test/test-acp-bridge.mjs && npx tsx test/test-hook-server.mjs && npx tsx test/test-session-commands.mjs && npx tsx test/test-interactive-console.mjs && npx tsx test/test-session-messages.mjs && npx tsx test/test-session-send-query.mjs && npx tsx test/test-skills.mjs && npx tsx test/test-agent-grouping.mjs && npx tsx test/test-machine-list-directory.mjs && npx tsx test/test-service-commands.mjs && npx tsx test/test-supervisor.mjs && npx tsx test/test-supervisor-lock.mjs && node test/test-supervisor-restart.mjs && npx tsx test/test-clear-detection.mjs && npx tsx test/test-session-consolidation.mjs && npx tsx test/test-inbox-store.mjs && npx tsx test/test-inbox.mjs && npx tsx test/test-inbox-cross-machine.mjs && npx tsx test/test-issue-store.mjs && npx tsx test/test-issue-close-gate.mjs && npx tsx test/test-loop-verify.mjs && npx tsx test/test-issue-rpc.mjs && npx tsx test/test-issue-pause.mjs && npx tsx test/test-workflow-store.mjs && npx tsx test/test-workflow-rpc.mjs && npx tsx test/test-workflow-scheduler.mjs && npx tsx test/test-workflow-runs.mjs && npx tsx test/test-serve-link-subdomain.mjs && npx tsx test/test-short-id.mjs && npx tsx test/test-transcript-edit.mjs && npx tsx test/test-edit-history.mjs && npx tsx test/test-friendly-name.mjs && npx tsx test/test-session-rpc-dispatch.mjs && npx tsx test/test-sandbox-cli.mjs && npx tsx test/test-serve-manager.mjs && npx tsx test/test-serve-stability.mjs && npx tsx test/test-frpc-e2e.mjs --unit-only && npx tsx test/test-frpc-status.mjs && node test/pinnedClaudeCode.test.mjs && node test/fleet.test.mjs && npx tsx test/test-session-file.mjs && npx tsx test/test-channel-rpc.mjs && npx tsx test/test-wise-agent.mjs && npx tsx test/test-channel-agent.mjs && npx tsx test/test-channels-service.mjs && npx tsx test/test-hotreload-seam.mjs && npx tsx test/test-hot-reload.mjs && npx tsx test/test-hot-reload-live.mjs && npx tsx test/test-session-core.mjs && npx tsx test/test-channel-async-reply.mjs && npx tsx test/test-channel-binding.mjs && npx tsx test/test-channel-identity.mjs && npx tsx test/test-shared-session-identity.mjs && npx tsx test/test-wise-agent-auth.mjs && npx tsx test/test-channel-http.mjs && npx tsx test/test-channel-upload.mjs && npx tsx test/test-wise-voice.mjs && npx tsx test/test-wise-headless.mjs && npx tsx test/test-wise-machine.mjs && npx tsx test/test-crew-merge.mjs && npx tsx test/test-crew-verdict-routing.mjs && npx tsx test/test-crew-standalone.mjs && npx tsx test/test-session-links.mjs && npx tsx test/test-issue-loop-pause-guard.mjs && npx tsx test/test-artifact-guard.mjs",
|
|
23
|
+
"test": "npx tsx test/test-context-window.mjs && npx tsx test/test-ratelimit-retry.mjs && npx tsx test/test-instance-config.mjs && npx tsx test/test-authorize.mjs && npx tsx test/test-normalize-allowed-user.mjs && npx tsx test/test-share-url.mjs && npx tsx test/test-update-sharing-normalization.mjs && npx tsx test/test-sharing-notify-sync.mjs && npx tsx test/test-staged-homes-sweep.mjs && npx tsx test/test-session-helpers.mjs && npx tsx test/test-cli-routing.mjs && npx tsx test/test-security-context.mjs && npx tsx test/test-isolation-decision.mjs && npx tsx test/test-message-helpers.mjs && npx tsx test/test-agent-config.mjs && npx tsx test/test-wrap-command.mjs && npx tsx test/test-credential-staging.mjs && npx tsx test/test-claude-auth.mjs && npx tsx test/test-btw-proxy-env.mjs && npx tsx test/test-output-formatters.mjs && npx tsx test/test-inbox-guard.mjs && npx tsx test/test-auto-topic.mjs && npx tsx test/test-project-info.mjs && npx tsx test/test-agent-types.mjs && npx tsx test/test-transport.mjs && npx tsx test/test-session-update-handlers.mjs && npx tsx test/test-session-scanner.mjs && npx tsx test/test-hypha-client.mjs && npx tsx test/test-hook-settings.mjs && npx tsx test/test-session-service-logic.mjs && npx tsx test/test-daemon-persistence.mjs && npx tsx test/test-detect-isolation.mjs && npx tsx test/test-machine-service-logic.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-backend.mjs && npx tsx test/test-acp-backend.mjs && npx tsx test/test-acp-bridge.mjs && npx tsx test/test-hook-server.mjs && npx tsx test/test-session-commands.mjs && npx tsx test/test-interactive-console.mjs && npx tsx test/test-session-messages.mjs && npx tsx test/test-session-send-query.mjs && npx tsx test/test-skills.mjs && npx tsx test/test-agent-grouping.mjs && npx tsx test/test-machine-list-directory.mjs && npx tsx test/test-service-commands.mjs && npx tsx test/test-supervisor.mjs && npx tsx test/test-supervisor-lock.mjs && node test/test-supervisor-restart.mjs && npx tsx test/test-clear-detection.mjs && npx tsx test/test-session-consolidation.mjs && npx tsx test/test-inbox-store.mjs && npx tsx test/test-inbox.mjs && npx tsx test/test-inbox-cross-machine.mjs && npx tsx test/test-issue-store.mjs && npx tsx test/test-issue-close-gate.mjs && npx tsx test/test-loop-verify.mjs && npx tsx test/test-issue-rpc.mjs && npx tsx test/test-issue-pause.mjs && npx tsx test/test-workflow-store.mjs && npx tsx test/test-workflow-rpc.mjs && npx tsx test/test-workflow-scheduler.mjs && npx tsx test/test-cron.mjs && npx tsx test/test-workflow-runs.mjs && npx tsx test/test-serve-link-subdomain.mjs && npx tsx test/test-short-id.mjs && npx tsx test/test-transcript-edit.mjs && npx tsx test/test-edit-history.mjs && npx tsx test/test-friendly-name.mjs && npx tsx test/test-session-rpc-dispatch.mjs && npx tsx test/test-sandbox-cli.mjs && npx tsx test/test-serve-manager.mjs && npx tsx test/test-serve-stability.mjs && npx tsx test/test-frpc-e2e.mjs --unit-only && npx tsx test/test-frpc-status.mjs && node test/pinnedClaudeCode.test.mjs && node test/fleet.test.mjs && npx tsx test/test-session-file.mjs && npx tsx test/test-channel-rpc.mjs && npx tsx test/test-wise-agent.mjs && npx tsx test/test-channel-agent.mjs && npx tsx test/test-channels-service.mjs && npx tsx test/test-hotreload-seam.mjs && npx tsx test/test-hot-reload.mjs && npx tsx test/test-hot-reload-live.mjs && npx tsx test/test-session-core.mjs && npx tsx test/test-channel-async-reply.mjs && npx tsx test/test-channel-binding.mjs && npx tsx test/test-channel-identity.mjs && npx tsx test/test-shared-session-identity.mjs && npx tsx test/test-wise-agent-auth.mjs && npx tsx test/test-channel-http.mjs && npx tsx test/test-channel-upload.mjs && npx tsx test/test-wise-voice.mjs && npx tsx test/test-wise-headless.mjs && npx tsx test/test-wise-machine.mjs && npx tsx test/test-crew-merge.mjs && npx tsx test/test-crew-verdict-routing.mjs && npx tsx test/test-crew-standalone.mjs && npx tsx test/test-session-links.mjs && npx tsx test/test-issue-loop-pause-guard.mjs && npx tsx test/test-artifact-guard.mjs",
|
|
24
24
|
"test:hypha": "node --no-warnings test/test-hypha-service.mjs",
|
|
25
25
|
"dev": "tsx src/cli.ts",
|
|
26
26
|
"dev:daemon": "tsx src/cli.ts daemon start-sync",
|
|
27
27
|
"test:e2e": "node --no-warnings test/e2e-session-tests.mjs",
|
|
28
|
-
"test:frpc": "npx tsx test/test-frpc-e2e.mjs"
|
|
28
|
+
"test:frpc": "npx tsx test/test-frpc-e2e.mjs",
|
|
29
|
+
"prepublishOnly": "yarn build"
|
|
29
30
|
},
|
|
30
31
|
"dependencies": {
|
|
31
32
|
"@agentclientprotocol/sdk": "^0.14.1",
|