svamp-cli 0.2.273 → 0.2.274
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-BRY74Q0h.mjs → agentCommands-iom4Qnpt.mjs} +5 -5
- package/dist/{auth-cez4R4me.mjs → auth-C5eN8Hte.mjs} +1 -1
- package/dist/{cli-C-19p_H4.mjs → cli-P3Tx1nrm.mjs} +63 -63
- package/dist/cli.mjs +2 -2
- package/dist/{commands-C8ceYKji.mjs → commands-B6LByF-g.mjs} +1 -1
- package/dist/{commands-BAr_4xB1.mjs → commands-C7J1hEg3.mjs} +2 -2
- package/dist/{commands-CobhxPGy.mjs → commands-CKhDT3cQ.mjs} +41 -18
- package/dist/{commands-eua1Gt4_.mjs → commands-CQHlltkU.mjs} +2 -2
- package/dist/{commands-2aatLLjq.mjs → commands-CgrbLgCc.mjs} +1 -1
- package/dist/{commands-CZqQryOD.mjs → commands-D606feNR.mjs} +4 -4
- package/dist/{commands-BZokG8vu.mjs → commands-VvErX3uk.mjs} +11 -9
- package/dist/{fleet-CzrL5O69.mjs → fleet-B1PDO1l8.mjs} +2 -2
- package/dist/{frpc-CFKdshLL.mjs → frpc-Dzhtizmd.mjs} +73 -32
- package/dist/{headlessCli-DG4HyG2F.mjs → headlessCli-1WzEZVMV.mjs} +2 -2
- package/dist/index.mjs +1 -1
- package/dist/package-BYElq4R_.mjs +64 -0
- package/dist/{pinnedClaudeCode-B9O-hKxm.mjs → pinnedClaudeCode-CgEtGkX2.mjs} +1 -1
- package/dist/{rpc-fy0bKbnH.mjs → rpc-BMoQLUTg.mjs} +1 -1
- package/dist/{rpc-Bbnunkmx.mjs → rpc-CIs3wZAu.mjs} +1 -1
- package/dist/{run-vr8PHjL1.mjs → run-DxoIx34n.mjs} +1 -1
- package/dist/{run-fDelGoR-.mjs → run-l_8UB-9h.mjs} +131 -19
- package/dist/{scheduler-C_3x4bEj.mjs → scheduler-uZ__o3N7.mjs} +1 -1
- package/dist/{serveCommands-DglJYzYC.mjs → serveCommands-twuwB_gw.mjs} +5 -5
- package/dist/{sideband-Mqkuef0c.mjs → sideband-C8myzP2c.mjs} +1 -1
- package/package.json +2 -2
- package/dist/package-BU9leRlh.mjs +0 -64
|
@@ -1390,9 +1390,15 @@ function serveStaticMount(req, res, opts) {
|
|
|
1390
1390
|
return;
|
|
1391
1391
|
}
|
|
1392
1392
|
const indexPath = realContainedPath(rootDir, path.join(target, "index.html"));
|
|
1393
|
-
if (indexPath
|
|
1394
|
-
|
|
1395
|
-
|
|
1393
|
+
if (indexPath) {
|
|
1394
|
+
try {
|
|
1395
|
+
const ist = fs.statSync(indexPath);
|
|
1396
|
+
if (ist.isFile()) {
|
|
1397
|
+
sendFile(req, res, indexPath, ist);
|
|
1398
|
+
return;
|
|
1399
|
+
}
|
|
1400
|
+
} catch {
|
|
1401
|
+
}
|
|
1396
1402
|
}
|
|
1397
1403
|
if (!browse) {
|
|
1398
1404
|
res.writeHead(403, { ...CORS, "Content-Type": "text/plain" });
|
|
@@ -2896,7 +2902,7 @@ Connection: close\r
|
|
|
2896
2902
|
const mount = this.mounts.get(mountName);
|
|
2897
2903
|
const subdomainOverride = mount?.access === "link" && mount.linkToken ? /* @__PURE__ */ new Map([[this.port, buildLinkSubdomain(subdomainSafe, mount.linkToken)]]) : void 0;
|
|
2898
2904
|
try {
|
|
2899
|
-
const { FrpcTunnel } = await import('./frpc-
|
|
2905
|
+
const { FrpcTunnel } = await import('./frpc-Dzhtizmd.mjs');
|
|
2900
2906
|
let tunnel;
|
|
2901
2907
|
tunnel = new FrpcTunnel({
|
|
2902
2908
|
name: tunnelName,
|
|
@@ -5698,7 +5704,7 @@ async function registerMachineService(server, machineId, metadata, daemonState,
|
|
|
5698
5704
|
const tunnels = handlers.tunnels;
|
|
5699
5705
|
if (!tunnels) throw new Error("Tunnel management not available");
|
|
5700
5706
|
if (tunnels.has(params.name)) throw new Error(`Tunnel '${params.name}' already running`);
|
|
5701
|
-
const { FrpcTunnel } = await import('./frpc-
|
|
5707
|
+
const { FrpcTunnel } = await import('./frpc-Dzhtizmd.mjs');
|
|
5702
5708
|
const tunnel = new FrpcTunnel({
|
|
5703
5709
|
name: params.name,
|
|
5704
5710
|
ports: params.ports,
|
|
@@ -6172,7 +6178,7 @@ QUESTION: ${params.question || "Summarize this concisely."}` }
|
|
|
6172
6178
|
}
|
|
6173
6179
|
const deps = buildSessionDeps(rpc, { cwd, ownerEmail: owner });
|
|
6174
6180
|
const sender = { name: context?.user?.email || context?.user?.id || "user", kind: "user", verified: true };
|
|
6175
|
-
const { toolsForRole } = await import('./sideband-
|
|
6181
|
+
const { toolsForRole } = await import('./sideband-C8myzP2c.mjs');
|
|
6176
6182
|
const r2 = await runWiseAgent({ message: params.message, sender, config: { tools: toolsForRole(role2) }, deps, transport, model: resolved.model });
|
|
6177
6183
|
return fmt(r2);
|
|
6178
6184
|
}
|
|
@@ -6271,7 +6277,7 @@ QUESTION: ${params.question || "Summarize this concisely."}` }
|
|
|
6271
6277
|
if (r.error || !r.sender) return { error: r.error || "unauthorized" };
|
|
6272
6278
|
const callId = "call_" + Math.random().toString(16).slice(2, 12);
|
|
6273
6279
|
const rendered = renderMessage(c, { sender: r.sender, body: { message: kwargs.message }, callId });
|
|
6274
|
-
const { queryCore } = await import('./commands-
|
|
6280
|
+
const { queryCore } = await import('./commands-D606feNR.mjs');
|
|
6275
6281
|
const timeout = c.reply?.timeout_sec || 120;
|
|
6276
6282
|
let result;
|
|
6277
6283
|
try {
|
|
@@ -6637,6 +6643,12 @@ function classifyInbound(message, now = Date.now(), opts) {
|
|
|
6637
6643
|
const tripped = recordWake(now);
|
|
6638
6644
|
return { action: "wake", reason: "urgent", breakerTripped: tripped };
|
|
6639
6645
|
}
|
|
6646
|
+
function isHopCapParked(message, opts) {
|
|
6647
|
+
const hop = message.hopCount ?? 0;
|
|
6648
|
+
const human = senderIsHuman(message);
|
|
6649
|
+
const self = false;
|
|
6650
|
+
return !human && !self && !message.channel && hop > MAX_AGENT_HOPS;
|
|
6651
|
+
}
|
|
6640
6652
|
function applyInboxClear(inbox, opts) {
|
|
6641
6653
|
let kept;
|
|
6642
6654
|
if (opts?.messageId) kept = inbox.filter((m) => m.messageId !== opts.messageId);
|
|
@@ -6670,6 +6682,9 @@ function saveInbox(projectDir, sessionId, inbox) {
|
|
|
6670
6682
|
} catch {
|
|
6671
6683
|
}
|
|
6672
6684
|
}
|
|
6685
|
+
function isPending(m) {
|
|
6686
|
+
return !m.handled && !m.read;
|
|
6687
|
+
}
|
|
6673
6688
|
|
|
6674
6689
|
function envInt(name, fallback) {
|
|
6675
6690
|
const raw = process.env[name];
|
|
@@ -7654,10 +7669,13 @@ function createSessionStore(server, sessionId, initialMetadata, initialAgentStat
|
|
|
7654
7669
|
},
|
|
7655
7670
|
// Agent/owner answers a queued (async) channel message → channel outbox, addressed
|
|
7656
7671
|
// to the original external caller. Routed here by `inbox reply` for channel-origin
|
|
7657
|
-
// inbox messages (which carry channelId + correlationId + from).
|
|
7658
|
-
//
|
|
7672
|
+
// inbox messages (which carry channelId + correlationId + from). #0466: owner-gated
|
|
7673
|
+
// (admin tier — the highest shared role; owner + same-owner-workspace still pass
|
|
7674
|
+
// above) since this speaks AS the session to EXTERNAL parties, recorded verified:true.
|
|
7675
|
+
// A mere interact-tier collaborator must not be able to emit outbound replies as the
|
|
7676
|
+
// session — that would be attribution spoofing to third parties.
|
|
7659
7677
|
channelReply: async (params, context) => {
|
|
7660
|
-
authorizeRequest(context, metadata.sharing, "
|
|
7678
|
+
authorizeRequest(context, metadata.sharing, "admin");
|
|
7661
7679
|
const c = channelStore.get(params.channel);
|
|
7662
7680
|
if (!c) return { ok: false, error: "channel not found" };
|
|
7663
7681
|
if (!params.to || !params.body) return { ok: false, error: "to and body are required" };
|
|
@@ -15939,7 +15957,7 @@ async function startDaemon(options) {
|
|
|
15939
15957
|
try {
|
|
15940
15958
|
const dir = loadSessionIndex()[sessionId]?.directory;
|
|
15941
15959
|
if (!dir) return;
|
|
15942
|
-
const { reconcileServiceLinks } = await import('./agentCommands-
|
|
15960
|
+
const { reconcileServiceLinks } = await import('./agentCommands-iom4Qnpt.mjs');
|
|
15943
15961
|
const configPath = getSvampConfigPath(dir, sessionId);
|
|
15944
15962
|
const config = readSvampConfig(configPath);
|
|
15945
15963
|
const entries = Array.from(urls.entries());
|
|
@@ -15957,7 +15975,7 @@ async function startDaemon(options) {
|
|
|
15957
15975
|
}
|
|
15958
15976
|
}
|
|
15959
15977
|
async function createExposedTunnel(spec) {
|
|
15960
|
-
const { FrpcTunnel } = await import('./frpc-
|
|
15978
|
+
const { FrpcTunnel } = await import('./frpc-Dzhtizmd.mjs');
|
|
15961
15979
|
const tunnel = new FrpcTunnel({
|
|
15962
15980
|
name: spec.name,
|
|
15963
15981
|
ports: spec.ports,
|
|
@@ -15985,7 +16003,7 @@ async function startDaemon(options) {
|
|
|
15985
16003
|
ensureAutoInstalledCommands(logger);
|
|
15986
16004
|
(async () => {
|
|
15987
16005
|
try {
|
|
15988
|
-
const { beginClaudeVersionReconcile } = await import('./pinnedClaudeCode-
|
|
16006
|
+
const { beginClaudeVersionReconcile } = await import('./pinnedClaudeCode-CgEtGkX2.mjs');
|
|
15989
16007
|
beginClaudeVersionReconcile((msg) => logger.log(msg));
|
|
15990
16008
|
} catch (e) {
|
|
15991
16009
|
logger.log(`[claude-version] check failed: ${e?.message || e}`);
|
|
@@ -18147,11 +18165,11 @@ ${capturedError}${buildClaudeErrorHint(capturedError)}`;
|
|
|
18147
18165
|
});
|
|
18148
18166
|
},
|
|
18149
18167
|
onIssue: async (params) => {
|
|
18150
|
-
const { issueRpc } = await import('./rpc-
|
|
18168
|
+
const { issueRpc } = await import('./rpc-CIs3wZAu.mjs');
|
|
18151
18169
|
return issueRpc(params?.cwd || directory, params || {}, { notifySession: notifyIssueOwner, rekickLoopOwner });
|
|
18152
18170
|
},
|
|
18153
18171
|
onWorkflow: async (params) => {
|
|
18154
|
-
const { workflowRpc } = await import('./rpc-
|
|
18172
|
+
const { workflowRpc } = await import('./rpc-BMoQLUTg.mjs');
|
|
18155
18173
|
return workflowRpc(params?.cwd || directory, params || {});
|
|
18156
18174
|
},
|
|
18157
18175
|
onRipgrep: async (args, cwd) => {
|
|
@@ -18368,6 +18386,47 @@ ${capturedError}${buildClaudeErrorHint(capturedError)}`;
|
|
|
18368
18386
|
sessionMetadata = { ...sessionMetadata, lifecycleState: "idle" };
|
|
18369
18387
|
sessionService.updateMetadata(sessionMetadata);
|
|
18370
18388
|
logger.log(`Session ${sessionId} registered on Hypha, waiting for first message to spawn Claude`);
|
|
18389
|
+
const inboxReconcileMs = Number(process.env.SVAMP_INBOX_RECONCILE_MS);
|
|
18390
|
+
const INBOX_RECONCILE_INTERVAL_MS = Number.isFinite(inboxReconcileMs) && inboxReconcileMs >= 0 ? inboxReconcileMs : 15e3;
|
|
18391
|
+
let inboxReconcileTimer = null;
|
|
18392
|
+
const reconcileIdleInbox = () => {
|
|
18393
|
+
if (trackedSession.stopped) {
|
|
18394
|
+
if (inboxReconcileTimer) clearInterval(inboxReconcileTimer);
|
|
18395
|
+
return;
|
|
18396
|
+
}
|
|
18397
|
+
if (sessionWasProcessing) return;
|
|
18398
|
+
if (isKillingClaude || isRestartingClaude || isSwitchingMode) return;
|
|
18399
|
+
const queue = sessionMetadata.messageQueue;
|
|
18400
|
+
if (queue && queue.length > 0) {
|
|
18401
|
+
processMessageQueueRef?.();
|
|
18402
|
+
return;
|
|
18403
|
+
}
|
|
18404
|
+
let inbox = [];
|
|
18405
|
+
try {
|
|
18406
|
+
inbox = loadInbox(directory, sessionId);
|
|
18407
|
+
} catch {
|
|
18408
|
+
return;
|
|
18409
|
+
}
|
|
18410
|
+
const deliverable = inbox.filter((m) => isPending(m) && !isHopCapParked(m));
|
|
18411
|
+
if (deliverable.length === 0) return;
|
|
18412
|
+
logger.log(`[Session ${sessionId}] Idle-inbox reconcile: ${deliverable.length} undelivered pending message(s) on an idle agent \u2014 delivering`);
|
|
18413
|
+
const existing = sessionMetadata.messageQueue || [];
|
|
18414
|
+
const seen = new Set(existing.map((e) => e.id));
|
|
18415
|
+
const additions = deliverable.filter((m) => !seen.has(m.messageId)).map((m) => {
|
|
18416
|
+
const formatted = formatInboxMessageXml(m);
|
|
18417
|
+
return { id: m.messageId, text: formatted, displayText: formatted, createdAt: Date.now(), inboxHop: m.hopCount ?? 0, inboxThreadId: m.threadId || m.messageId };
|
|
18418
|
+
});
|
|
18419
|
+
if (additions.length === 0) {
|
|
18420
|
+
processMessageQueueRef?.();
|
|
18421
|
+
return;
|
|
18422
|
+
}
|
|
18423
|
+
sessionMetadata = { ...sessionMetadata, messageQueue: [...existing, ...additions] };
|
|
18424
|
+
sessionService.updateMetadata(sessionMetadata);
|
|
18425
|
+
processMessageQueueRef?.();
|
|
18426
|
+
};
|
|
18427
|
+
if (INBOX_RECONCILE_INTERVAL_MS > 0) {
|
|
18428
|
+
inboxReconcileTimer = setInterval(reconcileIdleInbox, INBOX_RECONCILE_INTERVAL_MS);
|
|
18429
|
+
}
|
|
18371
18430
|
return {
|
|
18372
18431
|
type: "success",
|
|
18373
18432
|
sessionId,
|
|
@@ -18721,11 +18780,11 @@ ${capturedError}${buildClaudeErrorHint(capturedError)}`;
|
|
|
18721
18780
|
});
|
|
18722
18781
|
},
|
|
18723
18782
|
onIssue: async (params) => {
|
|
18724
|
-
const { issueRpc } = await import('./rpc-
|
|
18783
|
+
const { issueRpc } = await import('./rpc-CIs3wZAu.mjs');
|
|
18725
18784
|
return issueRpc(params?.cwd || directory, params || {}, { notifySession: notifyIssueOwner, rekickLoopOwner });
|
|
18726
18785
|
},
|
|
18727
18786
|
onWorkflow: async (params) => {
|
|
18728
|
-
const { workflowRpc } = await import('./rpc-
|
|
18787
|
+
const { workflowRpc } = await import('./rpc-BMoQLUTg.mjs');
|
|
18729
18788
|
return workflowRpc(params?.cwd || directory, params || {});
|
|
18730
18789
|
},
|
|
18731
18790
|
onRipgrep: async (args, cwd) => {
|
|
@@ -19161,6 +19220,59 @@ ${oracle.output.trim().slice(0, 500)}`, "\u{1F501} Continuing loop");
|
|
|
19161
19220
|
}
|
|
19162
19221
|
};
|
|
19163
19222
|
pidToTrackedSession.set(randomUUID$1(), trackedSession);
|
|
19223
|
+
let acpInboxReconcileTimer = null;
|
|
19224
|
+
const reconcileAcpIdleInbox = () => {
|
|
19225
|
+
if (acpStopped) {
|
|
19226
|
+
if (acpInboxReconcileTimer) clearInterval(acpInboxReconcileTimer);
|
|
19227
|
+
return;
|
|
19228
|
+
}
|
|
19229
|
+
if (!acpBackendReady) return;
|
|
19230
|
+
if (sessionMetadata.lifecycleState !== "idle") return;
|
|
19231
|
+
let inbox = [];
|
|
19232
|
+
try {
|
|
19233
|
+
inbox = loadInbox(directory, sessionId);
|
|
19234
|
+
} catch {
|
|
19235
|
+
return;
|
|
19236
|
+
}
|
|
19237
|
+
const existing = sessionMetadata.messageQueue || [];
|
|
19238
|
+
const seen = new Set(existing.map((e) => e.id));
|
|
19239
|
+
const deliverable = inbox.filter((m) => isPending(m) && !isHopCapParked(m) && !seen.has(m.messageId));
|
|
19240
|
+
let queue = existing;
|
|
19241
|
+
if (deliverable.length > 0) {
|
|
19242
|
+
const additions = deliverable.map((m) => {
|
|
19243
|
+
const formatted = formatInboxMessageXml(m);
|
|
19244
|
+
return { id: m.messageId, text: formatted, displayText: formatted, createdAt: Date.now(), inboxHop: m.hopCount ?? 0, inboxThreadId: m.threadId || m.messageId };
|
|
19245
|
+
});
|
|
19246
|
+
queue = [...existing, ...additions];
|
|
19247
|
+
sessionMetadata = { ...sessionMetadata, messageQueue: queue };
|
|
19248
|
+
sessionService.updateMetadata(sessionMetadata);
|
|
19249
|
+
}
|
|
19250
|
+
if (!queue || queue.length === 0) return;
|
|
19251
|
+
const next = queue[0];
|
|
19252
|
+
const remaining = queue.slice(1);
|
|
19253
|
+
sessionMetadata = { ...sessionMetadata, messageQueue: remaining.length > 0 ? remaining : void 0, lifecycleState: "running" };
|
|
19254
|
+
sessionService.updateMetadata(sessionMetadata);
|
|
19255
|
+
if (typeof next.inboxHop === "number") {
|
|
19256
|
+
writeInboundContext(sessionId, { hopCount: next.inboxHop, threadId: next.inboxThreadId });
|
|
19257
|
+
sessionService.markInboxHandled(next.id);
|
|
19258
|
+
}
|
|
19259
|
+
logger.log(`[${agentName} Session ${sessionId}] Idle-inbox reconcile: delivering queued message to idle agent`);
|
|
19260
|
+
sessionService.pushMessage(next.displayText || next.text, "user");
|
|
19261
|
+
sessionService.sendKeepAlive(true);
|
|
19262
|
+
agentBackend.sendPrompt(sessionId, next.text).catch((err) => {
|
|
19263
|
+
logger.error(`[${agentName} Session ${sessionId}] Error delivering reconciled inbox message: ${err.message}`);
|
|
19264
|
+
if (!acpStopped) {
|
|
19265
|
+
sessionMetadata = { ...sessionMetadata, lifecycleState: "idle" };
|
|
19266
|
+
sessionService.updateMetadata(sessionMetadata);
|
|
19267
|
+
sessionService.sendSessionEnd();
|
|
19268
|
+
}
|
|
19269
|
+
});
|
|
19270
|
+
};
|
|
19271
|
+
{
|
|
19272
|
+
const acpReconcileMs = Number(process.env.SVAMP_INBOX_RECONCILE_MS);
|
|
19273
|
+
const acpReconcileInterval = Number.isFinite(acpReconcileMs) && acpReconcileMs >= 0 ? acpReconcileMs : 15e3;
|
|
19274
|
+
if (acpReconcileInterval > 0) acpInboxReconcileTimer = setInterval(reconcileAcpIdleInbox, acpReconcileInterval);
|
|
19275
|
+
}
|
|
19164
19276
|
logger.log(`[Agent Session ${sessionId}] Starting ${agentName} backend...`);
|
|
19165
19277
|
agentBackend.startSession().then(() => {
|
|
19166
19278
|
acpBackendReady = true;
|
|
@@ -19564,7 +19676,7 @@ ${oracle.output.trim().slice(0, 500)}`, "\u{1F501} Continuing loop");
|
|
|
19564
19676
|
}
|
|
19565
19677
|
if (persistedSessions.length > 0) {
|
|
19566
19678
|
try {
|
|
19567
|
-
const { awaitClaudeVersionReady } = await import('./pinnedClaudeCode-
|
|
19679
|
+
const { awaitClaudeVersionReady } = await import('./pinnedClaudeCode-CgEtGkX2.mjs');
|
|
19568
19680
|
await awaitClaudeVersionReady();
|
|
19569
19681
|
} catch {
|
|
19570
19682
|
}
|
|
@@ -19761,7 +19873,7 @@ ${oracle.output.trim().slice(0, 500)}`, "\u{1F501} Continuing loop");
|
|
|
19761
19873
|
const PING_TIMEOUT_MS = 15e3;
|
|
19762
19874
|
const POST_RECONNECT_GRACE_MS = 2e4;
|
|
19763
19875
|
const RECONNECT_JITTER_MS = 2500;
|
|
19764
|
-
const { WorkflowScheduler } = await import('./scheduler-
|
|
19876
|
+
const { WorkflowScheduler } = await import('./scheduler-uZ__o3N7.mjs');
|
|
19765
19877
|
const workflowScheduler = new WorkflowScheduler({
|
|
19766
19878
|
projectRoots: () => {
|
|
19767
19879
|
const dirs = /* @__PURE__ */ new Set();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { j as resolveProjectRoot, D as listWorkflows, E as isWorkflowEnabled, F as workflowCrons, y as runWorkflow, G as cronMatches } from './run-
|
|
1
|
+
import { j as resolveProjectRoot, D as listWorkflows, E as isWorkflowEnabled, F as workflowCrons, y as runWorkflow, G as cronMatches } from './run-l_8UB-9h.mjs';
|
|
2
2
|
import 'os';
|
|
3
3
|
import 'fs/promises';
|
|
4
4
|
import 'fs';
|
|
@@ -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-D606feNR.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-D606feNR.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-D606feNR.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-D606feNR.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-D606feNR.mjs');
|
|
239
239
|
const { machine, server } = await connectAndGetMachine(machineId);
|
|
240
240
|
try {
|
|
241
241
|
const info = await machine.serveInfo();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { R as READ_ONLY_TOOLS, J as loadMachineContext, K as buildMachineInstructions, L as machineToolsForRole, M as buildMachineTools } from './run-
|
|
1
|
+
import { R as READ_ONLY_TOOLS, J as loadMachineContext, K as buildMachineInstructions, L as machineToolsForRole, M as buildMachineTools } from './run-l_8UB-9h.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.274",
|
|
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,7 +20,7 @@
|
|
|
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-backend-accounts.mjs && npx tsx test/test-backend-oauth.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-session-access-fallback.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-app-server.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-compact-detect.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-workflow-idle.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-ws-upgrade.mjs && npx tsx test/test-serve-auth.mjs && npx tsx test/test-static-file-server.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-outbox-reload.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 && npx tsx test/test-graceful-restart.mjs && npx tsx test/test-flush-exit.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-backend-accounts.mjs && npx tsx test/test-backend-oauth.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-inbox-reconcile.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-session-access-fallback.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-app-server.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-compact-detect.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-workflow-idle.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-ws-upgrade.mjs && npx tsx test/test-serve-auth.mjs && npx tsx test/test-static-file-server.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-outbox-reload.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 && npx tsx test/test-graceful-restart.mjs && npx tsx test/test-flush-exit.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",
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
var name = "svamp-cli";
|
|
2
|
-
var version = "0.2.273";
|
|
3
|
-
var description = "Svamp CLI — AI workspace daemon on Hypha Cloud";
|
|
4
|
-
var author = "Amun AI AB";
|
|
5
|
-
var license = "SEE LICENSE IN LICENSE";
|
|
6
|
-
var type = "module";
|
|
7
|
-
var bin = {
|
|
8
|
-
svamp: "./bin/svamp.mjs"
|
|
9
|
-
};
|
|
10
|
-
var files = [
|
|
11
|
-
"dist",
|
|
12
|
-
"bin"
|
|
13
|
-
];
|
|
14
|
-
var main = "./dist/index.mjs";
|
|
15
|
-
var exports$1 = {
|
|
16
|
-
".": "./dist/index.mjs",
|
|
17
|
-
"./cli": "./dist/cli.mjs"
|
|
18
|
-
};
|
|
19
|
-
var scripts = {
|
|
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
|
-
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-backend-accounts.mjs && npx tsx test/test-backend-oauth.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-session-access-fallback.mjs && npx tsx test/test-interactive-helpers.mjs && npx tsx test/test-codex-app-server.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-compact-detect.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-workflow-idle.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-ws-upgrade.mjs && npx tsx test/test-serve-auth.mjs && npx tsx test/test-static-file-server.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-outbox-reload.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 && npx tsx test/test-graceful-restart.mjs && npx tsx test/test-flush-exit.mjs",
|
|
23
|
-
"test:hypha": "node --no-warnings test/test-hypha-service.mjs",
|
|
24
|
-
dev: "tsx src/cli.ts",
|
|
25
|
-
"dev:daemon": "tsx src/cli.ts daemon start-sync",
|
|
26
|
-
"test:e2e": "node --no-warnings test/e2e-session-tests.mjs",
|
|
27
|
-
"test:frpc": "npx tsx test/test-frpc-e2e.mjs",
|
|
28
|
-
prepublishOnly: "yarn build"
|
|
29
|
-
};
|
|
30
|
-
var dependencies = {
|
|
31
|
-
"@agentclientprotocol/sdk": "^0.14.1",
|
|
32
|
-
"@modelcontextprotocol/sdk": "^1.25.3",
|
|
33
|
-
"hypha-rpc": "0.21.42",
|
|
34
|
-
"node-pty": "1.2.0-beta.11",
|
|
35
|
-
ws: "^8.18.0",
|
|
36
|
-
yaml: "^2.8.2",
|
|
37
|
-
zod: "^3.24.4"
|
|
38
|
-
};
|
|
39
|
-
var devDependencies = {
|
|
40
|
-
"@types/node": ">=20",
|
|
41
|
-
"@types/ws": "^8.5.14",
|
|
42
|
-
pkgroll: "^2.14.2",
|
|
43
|
-
tsx: "^4.20.6",
|
|
44
|
-
typescript: "5.9.3"
|
|
45
|
-
};
|
|
46
|
-
var packageManager = "yarn@1.22.22";
|
|
47
|
-
var _package = {
|
|
48
|
-
name: name,
|
|
49
|
-
version: version,
|
|
50
|
-
description: description,
|
|
51
|
-
author: author,
|
|
52
|
-
license: license,
|
|
53
|
-
type: type,
|
|
54
|
-
bin: bin,
|
|
55
|
-
files: files,
|
|
56
|
-
main: main,
|
|
57
|
-
exports: exports$1,
|
|
58
|
-
scripts: scripts,
|
|
59
|
-
dependencies: dependencies,
|
|
60
|
-
devDependencies: devDependencies,
|
|
61
|
-
packageManager: packageManager
|
|
62
|
-
};
|
|
63
|
-
|
|
64
|
-
export { author, bin, _package as default, dependencies, description, devDependencies, exports$1 as exports, files, license, main, name, packageManager, scripts, type, version };
|