@integrity-labs/agt-cli 0.27.136 → 0.27.138
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/bin/agt.js +4 -4
- package/dist/{chunk-HDWKI7W3.js → chunk-PDDU4Z5V.js} +2045 -2028
- package/dist/chunk-PDDU4Z5V.js.map +1 -0
- package/dist/{chunk-75QM5THV.js → chunk-RT37WJXI.js} +17 -2
- package/dist/{chunk-75QM5THV.js.map → chunk-RT37WJXI.js.map} +1 -1
- package/dist/{chunk-4B6KOQQL.js → chunk-SCZVYC5P.js} +522 -522
- package/dist/chunk-SCZVYC5P.js.map +1 -0
- package/dist/{claude-pair-runtime-A5IITZ6J.js → claude-pair-runtime-CNTCM57R.js} +2 -2
- package/dist/lib/manager-worker.js +41 -14
- package/dist/lib/manager-worker.js.map +1 -1
- package/dist/mcp/slack-channel.js +146 -69
- package/dist/mcp/telegram-channel.js +178 -49
- package/dist/{persistent-session-5N5NFU27.js → persistent-session-WWEAEEL4.js} +3 -3
- package/dist/{responsiveness-probe-6L6WKHK5.js → responsiveness-probe-MCKI22FY.js} +3 -3
- package/package.json +1 -1
- package/dist/chunk-4B6KOQQL.js.map +0 -1
- package/dist/chunk-HDWKI7W3.js.map +0 -1
- /package/dist/{claude-pair-runtime-A5IITZ6J.js.map → claude-pair-runtime-CNTCM57R.js.map} +0 -0
- /package/dist/{persistent-session-5N5NFU27.js.map → persistent-session-WWEAEEL4.js.map} +0 -0
- /package/dist/{responsiveness-probe-6L6WKHK5.js.map → responsiveness-probe-MCKI22FY.js.map} +0 -0
|
@@ -100,7 +100,7 @@ async function spawnPairSession(session) {
|
|
|
100
100
|
return { ok: true };
|
|
101
101
|
} catch {
|
|
102
102
|
}
|
|
103
|
-
const { resolveClaudeBinary } = await import("./persistent-session-
|
|
103
|
+
const { resolveClaudeBinary } = await import("./persistent-session-WWEAEEL4.js");
|
|
104
104
|
const claudeBin = resolveClaudeBinary();
|
|
105
105
|
const pairEnv = {
|
|
106
106
|
...process.env,
|
|
@@ -373,4 +373,4 @@ export {
|
|
|
373
373
|
startClaudePair,
|
|
374
374
|
submitClaudePairCode
|
|
375
375
|
};
|
|
376
|
-
//# sourceMappingURL=claude-pair-runtime-
|
|
376
|
+
//# sourceMappingURL=claude-pair-runtime-CNTCM57R.js.map
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
provisionStopHook,
|
|
18
18
|
requireHost,
|
|
19
19
|
safeWriteJsonAtomic
|
|
20
|
-
} from "../chunk-
|
|
20
|
+
} from "../chunk-SCZVYC5P.js";
|
|
21
21
|
import {
|
|
22
22
|
getProjectDir as getProjectDir2,
|
|
23
23
|
getReadyTasks,
|
|
@@ -29,6 +29,7 @@ import {
|
|
|
29
29
|
buildAllowedTools,
|
|
30
30
|
checkChannelInputs,
|
|
31
31
|
creditWatchdogGiveUpCount,
|
|
32
|
+
expandTemplateVars,
|
|
32
33
|
formatMissingVar,
|
|
33
34
|
getLastFailureContext,
|
|
34
35
|
getProjectDir,
|
|
@@ -56,7 +57,7 @@ import {
|
|
|
56
57
|
stopPersistentSession,
|
|
57
58
|
takeWatchdogGiveUpCount,
|
|
58
59
|
takeZombieDetection
|
|
59
|
-
} from "../chunk-
|
|
60
|
+
} from "../chunk-RT37WJXI.js";
|
|
60
61
|
import {
|
|
61
62
|
KANBAN_CHECK_COMMAND,
|
|
62
63
|
SUPPRESS_SENTINEL,
|
|
@@ -83,7 +84,7 @@ import {
|
|
|
83
84
|
resolveDmTarget,
|
|
84
85
|
worseConnectivityOutcome,
|
|
85
86
|
wrapScheduledTaskPrompt
|
|
86
|
-
} from "../chunk-
|
|
87
|
+
} from "../chunk-PDDU4Z5V.js";
|
|
87
88
|
import {
|
|
88
89
|
parsePsRows,
|
|
89
90
|
reapOrphanChannelMcps
|
|
@@ -4412,13 +4413,26 @@ function projectMcpKeys(_codeName, projectDir) {
|
|
|
4412
4413
|
return null;
|
|
4413
4414
|
}
|
|
4414
4415
|
}
|
|
4415
|
-
function readMcpHttpServerConfig(projectDir, serverKey) {
|
|
4416
|
+
function readMcpHttpServerConfig(projectDir, serverKey, env) {
|
|
4416
4417
|
try {
|
|
4417
4418
|
const raw = readFileSync9(join8(projectDir, ".mcp.json"), "utf-8");
|
|
4418
4419
|
const servers = JSON.parse(raw).mcpServers ?? {};
|
|
4419
4420
|
const entry = servers[serverKey];
|
|
4420
4421
|
if (entry && typeof entry.url === "string" && (entry.type === "http" || entry.type === void 0)) {
|
|
4421
|
-
|
|
4422
|
+
const unresolved = /* @__PURE__ */ new Set();
|
|
4423
|
+
const sub = (value) => {
|
|
4424
|
+
if (!env) return value;
|
|
4425
|
+
const r = expandTemplateVars(value, env);
|
|
4426
|
+
for (const name of r.unresolved) unresolved.add(name);
|
|
4427
|
+
return r.value;
|
|
4428
|
+
};
|
|
4429
|
+
const url = sub(entry.url);
|
|
4430
|
+
let headers;
|
|
4431
|
+
if (entry.headers) {
|
|
4432
|
+
headers = {};
|
|
4433
|
+
for (const [k, v] of Object.entries(entry.headers)) headers[k] = sub(v);
|
|
4434
|
+
}
|
|
4435
|
+
return { url, ...headers ? { headers } : {}, unresolved: [...unresolved] };
|
|
4422
4436
|
}
|
|
4423
4437
|
return null;
|
|
4424
4438
|
} catch {
|
|
@@ -4439,10 +4453,16 @@ async function runAgentConnectivityProbes(agent, integrations, projectDir) {
|
|
|
4439
4453
|
fetchImpl: fetch,
|
|
4440
4454
|
runCli: (binary, args) => runCliProbe(binary, args, { env: probeEnv }),
|
|
4441
4455
|
mcpProbe: async (target) => {
|
|
4442
|
-
const cfg = readMcpHttpServerConfig(projectDir, target.serverKey);
|
|
4456
|
+
const cfg = readMcpHttpServerConfig(projectDir, target.serverKey, probeEnv);
|
|
4443
4457
|
if (!cfg) {
|
|
4444
4458
|
return { status: "transient_error", message: `MCP server '${target.serverKey}' not resolvable from .mcp.json` };
|
|
4445
4459
|
}
|
|
4460
|
+
if (cfg.unresolved.length > 0) {
|
|
4461
|
+
return {
|
|
4462
|
+
status: "transient_error",
|
|
4463
|
+
message: `MCP '${target.serverKey}' auth unresolved: ${cfg.unresolved.join(", ")}`
|
|
4464
|
+
};
|
|
4465
|
+
}
|
|
4446
4466
|
return probeMcpHttp(cfg);
|
|
4447
4467
|
},
|
|
4448
4468
|
// ENG-6139: connected-account binding check for managed (Composio) toolkits.
|
|
@@ -4453,10 +4473,16 @@ async function runAgentConnectivityProbes(agent, integrations, projectDir) {
|
|
|
4453
4473
|
// authenticates with these), plus the recorded connected_account_id.
|
|
4454
4474
|
composioProbe: async (definitionId, credentials) => {
|
|
4455
4475
|
const serverKey = definitionId.replace(/[^a-z0-9]/gi, "_").toLowerCase();
|
|
4456
|
-
const cfg = readMcpHttpServerConfig(projectDir, serverKey);
|
|
4476
|
+
const cfg = readMcpHttpServerConfig(projectDir, serverKey, probeEnv);
|
|
4457
4477
|
if (!cfg) {
|
|
4458
4478
|
return { status: "transient_error", message: `MCP server '${serverKey}' not resolvable from .mcp.json` };
|
|
4459
4479
|
}
|
|
4480
|
+
if (cfg.unresolved.length > 0) {
|
|
4481
|
+
return {
|
|
4482
|
+
status: "transient_error",
|
|
4483
|
+
message: `MCP '${serverKey}' auth unresolved: ${cfg.unresolved.join(", ")}`
|
|
4484
|
+
};
|
|
4485
|
+
}
|
|
4460
4486
|
const apiKey = cfg.headers?.["x-api-key"] ?? cfg.headers?.["X-API-Key"] ?? "";
|
|
4461
4487
|
let expectedUserId = "";
|
|
4462
4488
|
let serverId;
|
|
@@ -4476,8 +4502,9 @@ async function runAgentConnectivityProbes(agent, integrations, projectDir) {
|
|
|
4476
4502
|
// linkage surfaces as a real `No connected account found` instead of a
|
|
4477
4503
|
// green handshake. Skips (`null`) when no safe read-only tool is callable.
|
|
4478
4504
|
composioToolCallProbe: async (target) => {
|
|
4479
|
-
const cfg = readMcpHttpServerConfig(projectDir, target.serverKey);
|
|
4505
|
+
const cfg = readMcpHttpServerConfig(projectDir, target.serverKey, probeEnv);
|
|
4480
4506
|
if (!cfg) return null;
|
|
4507
|
+
if (cfg.unresolved.length > 0) return null;
|
|
4481
4508
|
return probeComposioMcpToolCall({ url: cfg.url, headers: cfg.headers });
|
|
4482
4509
|
}
|
|
4483
4510
|
};
|
|
@@ -4691,7 +4718,7 @@ var cachedMaintenanceWindow = null;
|
|
|
4691
4718
|
var lastVersionCheckAt = 0;
|
|
4692
4719
|
var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
|
|
4693
4720
|
var lastResponsivenessProbeAt = 0;
|
|
4694
|
-
var agtCliVersion = true ? "0.27.
|
|
4721
|
+
var agtCliVersion = true ? "0.27.138" : "dev";
|
|
4695
4722
|
function resolveBrewPath(execFileSync4) {
|
|
4696
4723
|
try {
|
|
4697
4724
|
const out = execFileSync4("which", ["brew"], { timeout: 5e3 }).toString().trim();
|
|
@@ -5889,7 +5916,7 @@ async function pollCycle() {
|
|
|
5889
5916
|
}
|
|
5890
5917
|
try {
|
|
5891
5918
|
const { detectHostSecurity } = await import("../host-security-6PDFG7F5.js");
|
|
5892
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
5919
|
+
const { collectDiagnostics } = await import("../persistent-session-WWEAEEL4.js");
|
|
5893
5920
|
const diagCodeNames = [...agentState.persistentSessionAgents];
|
|
5894
5921
|
const agentDiagnostics = diagCodeNames.length > 0 ? collectDiagnostics(diagCodeNames) : void 0;
|
|
5895
5922
|
let tailscaleHostname;
|
|
@@ -5976,12 +6003,12 @@ async function pollCycle() {
|
|
|
5976
6003
|
const {
|
|
5977
6004
|
collectResponsivenessProbes,
|
|
5978
6005
|
getResponsivenessIntervalMs
|
|
5979
|
-
} = await import("../responsiveness-probe-
|
|
6006
|
+
} = await import("../responsiveness-probe-MCKI22FY.js");
|
|
5980
6007
|
const probeIntervalMs = getResponsivenessIntervalMs();
|
|
5981
6008
|
if (now - lastResponsivenessProbeAt > probeIntervalMs) {
|
|
5982
6009
|
const probeCodeNames = [...agentState.persistentSessionAgents];
|
|
5983
6010
|
if (probeCodeNames.length > 0) {
|
|
5984
|
-
const { takeAcpxExecFailureCount, creditAcpxExecFailureCount } = await import("../persistent-session-
|
|
6011
|
+
const { takeAcpxExecFailureCount, creditAcpxExecFailureCount } = await import("../persistent-session-WWEAEEL4.js");
|
|
5985
6012
|
const drainedGiveUps = /* @__PURE__ */ new Map();
|
|
5986
6013
|
const drainedAcpxFailures = /* @__PURE__ */ new Map();
|
|
5987
6014
|
const probes = collectResponsivenessProbes(probeCodeNames).map((p) => {
|
|
@@ -6015,7 +6042,7 @@ async function pollCycle() {
|
|
|
6015
6042
|
collectResponsivenessProbes,
|
|
6016
6043
|
livePendingInboundOldestAgeSeconds,
|
|
6017
6044
|
deadLetterPendingInbound
|
|
6018
|
-
} = await import("../responsiveness-probe-
|
|
6045
|
+
} = await import("../responsiveness-probe-MCKI22FY.js");
|
|
6019
6046
|
const wedgeNow = /* @__PURE__ */ new Date();
|
|
6020
6047
|
const liveAgents = agentState.persistentSessionAgents;
|
|
6021
6048
|
for (const tracked of consecutiveWedgeCycles.keys()) {
|
|
@@ -10521,7 +10548,7 @@ async function processClaudePairSessions(agents) {
|
|
|
10521
10548
|
killPairSession,
|
|
10522
10549
|
pairTmuxSession,
|
|
10523
10550
|
finalizeClaudePairOnboarding
|
|
10524
|
-
} = await import("../claude-pair-runtime-
|
|
10551
|
+
} = await import("../claude-pair-runtime-CNTCM57R.js");
|
|
10525
10552
|
for (const pairId of pendingResp.cancelled_pair_ids ?? []) {
|
|
10526
10553
|
log(`[claude-pair] sweeping orphan tmux session for pair ${pairId.slice(0, 8)}`);
|
|
10527
10554
|
const killed = await killPairSession(pairTmuxSession(pairId));
|