@integrity-labs/agt-cli 0.28.247 → 0.28.249
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-6UPAGHRR.js → chunk-JIQM5K3C.js} +3 -3
- package/dist/{chunk-NFO3GOL3.js → chunk-UMXGONVE.js} +1 -1
- package/dist/{claude-pair-runtime-HHEVB5WF.js → claude-pair-runtime-S6LYZUEC.js} +2 -2
- package/dist/lib/manager-worker.js +28 -15
- package/dist/lib/manager-worker.js.map +1 -1
- package/dist/mcp/slack-channel.js +12 -8
- package/dist/{persistent-session-7BQ2OE2R.js → persistent-session-CHYTU6HG.js} +2 -2
- package/dist/{responsiveness-probe-MUY7HOGQ.js → responsiveness-probe-D74I4CS6.js} +2 -2
- package/package.json +1 -1
- /package/dist/{chunk-6UPAGHRR.js.map → chunk-JIQM5K3C.js.map} +0 -0
- /package/dist/{chunk-NFO3GOL3.js.map → chunk-UMXGONVE.js.map} +0 -0
- /package/dist/{claude-pair-runtime-HHEVB5WF.js.map → claude-pair-runtime-S6LYZUEC.js.map} +0 -0
- /package/dist/{persistent-session-7BQ2OE2R.js.map → persistent-session-CHYTU6HG.js.map} +0 -0
- /package/dist/{responsiveness-probe-MUY7HOGQ.js.map → responsiveness-probe-D74I4CS6.js.map} +0 -0
package/dist/bin/agt.js
CHANGED
|
@@ -38,7 +38,7 @@ import {
|
|
|
38
38
|
success,
|
|
39
39
|
table,
|
|
40
40
|
warn
|
|
41
|
-
} from "../chunk-
|
|
41
|
+
} from "../chunk-JIQM5K3C.js";
|
|
42
42
|
import {
|
|
43
43
|
CHANNEL_REGISTRY,
|
|
44
44
|
DEFAULT_FRAMEWORK,
|
|
@@ -67,7 +67,7 @@ import {
|
|
|
67
67
|
renderTemplate,
|
|
68
68
|
resolveChannels,
|
|
69
69
|
serializeManifestForSlackCli
|
|
70
|
-
} from "../chunk-
|
|
70
|
+
} from "../chunk-UMXGONVE.js";
|
|
71
71
|
import "../chunk-XWVM4KPK.js";
|
|
72
72
|
|
|
73
73
|
// src/bin/agt.ts
|
|
@@ -4826,7 +4826,7 @@ import { execFileSync, execSync } from "child_process";
|
|
|
4826
4826
|
import { existsSync as existsSync10, realpathSync as realpathSync2 } from "fs";
|
|
4827
4827
|
import chalk18 from "chalk";
|
|
4828
4828
|
import ora16 from "ora";
|
|
4829
|
-
var cliVersion = true ? "0.28.
|
|
4829
|
+
var cliVersion = true ? "0.28.249" : "dev";
|
|
4830
4830
|
async function fetchLatestVersion() {
|
|
4831
4831
|
const host2 = getHost();
|
|
4832
4832
|
if (!host2) return null;
|
|
@@ -5840,7 +5840,7 @@ function handleError(err) {
|
|
|
5840
5840
|
}
|
|
5841
5841
|
|
|
5842
5842
|
// src/bin/agt.ts
|
|
5843
|
-
var cliVersion2 = true ? "0.28.
|
|
5843
|
+
var cliVersion2 = true ? "0.28.249" : "dev";
|
|
5844
5844
|
var program = new Command();
|
|
5845
5845
|
program.name("agt").description("Augmented CLI \u2014 agent provisioning and management").version(cliVersion2).option("--json", "Emit machine-readable JSON output (suppress spinners and colors)").option("--skip-update-check", "Skip the automatic update check on startup");
|
|
5846
5846
|
program.hook("preAction", async (thisCommand, actionCommand) => {
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
resolveConnectivityProbe,
|
|
19
19
|
worseConnectivityOutcome,
|
|
20
20
|
wrapScheduledTaskPrompt
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-UMXGONVE.js";
|
|
22
22
|
import {
|
|
23
23
|
parsePsRows
|
|
24
24
|
} from "./chunk-XWVM4KPK.js";
|
|
@@ -5832,7 +5832,7 @@ function requireHost() {
|
|
|
5832
5832
|
}
|
|
5833
5833
|
|
|
5834
5834
|
// src/lib/api-client.ts
|
|
5835
|
-
var agtCliVersion = true ? "0.28.
|
|
5835
|
+
var agtCliVersion = true ? "0.28.249" : "dev";
|
|
5836
5836
|
var lastConfigHash = null;
|
|
5837
5837
|
function setConfigHash(hash) {
|
|
5838
5838
|
lastConfigHash = hash && hash.length > 0 ? hash : null;
|
|
@@ -8102,4 +8102,4 @@ export {
|
|
|
8102
8102
|
managerInstallSystemUnitCommand,
|
|
8103
8103
|
managerUninstallSystemUnitCommand
|
|
8104
8104
|
};
|
|
8105
|
-
//# sourceMappingURL=chunk-
|
|
8105
|
+
//# sourceMappingURL=chunk-JIQM5K3C.js.map
|
|
@@ -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-CHYTU6HG.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-S6LYZUEC.js.map
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
requireHost,
|
|
38
38
|
safeWriteJsonAtomic,
|
|
39
39
|
setConfigHash
|
|
40
|
-
} from "../chunk-
|
|
40
|
+
} from "../chunk-JIQM5K3C.js";
|
|
41
41
|
import {
|
|
42
42
|
getProjectDir as getProjectDir2,
|
|
43
43
|
getReadyTasks,
|
|
@@ -122,7 +122,7 @@ import {
|
|
|
122
122
|
takeZombieDetection,
|
|
123
123
|
transcriptActivityAgeSeconds,
|
|
124
124
|
writeEgressAllowlist
|
|
125
|
-
} from "../chunk-
|
|
125
|
+
} from "../chunk-UMXGONVE.js";
|
|
126
126
|
import {
|
|
127
127
|
reapOrphanChannelMcps
|
|
128
128
|
} from "../chunk-XWVM4KPK.js";
|
|
@@ -6097,6 +6097,9 @@ function verifyPendingRestarts(now) {
|
|
|
6097
6097
|
pendingRestartVerifications.delete(codeName);
|
|
6098
6098
|
log(`[restart-verify] '${codeName}' respawned healthy after MCP change \u2014 tools bound (ENG-6174)`);
|
|
6099
6099
|
finishRestartTiming(codeName, "tools-bound", void 0, log, now);
|
|
6100
|
+
if (hostFlagStore().getBoolean("session-tool-probe")) {
|
|
6101
|
+
promptBindProbeAgents.add(codeName);
|
|
6102
|
+
}
|
|
6100
6103
|
break;
|
|
6101
6104
|
case "waiting":
|
|
6102
6105
|
break;
|
|
@@ -6275,15 +6278,21 @@ var SESSION_TOOL_REBIND_COOLDOWN_MS = 10 * 60 * 1e3;
|
|
|
6275
6278
|
function sessionToolRebindKey(codeName, serverKey) {
|
|
6276
6279
|
return `${codeName}\0${serverKey}`;
|
|
6277
6280
|
}
|
|
6278
|
-
|
|
6279
|
-
|
|
6281
|
+
var promptBindProbeAgents = /* @__PURE__ */ new Set();
|
|
6282
|
+
async function runAgentSessionToolBindProbes(agent, integrations, projectDir, opts) {
|
|
6283
|
+
if (integrations.length === 0) return true;
|
|
6280
6284
|
const intervalSec = Number(process.env.AGT_CONNECTIVITY_PROBE_INTERVAL_SECONDS) || 3600;
|
|
6285
|
+
const intervalMs = opts?.forceDue ? 0 : intervalSec * 1e3;
|
|
6281
6286
|
const sessionLoadedServerKeys = new Set(
|
|
6282
6287
|
readDirectChatSessionState(agent.agent_id)?.mcpServerKeys ?? []
|
|
6283
6288
|
);
|
|
6284
6289
|
const result = await gatherSessionToolBindProbe(agent, integrations, projectDir, {
|
|
6285
6290
|
sessionLoadedServerKeys,
|
|
6286
|
-
intervalMs
|
|
6291
|
+
intervalMs,
|
|
6292
|
+
// ENG-7429 (CodeRabbit on #3063): a prompt probe must cover the WHOLE set, not
|
|
6293
|
+
// the rolling batch cap (25), so the just-added integration can't be crowded out
|
|
6294
|
+
// on a busy agent. Rolling probes keep the default cap.
|
|
6295
|
+
...opts?.forceDue ? { maxPerRun: integrations.length } : {}
|
|
6287
6296
|
});
|
|
6288
6297
|
if (result && result.reports.length > 0) {
|
|
6289
6298
|
await api.post("/host/session-tool-bind", {
|
|
@@ -6291,7 +6300,7 @@ async function runAgentSessionToolBindProbes(agent, integrations, projectDir) {
|
|
|
6291
6300
|
results: result.reports
|
|
6292
6301
|
});
|
|
6293
6302
|
log(
|
|
6294
|
-
`Session-tool-bind probe for '${agent.code_name}': probed=${result.probed} reported=${result.reports.length} due=${result.due}`
|
|
6303
|
+
`Session-tool-bind probe${opts?.forceDue ? " (prompt, ENG-7429)" : ""} for '${agent.code_name}': probed=${result.probed} reported=${result.reports.length} due=${result.due}`
|
|
6295
6304
|
);
|
|
6296
6305
|
}
|
|
6297
6306
|
if (result && result.rebindCandidates.length > 0 && hostFlagStore().getBoolean("session-tool-rebind")) {
|
|
@@ -6324,6 +6333,7 @@ async function runAgentSessionToolBindProbes(agent, integrations, projectDir) {
|
|
|
6324
6333
|
);
|
|
6325
6334
|
}
|
|
6326
6335
|
}
|
|
6336
|
+
return result != null;
|
|
6327
6337
|
}
|
|
6328
6338
|
function stopPersistentSessionAndForgetMcpBaseline(codeName, breakerReason, gateReason = breakerReason) {
|
|
6329
6339
|
const gate = restartGateFor(codeName, gateReason);
|
|
@@ -6509,7 +6519,7 @@ var agentRestartTimezoneInputs = /* @__PURE__ */ new Map();
|
|
|
6509
6519
|
var lastVersionCheckAt = 0;
|
|
6510
6520
|
var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
|
|
6511
6521
|
var lastResponsivenessProbeAt = 0;
|
|
6512
|
-
var agtCliVersion = true ? "0.28.
|
|
6522
|
+
var agtCliVersion = true ? "0.28.249" : "dev";
|
|
6513
6523
|
function resolveBrewPath(execFileSync2) {
|
|
6514
6524
|
try {
|
|
6515
6525
|
const out = execFileSync2("which", ["brew"], { timeout: 5e3 }).toString().trim();
|
|
@@ -7359,7 +7369,7 @@ function flushRestartedAgentDiagnostics(hostId, codeNames) {
|
|
|
7359
7369
|
if (codeNames.length === 0) return;
|
|
7360
7370
|
void (async () => {
|
|
7361
7371
|
try {
|
|
7362
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
7372
|
+
const { collectDiagnostics } = await import("../persistent-session-CHYTU6HG.js");
|
|
7363
7373
|
await api.post("/host/heartbeat", {
|
|
7364
7374
|
host_id: hostId,
|
|
7365
7375
|
agent_diagnostics: collectDiagnostics(codeNames)
|
|
@@ -7457,7 +7467,7 @@ async function pollCycle() {
|
|
|
7457
7467
|
}
|
|
7458
7468
|
try {
|
|
7459
7469
|
const { detectHostSecurity } = await import("../host-security-6PDFG7F5.js");
|
|
7460
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
7470
|
+
const { collectDiagnostics } = await import("../persistent-session-CHYTU6HG.js");
|
|
7461
7471
|
const diagCodeNames = [...agentState.persistentSessionAgents];
|
|
7462
7472
|
const agentDiagnostics = diagCodeNames.length > 0 ? collectDiagnostics(diagCodeNames) : void 0;
|
|
7463
7473
|
let tailscaleHostname;
|
|
@@ -7605,7 +7615,7 @@ async function pollCycle() {
|
|
|
7605
7615
|
const {
|
|
7606
7616
|
collectResponsivenessProbes,
|
|
7607
7617
|
getResponsivenessIntervalMs
|
|
7608
|
-
} = await import("../responsiveness-probe-
|
|
7618
|
+
} = await import("../responsiveness-probe-D74I4CS6.js");
|
|
7609
7619
|
const probeIntervalMs = getResponsivenessIntervalMs();
|
|
7610
7620
|
if (now - lastResponsivenessProbeAt > probeIntervalMs) {
|
|
7611
7621
|
const probeCodeNames = [...agentState.persistentSessionAgents];
|
|
@@ -7637,7 +7647,7 @@ async function pollCycle() {
|
|
|
7637
7647
|
collectResponsivenessProbes,
|
|
7638
7648
|
livePendingInboundOldestAgeSeconds,
|
|
7639
7649
|
parkPendingInbound
|
|
7640
|
-
} = await import("../responsiveness-probe-
|
|
7650
|
+
} = await import("../responsiveness-probe-D74I4CS6.js");
|
|
7641
7651
|
const { getProjectDir: wedgeProjectDir } = await import("../claude-scheduler-FATCLHDM.js");
|
|
7642
7652
|
const wedgeNow = /* @__PURE__ */ new Date();
|
|
7643
7653
|
const liveAgents = agentState.persistentSessionAgents;
|
|
@@ -9079,12 +9089,15 @@ async function processAgent(agent, agentStates) {
|
|
|
9079
9089
|
}
|
|
9080
9090
|
}
|
|
9081
9091
|
if (hostFlagStore().getBoolean("session-tool-probe")) {
|
|
9092
|
+
const forceDue = promptBindProbeAgents.delete(agent.code_name);
|
|
9093
|
+
let probeRan = false;
|
|
9082
9094
|
try {
|
|
9083
9095
|
const probeProjectDir = join16(homedir9(), ".augmented", agent.code_name, "project");
|
|
9084
|
-
await runAgentSessionToolBindProbes(agent, integrations, probeProjectDir);
|
|
9096
|
+
probeRan = await runAgentSessionToolBindProbes(agent, integrations, probeProjectDir, { forceDue });
|
|
9085
9097
|
} catch (err) {
|
|
9086
9098
|
log(`Session-tool-bind probe failed for '${agent.code_name}': ${err.message}`);
|
|
9087
9099
|
}
|
|
9100
|
+
if (forceDue && !probeRan) promptBindProbeAgents.add(agent.code_name);
|
|
9088
9101
|
}
|
|
9089
9102
|
if (frameworkAdapter.removeMcpServer && frameworkAdapter.getMcpPath) {
|
|
9090
9103
|
const mcpPath = frameworkAdapter.getMcpPath(agent.code_name);
|
|
@@ -10452,7 +10465,7 @@ async function handleRestartDoorbell(agentId, requestedAt, restartReason) {
|
|
|
10452
10465
|
void api.post("/host/restart-ack", { host_id: hostId, agent_id: agentId, restart_requested_at: requestedAt }).catch((err) => log(`[restart-lane] ack failed for '${codeName}': ${err.message}`));
|
|
10453
10466
|
void (async () => {
|
|
10454
10467
|
try {
|
|
10455
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
10468
|
+
const { collectDiagnostics } = await import("../persistent-session-CHYTU6HG.js");
|
|
10456
10469
|
await api.post("/host/heartbeat", {
|
|
10457
10470
|
host_id: hostId,
|
|
10458
10471
|
agent_diagnostics: collectDiagnostics([codeName])
|
|
@@ -10502,7 +10515,7 @@ async function respawnAgentAfterMcpStop(codeName, reason) {
|
|
|
10502
10515
|
}
|
|
10503
10516
|
try {
|
|
10504
10517
|
const hostId = await getHostId();
|
|
10505
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
10518
|
+
const { collectDiagnostics } = await import("../persistent-session-CHYTU6HG.js");
|
|
10506
10519
|
await api.post("/host/heartbeat", {
|
|
10507
10520
|
host_id: hostId,
|
|
10508
10521
|
agent_diagnostics: collectDiagnostics([codeName])
|
|
@@ -10893,7 +10906,7 @@ async function processClaudePairSessions(agents) {
|
|
|
10893
10906
|
killPairSession,
|
|
10894
10907
|
pairTmuxSession,
|
|
10895
10908
|
finalizeClaudePairOnboarding
|
|
10896
|
-
} = await import("../claude-pair-runtime-
|
|
10909
|
+
} = await import("../claude-pair-runtime-S6LYZUEC.js");
|
|
10897
10910
|
for (const pairId of pendingResp.cancelled_pair_ids ?? []) {
|
|
10898
10911
|
log(`[claude-pair] sweeping orphan tmux session for pair ${pairId.slice(0, 8)}`);
|
|
10899
10912
|
const killed = await killPairSession(pairTmuxSession(pairId));
|