@integrity-labs/agt-cli 0.28.223 → 0.28.224
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-MJ2TQQOO.js → chunk-S43WVYAF.js} +9 -3
- package/dist/chunk-S43WVYAF.js.map +1 -0
- package/dist/{chunk-7GJGGLKZ.js → chunk-TPL4KIC5.js} +3 -3
- package/dist/{claude-pair-runtime-VBCNGNZW.js → claude-pair-runtime-JFP2N723.js} +2 -2
- package/dist/lib/manager-worker.js +23 -15
- package/dist/lib/manager-worker.js.map +1 -1
- package/dist/{persistent-session-JGBNCAKI.js → persistent-session-I4CQEDME.js} +2 -2
- package/dist/{responsiveness-probe-3AYQX6CL.js → responsiveness-probe-MIUMXKV4.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-MJ2TQQOO.js.map +0 -1
- /package/dist/{chunk-7GJGGLKZ.js.map → chunk-TPL4KIC5.js.map} +0 -0
- /package/dist/{claude-pair-runtime-VBCNGNZW.js.map → claude-pair-runtime-JFP2N723.js.map} +0 -0
- /package/dist/{persistent-session-JGBNCAKI.js.map → persistent-session-I4CQEDME.js.map} +0 -0
- /package/dist/{responsiveness-probe-3AYQX6CL.js.map → responsiveness-probe-MIUMXKV4.js.map} +0 -0
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
resolveConnectivityProbe,
|
|
19
19
|
worseConnectivityOutcome,
|
|
20
20
|
wrapScheduledTaskPrompt
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-S43WVYAF.js";
|
|
22
22
|
import {
|
|
23
23
|
parsePsRows
|
|
24
24
|
} from "./chunk-XWVM4KPK.js";
|
|
@@ -5667,7 +5667,7 @@ function requireHost() {
|
|
|
5667
5667
|
}
|
|
5668
5668
|
|
|
5669
5669
|
// src/lib/api-client.ts
|
|
5670
|
-
var agtCliVersion = true ? "0.28.
|
|
5670
|
+
var agtCliVersion = true ? "0.28.224" : "dev";
|
|
5671
5671
|
var lastConfigHash = null;
|
|
5672
5672
|
function setConfigHash(hash) {
|
|
5673
5673
|
lastConfigHash = hash && hash.length > 0 ? hash : null;
|
|
@@ -7720,4 +7720,4 @@ export {
|
|
|
7720
7720
|
managerInstallSystemUnitCommand,
|
|
7721
7721
|
managerUninstallSystemUnitCommand
|
|
7722
7722
|
};
|
|
7723
|
-
//# sourceMappingURL=chunk-
|
|
7723
|
+
//# sourceMappingURL=chunk-TPL4KIC5.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-I4CQEDME.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-JFP2N723.js.map
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
requireHost,
|
|
38
38
|
safeWriteJsonAtomic,
|
|
39
39
|
setConfigHash
|
|
40
|
-
} from "../chunk-
|
|
40
|
+
} from "../chunk-TPL4KIC5.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-S43WVYAF.js";
|
|
126
126
|
import {
|
|
127
127
|
reapOrphanChannelMcps
|
|
128
128
|
} from "../chunk-XWVM4KPK.js";
|
|
@@ -5135,8 +5135,9 @@ function startRealtimeAssignments(config2) {
|
|
|
5135
5135
|
const prev = restartRequestFingerprint.get(agentId);
|
|
5136
5136
|
restartRequestFingerprint.set(agentId, requestedAt);
|
|
5137
5137
|
if (requestedAt && requestedAt !== prev && onRestartRequested) {
|
|
5138
|
-
|
|
5139
|
-
|
|
5138
|
+
const restartReason = row.restart_reason ?? null;
|
|
5139
|
+
log2(`[realtime] Restart requested for ${agentId} at ${requestedAt}${restartReason ? ` (reason=${restartReason})` : ""}`);
|
|
5140
|
+
onRestartRequested({ agent_id: agentId, restart_requested_at: requestedAt, restart_reason: restartReason });
|
|
5140
5141
|
}
|
|
5141
5142
|
}).on("postgres_changes", {
|
|
5142
5143
|
event: "DELETE",
|
|
@@ -6242,7 +6243,7 @@ var agentRestartTimezoneInputs = /* @__PURE__ */ new Map();
|
|
|
6242
6243
|
var lastVersionCheckAt = 0;
|
|
6243
6244
|
var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
|
|
6244
6245
|
var lastResponsivenessProbeAt = 0;
|
|
6245
|
-
var agtCliVersion = true ? "0.28.
|
|
6246
|
+
var agtCliVersion = true ? "0.28.224" : "dev";
|
|
6246
6247
|
function resolveBrewPath(execFileSync2) {
|
|
6247
6248
|
try {
|
|
6248
6249
|
const out = execFileSync2("which", ["brew"], { timeout: 5e3 }).toString().trim();
|
|
@@ -7151,7 +7152,7 @@ async function pollCycle() {
|
|
|
7151
7152
|
}
|
|
7152
7153
|
try {
|
|
7153
7154
|
const { detectHostSecurity } = await import("../host-security-6PDFG7F5.js");
|
|
7154
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
7155
|
+
const { collectDiagnostics } = await import("../persistent-session-I4CQEDME.js");
|
|
7155
7156
|
const diagCodeNames = [...agentState.persistentSessionAgents];
|
|
7156
7157
|
const agentDiagnostics = diagCodeNames.length > 0 ? collectDiagnostics(diagCodeNames) : void 0;
|
|
7157
7158
|
let tailscaleHostname;
|
|
@@ -7299,7 +7300,7 @@ async function pollCycle() {
|
|
|
7299
7300
|
const {
|
|
7300
7301
|
collectResponsivenessProbes,
|
|
7301
7302
|
getResponsivenessIntervalMs
|
|
7302
|
-
} = await import("../responsiveness-probe-
|
|
7303
|
+
} = await import("../responsiveness-probe-MIUMXKV4.js");
|
|
7303
7304
|
const probeIntervalMs = getResponsivenessIntervalMs();
|
|
7304
7305
|
if (now - lastResponsivenessProbeAt > probeIntervalMs) {
|
|
7305
7306
|
const probeCodeNames = [...agentState.persistentSessionAgents];
|
|
@@ -7331,7 +7332,7 @@ async function pollCycle() {
|
|
|
7331
7332
|
collectResponsivenessProbes,
|
|
7332
7333
|
livePendingInboundOldestAgeSeconds,
|
|
7333
7334
|
parkPendingInbound
|
|
7334
|
-
} = await import("../responsiveness-probe-
|
|
7335
|
+
} = await import("../responsiveness-probe-MIUMXKV4.js");
|
|
7335
7336
|
const { getProjectDir: wedgeProjectDir } = await import("../claude-scheduler-FATCLHDM.js");
|
|
7336
7337
|
const wedgeNow = /* @__PURE__ */ new Date();
|
|
7337
7338
|
const liveAgents = agentState.persistentSessionAgents;
|
|
@@ -7586,7 +7587,7 @@ async function pollCycle() {
|
|
|
7586
7587
|
if (restartedCodeNames.length > 0) {
|
|
7587
7588
|
void (async () => {
|
|
7588
7589
|
try {
|
|
7589
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
7590
|
+
const { collectDiagnostics } = await import("../persistent-session-I4CQEDME.js");
|
|
7590
7591
|
const freshDiagnostics = collectDiagnostics(restartedCodeNames);
|
|
7591
7592
|
await api.post("/host/heartbeat", {
|
|
7592
7593
|
host_id: hostId,
|
|
@@ -10021,14 +10022,21 @@ function ensureRealtimeDriftStarted(agentStates) {
|
|
|
10021
10022
|
});
|
|
10022
10023
|
}
|
|
10023
10024
|
var restartInFlight = /* @__PURE__ */ new Set();
|
|
10024
|
-
|
|
10025
|
-
|
|
10026
|
-
|
|
10025
|
+
function restartReasonNeedsRender(reason) {
|
|
10026
|
+
return reason != null && reason !== "manual";
|
|
10027
|
+
}
|
|
10028
|
+
async function handleRestartDoorbell(agentId, requestedAt, restartReason) {
|
|
10027
10029
|
const prev = state6.agents.find((a) => a.agentId === agentId);
|
|
10028
10030
|
const codeName = prev?.codeName;
|
|
10029
10031
|
if (!codeName) return;
|
|
10030
10032
|
const lastProcessed = prev?.lastRestartProcessedAt ?? null;
|
|
10031
10033
|
if (lastProcessed != null && Date.parse(lastProcessed) >= Date.parse(requestedAt)) return;
|
|
10034
|
+
if (restartReasonNeedsRender(restartReason)) {
|
|
10035
|
+
triggerEarlyPoll(`config-change reload for '${codeName}' (reason=${restartReason})`);
|
|
10036
|
+
return;
|
|
10037
|
+
}
|
|
10038
|
+
if (!hostFlagStore().getBoolean("restart-doorbell")) return;
|
|
10039
|
+
if (restartInFlight.has(agentId)) return;
|
|
10032
10040
|
restartInFlight.add(agentId);
|
|
10033
10041
|
try {
|
|
10034
10042
|
log(`[restart-lane] Fast restart for '${codeName}' at ${requestedAt}`);
|
|
@@ -10060,7 +10068,7 @@ async function handleRestartDoorbell(agentId, requestedAt) {
|
|
|
10060
10068
|
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}`));
|
|
10061
10069
|
void (async () => {
|
|
10062
10070
|
try {
|
|
10063
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
10071
|
+
const { collectDiagnostics } = await import("../persistent-session-I4CQEDME.js");
|
|
10064
10072
|
await api.post("/host/heartbeat", {
|
|
10065
10073
|
host_id: hostId,
|
|
10066
10074
|
agent_diagnostics: collectDiagnostics([codeName])
|
|
@@ -10095,7 +10103,7 @@ function ensureRealtimeAssignStarted(agentStates) {
|
|
|
10095
10103
|
// flag-gated and backstopped by the slow poll, so wiring it unconditionally
|
|
10096
10104
|
// is safe (a no-op when the flag is off).
|
|
10097
10105
|
onRestartRequested: (payload) => {
|
|
10098
|
-
void handleRestartDoorbell(payload.agent_id, payload.restart_requested_at).catch(
|
|
10106
|
+
void handleRestartDoorbell(payload.agent_id, payload.restart_requested_at, payload.restart_reason).catch(
|
|
10099
10107
|
(err) => (
|
|
10100
10108
|
// Never let a fast-lane failure become an unhandled rejection - the slow
|
|
10101
10109
|
// poll backstop re-services the (still-set) restart_requested_at.
|
|
@@ -10454,7 +10462,7 @@ async function processClaudePairSessions(agents) {
|
|
|
10454
10462
|
killPairSession,
|
|
10455
10463
|
pairTmuxSession,
|
|
10456
10464
|
finalizeClaudePairOnboarding
|
|
10457
|
-
} = await import("../claude-pair-runtime-
|
|
10465
|
+
} = await import("../claude-pair-runtime-JFP2N723.js");
|
|
10458
10466
|
for (const pairId of pendingResp.cancelled_pair_ids ?? []) {
|
|
10459
10467
|
log(`[claude-pair] sweeping orphan tmux session for pair ${pairId.slice(0, 8)}`);
|
|
10460
10468
|
const killed = await killPairSession(pairTmuxSession(pairId));
|