@desplega.ai/agent-swarm 2.2.0 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{acp-adapter-k0vwfyvn.js → acp-adapter-v85a2bqy.js} +1 -1
- package/dist/{actions-w4pnb8vz.js → actions-zgcxfspj.js} +15 -15
- package/dist/{amp-adapter-0cmxb2t5.js → amp-adapter-jw9xfz42.js} +2 -2
- package/dist/{app-zneem7g9.js → app-4e1s4675.js} +3 -3
- package/dist/{assistant-wbzd2rnr.js → assistant-v238n9dk.js} +16 -16
- package/dist/{boot-reembed-4kx69j3g.js → boot-reembed-p666cw5n.js} +1 -1
- package/dist/{boot-reembed-db0wwgy1.js → boot-reembed-w6pm64j4.js} +1 -1
- package/dist/{boot-scrub-sweep-tfv4d3mm.js → boot-scrub-sweep-jcyjagn3.js} +2 -2
- package/dist/{boot-seeds-w2hmkxn5.js → boot-seeds-gbedmamp.js} +4 -4
- package/dist/{claude-adapter-5qrc2paq.js → claude-adapter-q7wspzt8.js} +2 -2
- package/dist/{claude-managed-setup-7ra32em4.js → claude-managed-setup-wza784fb.js} +1 -1
- package/dist/{claude-sdk-session-cd02gc76.js → claude-sdk-session-yf400ptr.js} +2 -2
- package/dist/{cli-p46xdr1m.js → cli-0rh20bp3.js} +1 -1
- package/dist/{cli-e5y285rg.js → cli-1v8w782f.js} +1 -1
- package/dist/{cli-8c1m9mhy.js → cli-30m5q8mc.js} +5 -5
- package/dist/{cli-xnp2vkx7.js → cli-4hmaheb6.js} +6 -6
- package/dist/{cli-xhgtay7w.js → cli-4s1kqrqg.js} +1 -1
- package/dist/{cli-2jm992rm.js → cli-5d1m1qca.js} +2 -2
- package/dist/{cli-mvsfbbgq.js → cli-65q70v2v.js} +3 -3
- package/dist/{cli-th8krqbf.js → cli-6p7ddg72.js} +2 -2
- package/dist/{cli-6q7pyd3k.js → cli-6vcyw6v7.js} +1 -1
- package/dist/{cli-bddxamg7.js → cli-8qsx817b.js} +23 -22
- package/dist/{cli-ztcxv5nv.js → cli-9e9kjqsj.js} +1 -1
- package/dist/{cli-jrk8mj0t.js → cli-a17tzmn0.js} +1 -1
- package/dist/{cli-raejy0mp.js → cli-d43xqzbe.js} +1 -1
- package/dist/{cli-tba8fxf9.js → cli-dxwh4j32.js} +11 -11
- package/dist/{cli-c9vrwcpb.js → cli-ea7chd26.js} +19 -19
- package/dist/{cli-vmbakbq0.js → cli-fhvqt2fp.js} +1 -1
- package/dist/{cli-z3dk189k.js → cli-fp4xbw07.js} +6 -6
- package/dist/{cli-xx13gqf3.js → cli-g6p7c2my.js} +1 -1
- package/dist/{cli-c0dpzwnx.js → cli-hn3pftj2.js} +2 -2
- package/dist/{cli-h23mr2s6.js → cli-hz64bcnj.js} +2 -2
- package/dist/{cli-dw0njd9q.js → cli-jhmjwqcg.js} +5 -5
- package/dist/{cli-0k9rcwfy.js → cli-ka01m5rb.js} +28 -12
- package/dist/{cli-jhhb2v9n.js → cli-kqypty34.js} +2 -2
- package/dist/{cli-hwc4a9xm.js → cli-q1812jbw.js} +4 -4
- package/dist/{cli-8w65vwee.js → cli-qrwp40st.js} +1 -1
- package/dist/{cli-4c7k75rq.js → cli-re4wkbzx.js} +54 -41
- package/dist/{cli-z1hh99j0.js → cli-tr24eeny.js} +2 -2
- package/dist/{cli-q6gw45wj.js → cli-wtg6edvd.js} +1 -1
- package/dist/{cli-mnry16kh.js → cli-xgn4rwyv.js} +4 -4
- package/dist/{cli-5ks6x36q.js → cli-y3dvz6ge.js} +3 -3
- package/dist/{cli-ksrphveb.js → cli-yv0vgscc.js} +1 -0
- package/dist/{cli-ak4c12mh.js → cli-yv3n83x8.js} +1 -1
- package/dist/{cli-9ac0mkg5.js → cli-zes4tsbb.js} +1 -1
- package/dist/cli.js +14 -14
- package/dist/{codex-adapter-m0fx3v3s.js → codex-adapter-nhjj2veb.js} +1 -1
- package/dist/{codex-session-runner-j9m2gfyy.js → codex-session-runner-6hggrjbx.js} +1 -1
- package/dist/{commands-ktnqwrv4.js → commands-mrw1ph2w.js} +2 -2
- package/dist/{controller-nex2he8v.js → controller-pt1zam5w.js} +2 -2
- package/dist/{controllers-connect-6yhwqv9v.js → controllers-connect-ymw5541d.js} +16 -16
- package/dist/{cursor-adapter-02s5ekva.js → cursor-adapter-cf4zh5x0.js} +1 -1
- package/dist/{db-19tw9r5s.js → db-hhpy6m4x.js} +2 -2
- package/dist/{db-jvr86v7f.js → db-hy80219q.js} +1 -1
- package/dist/{dispatcher-d3mnsg2y.js → dispatcher-6pdjtkr1.js} +14 -14
- package/dist/{dsh-adapter-63rvej88.js → dsh-adapter-fbx06re2.js} +1 -1
- package/dist/{external-channel-44cwer32.js → external-channel-j6vb6ya1.js} +2 -2
- package/dist/{grok-adapter-ysp907f6.js → grok-adapter-1193sprp.js} +2 -2
- package/dist/{handlers-t5pbabwf.js → handlers-tb3xgjnm.js} +17 -17
- package/dist/{heartbeat-2etacsqq.js → heartbeat-h1w1ktce.js} +17 -17
- package/dist/{hook-3kvmax6d.js → hook-ejja4bpe.js} +1 -1
- package/dist/{hook-mzxxs5n2.js → hook-skrbja18.js} +1 -1
- package/dist/{http-fn978m0g.js → http-mzh41mfj.js} +108 -52
- package/dist/{index-039x2sag.js → index-6rmnn89d.js} +40 -12
- package/dist/{index-w2wr89xd.js → index-epr2gnbw.js} +1 -1
- package/dist/{index-qyjbb7br.js → index-nyfcdpky.js} +17 -17
- package/dist/{index-e4tsa1h7.js → index-vjn3wbzf.js} +14 -14
- package/dist/{index-1r8hw4vd.js → index-xmmkyx82.js} +14 -14
- package/dist/{keepalive-d4nzs76x.js → keepalive-4djvbm2j.js} +3 -3
- package/dist/{lead-8h5n9k5f.js → lead-61kqp604.js} +23 -23
- package/dist/{maintenance-ea6jfw42.js → maintenance-f3xhnjsm.js} +1 -1
- package/dist/{oauth-refresh-sweep-3f25djq3.js → oauth-refresh-sweep-fpd6x6rw.js} +2 -2
- package/dist/{onboard-pvk7hdb2.js → onboard-196tjgyn.js} +2 -2
- package/dist/{otel-impl-qb7nhgdp.js → otel-impl-g8fh4c21.js} +1 -1
- package/dist/{pricing-refresh-6ehwkcmp.js → pricing-refresh-sdcf5yaz.js} +3 -3
- package/dist/{rbac-roles-9648nh00.js → rbac-roles-2x4g1wb5.js} +2 -2
- package/dist/{rbac-roles-km0f9cmm.js → rbac-roles-bsp5657v.js} +1 -1
- package/dist/{render-v2-xkze1wef.js → render-v2-0pyb39bb.js} +3 -3
- package/dist/{resume-tq0bbvt5.js → resume-a86tkj6r.js} +5 -5
- package/dist/{setup-rnrazxvd.js → setup-ypbzcapd.js} +1 -1
- package/dist/{work-objects-e75q2rqs.js → work-objects-yjp8de12.js} +17 -17
- package/dist/{worker-4ww4hjef.js → worker-4ptnn1ge.js} +23 -23
- package/openapi.json +168 -6
- package/package.json +2 -2
- package/src/be/asset-key-audit.ts +4 -13
- package/src/be/db.ts +57 -33
- package/src/be/migrations/227_inbox_item_state_last_read_at.sql +1 -0
- package/src/be/seed-scripts/catalog/heartbeat-jev-gate.ts +22 -4
- package/src/heartbeat/heartbeat.ts +25 -7
- package/src/http/assets.ts +26 -4
- package/src/http/inbox-state.ts +58 -8
- package/src/kv-reserved-namespaces.ts +1 -0
- package/src/providers/amp-adapter.ts +1 -1
- package/src/tests/asset-key-api.test.ts +128 -0
- package/src/tests/asset-key-invariants.test.ts +179 -3
- package/src/tests/asset-key-migration.test.ts +35 -0
- package/src/tests/docs-index-footprint.test.js +2 -2
- package/src/tests/heartbeat-checklist.test.ts +88 -0
- package/src/tests/heartbeat-jev-gate.test.ts +394 -10
- package/src/tests/inbox-state.test.ts +167 -0
- package/src/tests/kv-tool.test.ts +15 -0
- package/src/tests/script-connections.test.ts +2 -0
- package/src/types.ts +2 -0
- package/templates/skills/code-quality/content.md +2 -2
- package/templates/skills/pages/content.md +4 -0
- package/templates/skills/swarm-scripts/SKILL.md +6 -0
- package/templates/skills/swarm-scripts/content.md +6 -0
|
@@ -47,10 +47,10 @@ import {
|
|
|
47
47
|
checkDependencies2,
|
|
48
48
|
emitBuiltInIntegrationConnectedOnce2,
|
|
49
49
|
init_db3
|
|
50
|
-
} from "./cli-
|
|
50
|
+
} from "./cli-re4wkbzx.js";
|
|
51
51
|
import {
|
|
52
52
|
getChannelBlockReason2
|
|
53
|
-
} from "./cli-
|
|
53
|
+
} from "./cli-9e9kjqsj.js";
|
|
54
54
|
import {
|
|
55
55
|
require_jsonwebtoken,
|
|
56
56
|
require_dist5,
|
|
@@ -67,7 +67,7 @@ import {
|
|
|
67
67
|
import {
|
|
68
68
|
isTerminalTaskStatus,
|
|
69
69
|
init_types
|
|
70
|
-
} from "./cli-
|
|
70
|
+
} from "./cli-yv0vgscc.js";
|
|
71
71
|
import {
|
|
72
72
|
taskAttachmentDisplayUrl,
|
|
73
73
|
init_task_attachment_links
|
|
@@ -6235,7 +6235,7 @@ async function initOtel(serviceRole = process.env.AGENT_ROLE || "api") {
|
|
|
6235
6235
|
return;
|
|
6236
6236
|
initialized = true;
|
|
6237
6237
|
try {
|
|
6238
|
-
const impl = await import("./otel-impl-
|
|
6238
|
+
const impl = await import("./otel-impl-g8fh4c21.js");
|
|
6239
6239
|
await impl.boot(serviceRole, {
|
|
6240
6240
|
exportConsoleLogs: serviceRole === "api" && isApiLogExportEnabled()
|
|
6241
6241
|
});
|
|
@@ -10071,17 +10071,17 @@ async function initSlackApp2() {
|
|
|
10071
10071
|
});
|
|
10072
10072
|
initialized2 = true;
|
|
10073
10073
|
app.use(slackInboundOutcomeMiddleware());
|
|
10074
|
-
const { registerMessageHandler } = await import("./handlers-
|
|
10075
|
-
const { registerCommandHandler } = await import("./commands-
|
|
10076
|
-
const { registerActionHandlers } = await import("./actions-
|
|
10077
|
-
const { registerWorkObjectHandlers } = await import("./work-objects-
|
|
10074
|
+
const { registerMessageHandler } = await import("./handlers-tb3xgjnm.js");
|
|
10075
|
+
const { registerCommandHandler } = await import("./commands-mrw1ph2w.js");
|
|
10076
|
+
const { registerActionHandlers } = await import("./actions-zgcxfspj.js");
|
|
10077
|
+
const { registerWorkObjectHandlers } = await import("./work-objects-yjp8de12.js");
|
|
10078
10078
|
registerMessageHandler(app);
|
|
10079
10079
|
registerCommandHandler(app);
|
|
10080
10080
|
registerActionHandlers(app);
|
|
10081
10081
|
registerWorkObjectHandlers(app);
|
|
10082
|
-
const { createAssistant } = await import("./assistant-
|
|
10082
|
+
const { createAssistant } = await import("./assistant-v238n9dk.js");
|
|
10083
10083
|
app.assistant(createAssistant());
|
|
10084
|
-
const { isBlockExternalEnabled, scanExternalChannelsOnBoot } = await import("./external-channel-
|
|
10084
|
+
const { isBlockExternalEnabled, scanExternalChannelsOnBoot } = await import("./external-channel-j6vb6ya1.js");
|
|
10085
10085
|
if (isBlockExternalEnabled()) {
|
|
10086
10086
|
scanExternalChannelsOnBoot(app.client).catch((error) => {
|
|
10087
10087
|
console.error("[Slack] External channel boot scan failed:", error);
|
|
@@ -10094,7 +10094,7 @@ async function startSlackApp2() {
|
|
|
10094
10094
|
await initSlackApp2();
|
|
10095
10095
|
}
|
|
10096
10096
|
if (app) {
|
|
10097
|
-
const { isSlackRenderV2Enabled } = await import("./render-v2-
|
|
10097
|
+
const { isSlackRenderV2Enabled } = await import("./render-v2-0pyb39bb.js");
|
|
10098
10098
|
if (isSlackRenderV2Enabled())
|
|
10099
10099
|
await ensureSlackRenderV2Activation2();
|
|
10100
10100
|
await app.start();
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
injectTraceContext2,
|
|
24
24
|
initialize,
|
|
25
25
|
ensure
|
|
26
|
-
} from "./cli-
|
|
26
|
+
} from "./cli-dxwh4j32.js";
|
|
27
27
|
import {
|
|
28
28
|
getContextWindowSize
|
|
29
29
|
} from "./cli-jhp7w1fy.js";
|
|
@@ -44,7 +44,7 @@ import {
|
|
|
44
44
|
canonicalAzureDevOpsRepoUrl,
|
|
45
45
|
parseAzureDevOpsRepoUrl,
|
|
46
46
|
resolveScriptsOnlyMode
|
|
47
|
-
} from "./cli-
|
|
47
|
+
} from "./cli-8qsx817b.js";
|
|
48
48
|
import {
|
|
49
49
|
ACP_TARGET_IDS,
|
|
50
50
|
isAcpTarget
|
|
@@ -52,32 +52,32 @@ import {
|
|
|
52
52
|
import {
|
|
53
53
|
checkAmpCredentials2,
|
|
54
54
|
liveTestAmpCredentials2
|
|
55
|
-
} from "./cli-
|
|
55
|
+
} from "./cli-6p7ddg72.js";
|
|
56
56
|
import {
|
|
57
57
|
checkClaudeCredentials2
|
|
58
|
-
} from "./cli-
|
|
58
|
+
} from "./cli-hn3pftj2.js";
|
|
59
59
|
import {
|
|
60
60
|
checkClaudeManagedCredentials2
|
|
61
61
|
} from "./cli-j0v75y13.js";
|
|
62
62
|
import {
|
|
63
63
|
codexUserHome,
|
|
64
64
|
checkCodexCredentials2
|
|
65
|
-
} from "./cli-
|
|
65
|
+
} from "./cli-tr24eeny.js";
|
|
66
66
|
import {
|
|
67
67
|
checkCursorCredentials2
|
|
68
|
-
} from "./cli-
|
|
68
|
+
} from "./cli-4s1kqrqg.js";
|
|
69
69
|
import {
|
|
70
70
|
checkDevinCredentials2
|
|
71
71
|
} from "./cli-zv4vy2b0.js";
|
|
72
72
|
import {
|
|
73
73
|
checkDshCredentials2
|
|
74
|
-
} from "./cli-
|
|
74
|
+
} from "./cli-zes4tsbb.js";
|
|
75
75
|
import {
|
|
76
76
|
checkOpencodeCredentials2
|
|
77
77
|
} from "./cli-rc3r0bnh.js";
|
|
78
78
|
import {
|
|
79
79
|
checkGrokCredentials2
|
|
80
|
-
} from "./cli-
|
|
80
|
+
} from "./cli-0rh20bp3.js";
|
|
81
81
|
import {
|
|
82
82
|
isLeadChannelMonitoringEnabled,
|
|
83
83
|
renderMemoriesPrompt,
|
|
@@ -92,7 +92,7 @@ import {
|
|
|
92
92
|
} from "./cli-j4bwnpkm.js";
|
|
93
93
|
import {
|
|
94
94
|
validateJsonSchema
|
|
95
|
-
} from "./cli-
|
|
95
|
+
} from "./cli-jhmjwqcg.js";
|
|
96
96
|
import {
|
|
97
97
|
mapTriggerSurface,
|
|
98
98
|
init_telemetry_context,
|
|
@@ -110,7 +110,7 @@ import {
|
|
|
110
110
|
init_vcs_repo_match,
|
|
111
111
|
isApiDrainingResponse,
|
|
112
112
|
init_api_drain
|
|
113
|
-
} from "./cli-
|
|
113
|
+
} from "./cli-re4wkbzx.js";
|
|
114
114
|
import {
|
|
115
115
|
parseWorkerModelTierOverrides,
|
|
116
116
|
resolveTaskModelSelection,
|
|
@@ -118,7 +118,7 @@ import {
|
|
|
118
118
|
ProviderNameSchema,
|
|
119
119
|
WorkerNudgeSchema,
|
|
120
120
|
init_types
|
|
121
|
-
} from "./cli-
|
|
121
|
+
} from "./cli-yv0vgscc.js";
|
|
122
122
|
import {
|
|
123
123
|
generateDefaultClaudeMd2,
|
|
124
124
|
generateDefaultSoulMd2,
|
|
@@ -241,7 +241,7 @@ async function materializeCodexAuthJson(_slot, creds, deps = {}) {
|
|
|
241
241
|
async function createProviderAdapter(provider) {
|
|
242
242
|
switch (provider) {
|
|
243
243
|
case "claude": {
|
|
244
|
-
const { ClaudeAdapter } = await import("./claude-adapter-
|
|
244
|
+
const { ClaudeAdapter } = await import("./claude-adapter-q7wspzt8.js");
|
|
245
245
|
return new ClaudeAdapter;
|
|
246
246
|
}
|
|
247
247
|
case "pi": {
|
|
@@ -249,7 +249,7 @@ async function createProviderAdapter(provider) {
|
|
|
249
249
|
return new PiMonoAdapter;
|
|
250
250
|
}
|
|
251
251
|
case "codex": {
|
|
252
|
-
const { CodexAdapter } = await import("./codex-adapter-
|
|
252
|
+
const { CodexAdapter } = await import("./codex-adapter-nhjj2veb.js");
|
|
253
253
|
return new CodexAdapter;
|
|
254
254
|
}
|
|
255
255
|
case "claude-managed": {
|
|
@@ -265,23 +265,23 @@ async function createProviderAdapter(provider) {
|
|
|
265
265
|
return new OpencodeAdapter;
|
|
266
266
|
}
|
|
267
267
|
case "dsh": {
|
|
268
|
-
const { DshAdapter } = await import("./dsh-adapter-
|
|
268
|
+
const { DshAdapter } = await import("./dsh-adapter-fbx06re2.js");
|
|
269
269
|
return new DshAdapter;
|
|
270
270
|
}
|
|
271
271
|
case "amp": {
|
|
272
|
-
const { AmpAdapter } = await import("./amp-adapter-
|
|
272
|
+
const { AmpAdapter } = await import("./amp-adapter-jw9xfz42.js");
|
|
273
273
|
return new AmpAdapter;
|
|
274
274
|
}
|
|
275
275
|
case "cursor": {
|
|
276
|
-
const { CursorAdapter } = await import("./cursor-adapter-
|
|
276
|
+
const { CursorAdapter } = await import("./cursor-adapter-cf4zh5x0.js");
|
|
277
277
|
return new CursorAdapter;
|
|
278
278
|
}
|
|
279
279
|
case "grok": {
|
|
280
|
-
const { GrokAdapter } = await import("./grok-adapter-
|
|
280
|
+
const { GrokAdapter } = await import("./grok-adapter-1193sprp.js");
|
|
281
281
|
return new GrokAdapter;
|
|
282
282
|
}
|
|
283
283
|
case "acp": {
|
|
284
|
-
const { ACPAdapter } = await import("./acp-adapter-
|
|
284
|
+
const { ACPAdapter } = await import("./acp-adapter-v85a2bqy.js");
|
|
285
285
|
return new ACPAdapter;
|
|
286
286
|
}
|
|
287
287
|
default:
|
|
@@ -1443,7 +1443,7 @@ async function validateProviderCredentials(provider, env = process.env, presence
|
|
|
1443
1443
|
latency_ms: Date.now() - startedAt
|
|
1444
1444
|
};
|
|
1445
1445
|
}
|
|
1446
|
-
const { liveTestCursorKey } = await import("./cursor-adapter-
|
|
1446
|
+
const { liveTestCursorKey } = await import("./cursor-adapter-cf4zh5x0.js");
|
|
1447
1447
|
const result = await liveTestCursorKey(apiKey);
|
|
1448
1448
|
return result.ok ? { ok: true, latency_ms: Date.now() - startedAt } : { ok: false, error: result.error, latency_ms: Date.now() - startedAt };
|
|
1449
1449
|
}
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
CONTROLLER_COMMAND_TIMEOUT_MS,
|
|
5
5
|
RuntimeHandleSchema,
|
|
6
6
|
ControllerStatusResultSchema
|
|
7
|
-
} from "./cli-
|
|
7
|
+
} from "./cli-d43xqzbe.js";
|
|
8
8
|
import {
|
|
9
9
|
getDbClient2,
|
|
10
10
|
isRuntimePoolsEnabled,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
upsertSwarmConfig2,
|
|
22
22
|
getResolvedConfig2,
|
|
23
23
|
init_db3
|
|
24
|
-
} from "./cli-
|
|
24
|
+
} from "./cli-re4wkbzx.js";
|
|
25
25
|
import {
|
|
26
26
|
runtimeStaleThresholdMinutes,
|
|
27
27
|
getRuntimeInstanceById,
|
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
listRuntimeInstancesForPool,
|
|
32
32
|
createWorkerTaskFollowUp,
|
|
33
33
|
canClaim
|
|
34
|
-
} from "./cli-
|
|
34
|
+
} from "./cli-8qsx817b.js";
|
|
35
35
|
import {
|
|
36
36
|
mintRuntimeToken,
|
|
37
37
|
init_users,
|
|
@@ -44,7 +44,7 @@ import {
|
|
|
44
44
|
getPoolForAgent2,
|
|
45
45
|
resolvePoolDelivery2,
|
|
46
46
|
init_db
|
|
47
|
-
} from "./cli-
|
|
47
|
+
} from "./cli-hz64bcnj.js";
|
|
48
48
|
import {
|
|
49
49
|
workflowEventBus2,
|
|
50
50
|
init_event_bus
|
|
@@ -64,7 +64,7 @@ import {
|
|
|
64
64
|
TERMINAL_TASK_STATUSES,
|
|
65
65
|
isTerminalTaskStatus,
|
|
66
66
|
init_types
|
|
67
|
-
} from "./cli-
|
|
67
|
+
} from "./cli-yv0vgscc.js";
|
|
68
68
|
import {
|
|
69
69
|
init_zod
|
|
70
70
|
} from "./cli-4chz1hye.js";
|
|
@@ -520,7 +520,7 @@ async function recoverSessions(runtimeId, reason) {
|
|
|
520
520
|
}
|
|
521
521
|
if (!sessions.length)
|
|
522
522
|
return;
|
|
523
|
-
const { remediateTaskForDeadRuntime } = await import("./heartbeat-
|
|
523
|
+
const { remediateTaskForDeadRuntime } = await import("./heartbeat-h1w1ktce.js");
|
|
524
524
|
for (const session of sessions) {
|
|
525
525
|
try {
|
|
526
526
|
const task = await getTaskById2(session.taskId);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runStopHookSessionSummarySubprocess
|
|
3
|
-
} from "./cli-
|
|
3
|
+
} from "./cli-1v8w782f.js";
|
|
4
4
|
import {
|
|
5
5
|
CONTEXT_FORMULA,
|
|
6
6
|
getContextWindowSize,
|
|
@@ -1236,7 +1236,7 @@ class ClaudeAdapter2 {
|
|
|
1236
1236
|
if (transport === "sdk" && isClaudeBridgeEffective(sourceEnv)) {
|
|
1237
1237
|
throw new Error("CLAUDE_TRANSPORT=sdk cannot run with an effective Claude Bridge configuration. Select CLI transport or disable the bridge.");
|
|
1238
1238
|
}
|
|
1239
|
-
const claudeSdk = transport === "sdk" ? await import("./claude-sdk-session-
|
|
1239
|
+
const claudeSdk = transport === "sdk" ? await import("./claude-sdk-session-yf400ptr.js") : undefined;
|
|
1240
1240
|
claudeSdk?.validateClaudeSdkAdditionalArgs([
|
|
1241
1241
|
...claudeBinaryArgv.slice(1),
|
|
1242
1242
|
...config.additionalArgs ?? []
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
init_secret_registry,
|
|
19
19
|
upsertSwarmConfig2,
|
|
20
20
|
init_db3
|
|
21
|
-
} from "./cli-
|
|
21
|
+
} from "./cli-re4wkbzx.js";
|
|
22
22
|
import {
|
|
23
23
|
createRuntimeProvider,
|
|
24
24
|
init_runtime_providers
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
RuntimePoolUpdateSchema,
|
|
31
31
|
RuntimePoolCreateAgentSchema,
|
|
32
32
|
init_types
|
|
33
|
-
} from "./cli-
|
|
33
|
+
} from "./cli-yv0vgscc.js";
|
|
34
34
|
import {
|
|
35
35
|
scrubSecrets,
|
|
36
36
|
registerVolatileSecret,
|
|
@@ -39,7 +39,7 @@ import {
|
|
|
39
39
|
getPendingWaitsByEvent2,
|
|
40
40
|
resolveWaitState2,
|
|
41
41
|
init_db3
|
|
42
|
-
} from "./cli-
|
|
42
|
+
} from "./cli-re4wkbzx.js";
|
|
43
43
|
import {
|
|
44
44
|
BaseExecutor,
|
|
45
45
|
postApprovalCancellationUpdates,
|
|
@@ -50,7 +50,7 @@ import {
|
|
|
50
50
|
findEntryNodes,
|
|
51
51
|
resolveValidationPort,
|
|
52
52
|
getSuccessors
|
|
53
|
-
} from "./cli-
|
|
53
|
+
} from "./cli-q1812jbw.js";
|
|
54
54
|
import {
|
|
55
55
|
workflowEventBus2,
|
|
56
56
|
init_event_bus
|
|
@@ -58,7 +58,7 @@ import {
|
|
|
58
58
|
import {
|
|
59
59
|
RetryPolicySchema,
|
|
60
60
|
init_types
|
|
61
|
-
} from "./cli-
|
|
61
|
+
} from "./cli-yv0vgscc.js";
|
|
62
62
|
import {
|
|
63
63
|
getSlackConfiguration,
|
|
64
64
|
isSlackConfigured,
|
|
@@ -106,7 +106,7 @@ async function notifyAutomationPreflightFailure(preflight) {
|
|
|
106
106
|
return;
|
|
107
107
|
}
|
|
108
108
|
try {
|
|
109
|
-
const { getSlackApp } = await import("./app-
|
|
109
|
+
const { getSlackApp } = await import("./app-4e1s4675.js");
|
|
110
110
|
const app = getSlackApp();
|
|
111
111
|
if (!app) {
|
|
112
112
|
console.warn("[Automation Preflight] Slack not available, cannot send notification");
|
|
@@ -1434,7 +1434,7 @@ async function runClaimedStep(def, runId, ctx, node, registry, existingStep, ste
|
|
|
1434
1434
|
if ("async" in result && result.async) {
|
|
1435
1435
|
const waiting = await checkpointStepWaiting(runId, stepId, ctx);
|
|
1436
1436
|
if (waiting && result.waitFor === "workflow.child.finished") {
|
|
1437
|
-
const { resumeFromChildRun } = await import("./resume-
|
|
1437
|
+
const { resumeFromChildRun } = await import("./resume-a86tkj6r.js");
|
|
1438
1438
|
await resumeFromChildRun(stepId, registry);
|
|
1439
1439
|
}
|
|
1440
1440
|
return { outcome: waiting ? "waiting" : "completed", successors: [] };
|
|
@@ -64,8 +64,9 @@ import {
|
|
|
64
64
|
resolveApprovalRequest2,
|
|
65
65
|
getExpiredPendingApprovals2,
|
|
66
66
|
getStaleApprovalRequests2,
|
|
67
|
+
upsertKv2,
|
|
67
68
|
init_db3
|
|
68
|
-
} from "./cli-
|
|
69
|
+
} from "./cli-re4wkbzx.js";
|
|
69
70
|
import {
|
|
70
71
|
poolTaskRunsOnHarness,
|
|
71
72
|
isRuntimePoolWakeable,
|
|
@@ -90,26 +91,26 @@ import {
|
|
|
90
91
|
createRerouteDecisionTask,
|
|
91
92
|
createPoolStarvationDecisionTask,
|
|
92
93
|
canClaim
|
|
93
|
-
} from "./cli-
|
|
94
|
+
} from "./cli-8qsx817b.js";
|
|
94
95
|
import {
|
|
95
96
|
mintToken,
|
|
96
97
|
init_users,
|
|
97
98
|
listRuntimePools2,
|
|
98
99
|
init_db
|
|
99
|
-
} from "./cli-
|
|
100
|
+
} from "./cli-hz64bcnj.js";
|
|
100
101
|
import {
|
|
101
102
|
createApprovalFollowUpTask
|
|
102
|
-
} from "./cli-
|
|
103
|
+
} from "./cli-q1812jbw.js";
|
|
103
104
|
import {
|
|
104
105
|
remediateStalledRuntime
|
|
105
|
-
} from "./cli-
|
|
106
|
+
} from "./cli-fp4xbw07.js";
|
|
106
107
|
import {
|
|
107
108
|
runSavedScriptAsAgent
|
|
108
|
-
} from "./cli-
|
|
109
|
+
} from "./cli-65q70v2v.js";
|
|
109
110
|
import {
|
|
110
111
|
TERMINAL_TASK_STATUSES,
|
|
111
112
|
init_types
|
|
112
|
-
} from "./cli-
|
|
113
|
+
} from "./cli-yv0vgscc.js";
|
|
113
114
|
import {
|
|
114
115
|
registerTemplate,
|
|
115
116
|
init_registry,
|
|
@@ -124,7 +125,7 @@ import {
|
|
|
124
125
|
import {
|
|
125
126
|
init_package,
|
|
126
127
|
package_default
|
|
127
|
-
} from "./cli-
|
|
128
|
+
} from "./cli-5d1m1qca.js";
|
|
128
129
|
import {
|
|
129
130
|
isEnvFlagEnabled,
|
|
130
131
|
init_env_flag
|
|
@@ -1347,6 +1348,7 @@ async function gatherSystemStatus(options) {
|
|
|
1347
1348
|
}
|
|
1348
1349
|
}
|
|
1349
1350
|
const recentFailures = await getRecentFailedTasks2(6);
|
|
1351
|
+
const renderedFailures = recentFailures.slice(0, 10);
|
|
1350
1352
|
if (recentFailures.length > 0) {
|
|
1351
1353
|
sections.push("");
|
|
1352
1354
|
sections.push("## Recent Failures (last 6h) [auto-generated]");
|
|
@@ -1367,10 +1369,12 @@ async function gatherSystemStatus(options) {
|
|
|
1367
1369
|
}
|
|
1368
1370
|
}
|
|
1369
1371
|
sections.push("");
|
|
1370
|
-
for (const task of
|
|
1372
|
+
for (const task of renderedFailures) {
|
|
1371
1373
|
const agentSlice = task.agentId?.slice(0, 8) ?? "unassigned";
|
|
1372
1374
|
const reason = task.failureReason?.slice(0, 100) ?? "no reason";
|
|
1373
|
-
|
|
1375
|
+
const line = `- [${task.id.slice(0, 8)}] "${task.task.slice(0, 50)}" — agent: ${agentSlice}, reason: ${reason}, at: ${task.finishedAt}`;
|
|
1376
|
+
sections.push(line);
|
|
1377
|
+
options?.reportedFailures?.push({ id: task.id, line });
|
|
1374
1378
|
}
|
|
1375
1379
|
if (recentFailures.length > 10) {
|
|
1376
1380
|
sections.push(`- ... and ${recentFailures.length - 10} more`);
|
|
@@ -1527,7 +1531,8 @@ async function checkHeartbeatChecklist2() {
|
|
|
1527
1531
|
console.log(`[Heartbeat] Checklist skipped for lead ${lead.name}: quiet tick`);
|
|
1528
1532
|
return;
|
|
1529
1533
|
}
|
|
1530
|
-
|
|
1534
|
+
const reportedFailures = [];
|
|
1535
|
+
let systemStatus = await gatherSystemStatus({ reportedFailures });
|
|
1531
1536
|
if (gateMode === "enforce" && gate?.verdict === "wake" && gate.summary) {
|
|
1532
1537
|
const findings = resolveTemplate("heartbeat.checklist.gate_findings", {
|
|
1533
1538
|
gate_summary: gate.summary
|
|
@@ -1543,7 +1548,7 @@ ${findings.text}`;
|
|
|
1543
1548
|
});
|
|
1544
1549
|
if (result.skipped)
|
|
1545
1550
|
return;
|
|
1546
|
-
await createTaskExtended2(result.text, {
|
|
1551
|
+
const task = await createTaskExtended2(result.text, {
|
|
1547
1552
|
agentId: lead.id,
|
|
1548
1553
|
routingReason: "skill",
|
|
1549
1554
|
routingSource: "engine_default",
|
|
@@ -1552,6 +1557,17 @@ ${findings.text}`;
|
|
|
1552
1557
|
tags: ["checklist", "auto-generated", ...gate ? [`heartbeat-gate:${gate.verdict}`] : []],
|
|
1553
1558
|
priority: 60
|
|
1554
1559
|
});
|
|
1560
|
+
try {
|
|
1561
|
+
await upsertKv2({
|
|
1562
|
+
namespace: "heartbeat-checklist:reported-failures",
|
|
1563
|
+
key: task.id,
|
|
1564
|
+
value: reportedFailures.filter(({ line }) => result.text.includes(line)).map(({ id }) => id),
|
|
1565
|
+
valueType: "json",
|
|
1566
|
+
expiresAt: Date.now() + 7 * 24 * 3600000
|
|
1567
|
+
});
|
|
1568
|
+
} catch (err) {
|
|
1569
|
+
console.error(`[Heartbeat] Failed to save reported failures for checklist ${task.id}:`, err);
|
|
1570
|
+
}
|
|
1555
1571
|
console.log(`[Heartbeat] Checklist task created for lead ${lead.name}`);
|
|
1556
1572
|
}
|
|
1557
1573
|
async function runHeartbeatSweep2() {
|
|
@@ -4,11 +4,11 @@ import {
|
|
|
4
4
|
getActivePricingRow2,
|
|
5
5
|
insertPricingRow2,
|
|
6
6
|
init_db3
|
|
7
|
-
} from "./cli-
|
|
7
|
+
} from "./cli-re4wkbzx.js";
|
|
8
8
|
import {
|
|
9
9
|
loadModelsDevCache,
|
|
10
10
|
buildModelsDevSeedRows
|
|
11
|
-
} from "./cli-
|
|
11
|
+
} from "./cli-qrwp40st.js";
|
|
12
12
|
import {
|
|
13
13
|
setRuntimeModelCatalog,
|
|
14
14
|
init_runtime_model_catalog
|
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
completeApprovalCancellationNotificationClaim2,
|
|
6
6
|
releaseApprovalCancellationNotificationClaim2,
|
|
7
7
|
init_db3
|
|
8
|
-
} from "./cli-
|
|
8
|
+
} from "./cli-re4wkbzx.js";
|
|
9
9
|
import {
|
|
10
10
|
getSlackApp2
|
|
11
|
-
} from "./cli-
|
|
11
|
+
} from "./cli-dxwh4j32.js";
|
|
12
12
|
import {
|
|
13
13
|
DEFAULT_MODEL,
|
|
14
14
|
resolveCredential
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
import {
|
|
17
17
|
TERMINAL_TASK_STATUSES,
|
|
18
18
|
init_types
|
|
19
|
-
} from "./cli-
|
|
19
|
+
} from "./cli-yv0vgscc.js";
|
|
20
20
|
import {
|
|
21
21
|
selectCredential,
|
|
22
22
|
init_credentials
|
|
@@ -454,7 +454,7 @@ class HumanInTheLoopExecutor extends BaseExecutor {
|
|
|
454
454
|
}
|
|
455
455
|
if (notification.channel === "slack") {
|
|
456
456
|
try {
|
|
457
|
-
const { getSlackApp } = await import("./app-
|
|
457
|
+
const { getSlackApp } = await import("./app-4e1s4675.js");
|
|
458
458
|
const slackApp = getSlackApp();
|
|
459
459
|
if (!slackApp) {
|
|
460
460
|
console.warn("[HITL] Slack not initialized — cannot send notification");
|