@integrity-labs/agt-cli 0.28.1098 → 0.28.1100
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 +5 -5
- package/dist/{chunk-3SNPFRW3.js → chunk-BCIY67GX.js} +4 -4
- package/dist/{chunk-AVM2BBSX.js → chunk-NULQEO5H.js} +1 -1
- package/dist/chunk-NULQEO5H.js.map +1 -0
- package/dist/{chunk-WQQGPPQW.js → chunk-U2CHXYDJ.js} +2 -2
- package/dist/{claude-pair-runtime-MZXXBNGF.js → claude-pair-runtime-OTQOPMBH.js} +2 -2
- package/dist/lib/manager-worker.js +33 -20
- package/dist/lib/manager-worker.js.map +1 -1
- package/dist/{persistent-session-WHEFQHXF.js → persistent-session-RVYRYF6U.js} +3 -3
- package/dist/{responsiveness-probe-WHV2OHXM.js → responsiveness-probe-OPCRQN27.js} +3 -3
- package/dist/{session-auth-dead-H3YYJLPC.js → session-auth-dead-XOCRHVHW.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-AVM2BBSX.js.map +0 -1
- /package/dist/{chunk-3SNPFRW3.js.map → chunk-BCIY67GX.js.map} +0 -0
- /package/dist/{chunk-WQQGPPQW.js.map → chunk-U2CHXYDJ.js.map} +0 -0
- /package/dist/{claude-pair-runtime-MZXXBNGF.js.map → claude-pair-runtime-OTQOPMBH.js.map} +0 -0
- /package/dist/{persistent-session-WHEFQHXF.js.map → persistent-session-RVYRYF6U.js.map} +0 -0
- /package/dist/{responsiveness-probe-WHV2OHXM.js.map → responsiveness-probe-OPCRQN27.js.map} +0 -0
- /package/dist/{session-auth-dead-H3YYJLPC.js.map → session-auth-dead-XOCRHVHW.js.map} +0 -0
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
rotateDailySession,
|
|
25
25
|
sessionFileExists,
|
|
26
26
|
todayLocalIso
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-NULQEO5H.js";
|
|
28
28
|
import {
|
|
29
29
|
classifyUnanswerablePane,
|
|
30
30
|
findUsageLimitResetHint,
|
|
@@ -6113,4 +6113,4 @@ export {
|
|
|
6113
6113
|
stopAllSessionsAndWait,
|
|
6114
6114
|
getProjectDir
|
|
6115
6115
|
};
|
|
6116
|
-
//# sourceMappingURL=chunk-
|
|
6116
|
+
//# sourceMappingURL=chunk-U2CHXYDJ.js.map
|
|
@@ -266,7 +266,7 @@ async function spawnPairSession(session) {
|
|
|
266
266
|
return { ok: true };
|
|
267
267
|
} catch {
|
|
268
268
|
}
|
|
269
|
-
const { resolveClaudeBinary } = await import("./persistent-session-
|
|
269
|
+
const { resolveClaudeBinary } = await import("./persistent-session-RVYRYF6U.js");
|
|
270
270
|
const claudeBin = resolveClaudeBinary();
|
|
271
271
|
const pairEnv = {
|
|
272
272
|
...process.env,
|
|
@@ -734,4 +734,4 @@ export {
|
|
|
734
734
|
startClaudePair,
|
|
735
735
|
submitClaudePairCode
|
|
736
736
|
};
|
|
737
|
-
//# sourceMappingURL=claude-pair-runtime-
|
|
737
|
+
//# sourceMappingURL=claude-pair-runtime-OTQOPMBH.js.map
|
|
@@ -67,7 +67,7 @@ import {
|
|
|
67
67
|
safeWriteJsonAtomic,
|
|
68
68
|
setConfigHash,
|
|
69
69
|
tripClass
|
|
70
|
-
} from "../chunk-
|
|
70
|
+
} from "../chunk-BCIY67GX.js";
|
|
71
71
|
import {
|
|
72
72
|
getProjectDir as getProjectDir2,
|
|
73
73
|
getReadyTasks,
|
|
@@ -154,7 +154,7 @@ import {
|
|
|
154
154
|
webFetchBaselineValue,
|
|
155
155
|
webFetchRestartNeeded,
|
|
156
156
|
writeEgressAllowlist
|
|
157
|
-
} from "../chunk-
|
|
157
|
+
} from "../chunk-U2CHXYDJ.js";
|
|
158
158
|
import {
|
|
159
159
|
ACCOUNT_ENFORCEMENT_MARKER_FILENAME,
|
|
160
160
|
AnchorSessionClient,
|
|
@@ -264,7 +264,7 @@ import {
|
|
|
264
264
|
subagentActivityAgeSeconds,
|
|
265
265
|
sumTranscriptUsageInWindow,
|
|
266
266
|
transcriptActivityAgeSeconds
|
|
267
|
-
} from "../chunk-
|
|
267
|
+
} from "../chunk-NULQEO5H.js";
|
|
268
268
|
import {
|
|
269
269
|
classifyUnanswerablePane,
|
|
270
270
|
paneRemedy
|
|
@@ -14142,7 +14142,7 @@ var pendingDayRolloverReset = /* @__PURE__ */ new Set();
|
|
|
14142
14142
|
var dayRolloverInboundHold = /* @__PURE__ */ new Map();
|
|
14143
14143
|
var INBOUND_HOLD_EPISODE_GAP_MS = 12e4;
|
|
14144
14144
|
async function channelInboundActivityAgeSecondsFor(codeName) {
|
|
14145
|
-
const { newestPendingInboundActivityMtimeMs } = await import("../responsiveness-probe-
|
|
14145
|
+
const { newestPendingInboundActivityMtimeMs } = await import("../responsiveness-probe-OPCRQN27.js");
|
|
14146
14146
|
const newest = newestPendingInboundActivityMtimeMs(dirname11(paneLogPath(codeName)));
|
|
14147
14147
|
if (newest === null) return null;
|
|
14148
14148
|
return Math.max(0, Math.floor((Date.now() - newest) / 1e3));
|
|
@@ -14900,7 +14900,7 @@ var agentRestartTimezoneInputs = /* @__PURE__ */ new Map();
|
|
|
14900
14900
|
var lastVersionCheckAt = 0;
|
|
14901
14901
|
var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
|
|
14902
14902
|
var lastResponsivenessProbeAt = 0;
|
|
14903
|
-
var agtCliVersion = true ? "0.28.
|
|
14903
|
+
var agtCliVersion = true ? "0.28.1100" : "dev";
|
|
14904
14904
|
function resolveBrewPath(execFileSync3) {
|
|
14905
14905
|
try {
|
|
14906
14906
|
const out = execFileSync3("which", ["brew"], { timeout: 5e3 }).toString().trim();
|
|
@@ -16517,7 +16517,7 @@ function flushRestartedAgentDiagnostics(hostId, codeNames) {
|
|
|
16517
16517
|
if (codeNames.length === 0) return;
|
|
16518
16518
|
void (async () => {
|
|
16519
16519
|
try {
|
|
16520
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
16520
|
+
const { collectDiagnostics } = await import("../persistent-session-RVYRYF6U.js");
|
|
16521
16521
|
await api.post("/host/heartbeat", {
|
|
16522
16522
|
host_id: hostId,
|
|
16523
16523
|
agent_diagnostics: collectDiagnostics(codeNames, quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor)
|
|
@@ -16659,7 +16659,7 @@ async function pollCycleInner() {
|
|
|
16659
16659
|
}
|
|
16660
16660
|
try {
|
|
16661
16661
|
const { detectHostSecurity } = await import("../host-security-KQYYZZVW.js");
|
|
16662
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
16662
|
+
const { collectDiagnostics } = await import("../persistent-session-RVYRYF6U.js");
|
|
16663
16663
|
const diagCodeNames = [...agentState.persistentSessionAgents];
|
|
16664
16664
|
const agentDiagnostics = diagCodeNames.length > 0 ? collectDiagnostics(diagCodeNames, quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor) : void 0;
|
|
16665
16665
|
let tailscaleHostname;
|
|
@@ -16867,7 +16867,7 @@ async function pollCycleInner() {
|
|
|
16867
16867
|
collectPanelessActivityProbes,
|
|
16868
16868
|
getResponsivenessIntervalMs,
|
|
16869
16869
|
occupancyQualificationClassifications
|
|
16870
|
-
} = await import("../responsiveness-probe-
|
|
16870
|
+
} = await import("../responsiveness-probe-OPCRQN27.js");
|
|
16871
16871
|
const probeIntervalMs = getResponsivenessIntervalMs();
|
|
16872
16872
|
if (now - lastResponsivenessProbeAt > probeIntervalMs) {
|
|
16873
16873
|
const probeCodeNames = [...agentState.persistentSessionAgents];
|
|
@@ -16984,7 +16984,7 @@ async function pollCycleInner() {
|
|
|
16984
16984
|
collectResponsivenessProbes,
|
|
16985
16985
|
livePendingInboundOldestAgeSeconds,
|
|
16986
16986
|
parkPendingInbound
|
|
16987
|
-
} = await import("../responsiveness-probe-
|
|
16987
|
+
} = await import("../responsiveness-probe-OPCRQN27.js");
|
|
16988
16988
|
const { getProjectDir: wedgeProjectDir } = await import("../scheduler-engine-M6AFZWNU.js");
|
|
16989
16989
|
const wedgeNow = /* @__PURE__ */ new Date();
|
|
16990
16990
|
const liveAgents = agentState.persistentSessionAgents;
|
|
@@ -17270,7 +17270,7 @@ async function pollCycleInner() {
|
|
|
17270
17270
|
}
|
|
17271
17271
|
}
|
|
17272
17272
|
);
|
|
17273
|
-
const { parkPendingInbound } = await import("../responsiveness-probe-
|
|
17273
|
+
const { parkPendingInbound } = await import("../responsiveness-probe-OPCRQN27.js");
|
|
17274
17274
|
const { parked, deadLettered } = parkPendingInbound(codeName, new Date(fatalNowMs));
|
|
17275
17275
|
paneFatalStreak.delete(codeName);
|
|
17276
17276
|
paneFatalRestarts.set(codeName, [...history, fatalNowMs]);
|
|
@@ -17301,7 +17301,7 @@ async function pollCycleInner() {
|
|
|
17301
17301
|
TRANSCRIPT_MOUNT_ESCALATION_REFRESH_MS,
|
|
17302
17302
|
bindSourceEscalations
|
|
17303
17303
|
} = await import("../transcript-mount-health-OHE6IVJV.js");
|
|
17304
|
-
const { transcriptBindSourcesFor, ensureTranscriptBindSources } = await import("../persistent-session-
|
|
17304
|
+
const { transcriptBindSourcesFor, ensureTranscriptBindSources } = await import("../persistent-session-RVYRYF6U.js");
|
|
17305
17305
|
const mountConfig = resolveTranscriptMountConfig();
|
|
17306
17306
|
const liveAgents = agentState.persistentSessionAgents;
|
|
17307
17307
|
for (const tracked of [
|
|
@@ -17466,7 +17466,7 @@ async function pollCycleInner() {
|
|
|
17466
17466
|
}
|
|
17467
17467
|
try {
|
|
17468
17468
|
const { scrapeMcpFailedBannerCount } = await import("../pane-mcp-banner-scraper-VR5QGP3J.js");
|
|
17469
|
-
const { probeSessionAuth } = await import("../session-auth-dead-
|
|
17469
|
+
const { probeSessionAuth } = await import("../session-auth-dead-XOCRHVHW.js");
|
|
17470
17470
|
const observations = [];
|
|
17471
17471
|
const pendingCacheCommits = [];
|
|
17472
17472
|
const modelApiErrorReportingOn = hostFlagStore().getBoolean("model-api-error-reporting");
|
|
@@ -21829,7 +21829,17 @@ function realtimeRebindBackoffMs(attempts) {
|
|
|
21829
21829
|
const step = attempts - REALTIME_REBIND_FREE_ATTEMPTS;
|
|
21830
21830
|
return Math.min(1e4 * 2 ** (step - 1), REALTIME_REBIND_MAX_BACKOFF_MS);
|
|
21831
21831
|
}
|
|
21832
|
-
function
|
|
21832
|
+
function jitteredRealtimeRebindBackoffMs(attempts, rand = hostRebindJitter) {
|
|
21833
|
+
const ceiling = realtimeRebindBackoffMs(attempts);
|
|
21834
|
+
if (ceiling === 0) return 0;
|
|
21835
|
+
const r = Math.min(Math.max(rand(), 0), 1);
|
|
21836
|
+
return Math.round(ceiling + ceiling / 2 * r);
|
|
21837
|
+
}
|
|
21838
|
+
var HOST_REBIND_JITTER = Math.random();
|
|
21839
|
+
function hostRebindJitter() {
|
|
21840
|
+
return HOST_REBIND_JITTER;
|
|
21841
|
+
}
|
|
21842
|
+
function recordRealtimeRebindFailure(failures, agentId, status, now, rand = hostRebindJitter) {
|
|
21833
21843
|
const prior = failures.get(agentId);
|
|
21834
21844
|
const attempts = (prior?.attempts ?? 0) + 1;
|
|
21835
21845
|
const next = {
|
|
@@ -21837,7 +21847,7 @@ function recordRealtimeRebindFailure(failures, agentId, status, now) {
|
|
|
21837
21847
|
since: prior?.since ?? now,
|
|
21838
21848
|
lastStatus: status,
|
|
21839
21849
|
loggedAtAttempt: prior?.loggedAtAttempt ?? 0,
|
|
21840
|
-
nextAttemptAt: now +
|
|
21850
|
+
nextAttemptAt: now + jitteredRealtimeRebindBackoffMs(attempts, rand)
|
|
21841
21851
|
};
|
|
21842
21852
|
failures.set(agentId, next);
|
|
21843
21853
|
return next;
|
|
@@ -22038,7 +22048,7 @@ async function handleRestartDoorbell(agentId, requestedAt, restartReason) {
|
|
|
22038
22048
|
try {
|
|
22039
22049
|
const freshId = rotateSessionForWedge(codeName);
|
|
22040
22050
|
consecutiveWedgeCycles.delete(codeName);
|
|
22041
|
-
const { parkPendingInbound: parkForRestart } = await import("../responsiveness-probe-
|
|
22051
|
+
const { parkPendingInbound: parkForRestart } = await import("../responsiveness-probe-OPCRQN27.js");
|
|
22042
22052
|
const { parked, deadLettered } = parkForRestart(codeName, /* @__PURE__ */ new Date());
|
|
22043
22053
|
const parkNote = parked > 0 ? `, ${parked} inbound parked` : "";
|
|
22044
22054
|
const deadNote = deadLettered > 0 ? `, ${deadLettered} undeliverable dead-lettered` : "";
|
|
@@ -22081,7 +22091,7 @@ async function handleRestartDoorbell(agentId, requestedAt, restartReason) {
|
|
|
22081
22091
|
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}`));
|
|
22082
22092
|
void (async () => {
|
|
22083
22093
|
try {
|
|
22084
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
22094
|
+
const { collectDiagnostics } = await import("../persistent-session-RVYRYF6U.js");
|
|
22085
22095
|
await api.post("/host/heartbeat", {
|
|
22086
22096
|
host_id: hostId,
|
|
22087
22097
|
agent_diagnostics: collectDiagnostics([codeName], quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor)
|
|
@@ -22132,7 +22142,7 @@ async function respawnAgentAfterMcpStop(codeName, reason) {
|
|
|
22132
22142
|
}
|
|
22133
22143
|
try {
|
|
22134
22144
|
const hostId = await getHostId();
|
|
22135
|
-
const { collectDiagnostics } = await import("../persistent-session-
|
|
22145
|
+
const { collectDiagnostics } = await import("../persistent-session-RVYRYF6U.js");
|
|
22136
22146
|
await api.post("/host/heartbeat", {
|
|
22137
22147
|
host_id: hostId,
|
|
22138
22148
|
agent_diagnostics: collectDiagnostics([codeName], quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor)
|
|
@@ -22356,13 +22366,14 @@ function ensureRealtimeIntegrationContextStarted(agentStates) {
|
|
|
22356
22366
|
);
|
|
22357
22367
|
},
|
|
22358
22368
|
onSubscriptionLost: (agentId, status) => {
|
|
22369
|
+
const lostAt = Date.now();
|
|
22359
22370
|
const state10 = recordRealtimeRebindFailure(
|
|
22360
22371
|
realtimeRebindFailures,
|
|
22361
22372
|
agentId,
|
|
22362
22373
|
status,
|
|
22363
|
-
|
|
22374
|
+
lostAt
|
|
22364
22375
|
);
|
|
22365
|
-
const waitMs =
|
|
22376
|
+
const waitMs = Math.max(0, state10.nextAttemptAt - lostAt);
|
|
22366
22377
|
if (state10.attempts === 1 || state10.attempts > state10.loggedAtAttempt) {
|
|
22367
22378
|
state10.loggedAtAttempt = state10.attempts;
|
|
22368
22379
|
const stuckForSeconds = Math.floor((Date.now() - state10.since) / 1e3);
|
|
@@ -22804,7 +22815,7 @@ async function processClaudePairSessions(agents) {
|
|
|
22804
22815
|
// cannot take it for itself — by the time it runs, the write it is looking
|
|
22805
22816
|
// for may already have happened.
|
|
22806
22817
|
snapshotPairConfig
|
|
22807
|
-
} = await import("../claude-pair-runtime-
|
|
22818
|
+
} = await import("../claude-pair-runtime-OTQOPMBH.js");
|
|
22808
22819
|
for (const pairId of pendingResp.cancelled_pair_ids ?? []) {
|
|
22809
22820
|
log(`[claude-pair] sweeping orphan tmux session for pair ${pairId.slice(0, 8)}`);
|
|
22810
22821
|
const killed = await killPairSession(pairTmuxSession(pairId));
|
|
@@ -24204,6 +24215,7 @@ export {
|
|
|
24204
24215
|
DAY_ROLLOVER_FORCE_GRACE_MIN,
|
|
24205
24216
|
DAY_ROLLOVER_INBOUND_DEFER_MAX_MIN,
|
|
24206
24217
|
DAY_ROLLOVER_INBOUND_GRACE_SEC,
|
|
24218
|
+
HOST_REBIND_JITTER,
|
|
24207
24219
|
REALTIME_REBIND_FREE_ATTEMPTS,
|
|
24208
24220
|
REALTIME_REBIND_IN_FLIGHT_GRACE_MS,
|
|
24209
24221
|
REALTIME_REBIND_MAX_BACKOFF_MS,
|
|
@@ -24235,6 +24247,7 @@ export {
|
|
|
24235
24247
|
inboundHoldMinutes,
|
|
24236
24248
|
isOlderSemverTuple,
|
|
24237
24249
|
isPrereleaseVersion,
|
|
24250
|
+
jitteredRealtimeRebindBackoffMs,
|
|
24238
24251
|
markAgentForFreshMemorySync,
|
|
24239
24252
|
maybeInjectKanbanCheck,
|
|
24240
24253
|
maybeProbeClaudeRuntimeAuth,
|