@integrity-labs/agt-cli 0.28.1224 → 0.28.1226

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.
Files changed (30) hide show
  1. package/dist/bin/agt.js +6 -6
  2. package/dist/{chunk-LBEB7SZN.js → chunk-DKTSGG7Q.js} +71 -1
  3. package/dist/{chunk-LBEB7SZN.js.map → chunk-DKTSGG7Q.js.map} +1 -1
  4. package/dist/{chunk-3QWPLCMX.js → chunk-GBPHP6FI.js} +7 -3
  5. package/dist/chunk-GBPHP6FI.js.map +1 -0
  6. package/dist/{chunk-C6VRK3J2.js → chunk-M53VVKTM.js} +2 -2
  7. package/dist/{chunk-EZOHUWIF.js → chunk-SIVBDXES.js} +5 -5
  8. package/dist/{chunk-4HPJCR5S.js → chunk-XF6SM5RR.js} +7 -4
  9. package/dist/chunk-XF6SM5RR.js.map +1 -0
  10. package/dist/{claude-code-updater-F7A6PTT6.js → claude-code-updater-QFDDREKD.js} +3 -3
  11. package/dist/{claude-pair-runtime-4X7ST7J3.js → claude-pair-runtime-3YHQHU45.js} +3 -3
  12. package/dist/lib/manager-worker.js +168 -30
  13. package/dist/lib/manager-worker.js.map +1 -1
  14. package/dist/mcp/direct-chat-channel.js +3 -0
  15. package/dist/mcp/index.js +3 -0
  16. package/dist/mcp/slack-channel.js +3 -0
  17. package/dist/mcp/telegram-channel.js +3 -0
  18. package/dist/{persistent-session-OG2MVQUR.js → persistent-session-DBAPNU35.js} +4 -4
  19. package/dist/{responsiveness-probe-HOXQTWME.js → responsiveness-probe-6S34EWLC.js} +4 -4
  20. package/dist/{session-auth-dead-GQGLYVIG.js → session-auth-dead-TDTU2CHO.js} +3 -3
  21. package/package.json +1 -1
  22. package/dist/chunk-3QWPLCMX.js.map +0 -1
  23. package/dist/chunk-4HPJCR5S.js.map +0 -1
  24. /package/dist/{chunk-C6VRK3J2.js.map → chunk-M53VVKTM.js.map} +0 -0
  25. /package/dist/{chunk-EZOHUWIF.js.map → chunk-SIVBDXES.js.map} +0 -0
  26. /package/dist/{claude-code-updater-F7A6PTT6.js.map → claude-code-updater-QFDDREKD.js.map} +0 -0
  27. /package/dist/{claude-pair-runtime-4X7ST7J3.js.map → claude-pair-runtime-3YHQHU45.js.map} +0 -0
  28. /package/dist/{persistent-session-OG2MVQUR.js.map → persistent-session-DBAPNU35.js.map} +0 -0
  29. /package/dist/{responsiveness-probe-HOXQTWME.js.map → responsiveness-probe-6S34EWLC.js.map} +0 -0
  30. /package/dist/{session-auth-dead-GQGLYVIG.js.map → session-auth-dead-TDTU2CHO.js.map} +0 -0
@@ -13,9 +13,9 @@ import {
13
13
  probeClaudeInstalls,
14
14
  readsAsNativeInstall,
15
15
  shouldRunClaudeCodeUpdater
16
- } from "./chunk-C6VRK3J2.js";
16
+ } from "./chunk-M53VVKTM.js";
17
17
  import "./chunk-XWVM4KPK.js";
18
- import "./chunk-LBEB7SZN.js";
18
+ import "./chunk-DKTSGG7Q.js";
19
19
  import "./chunk-AIUIMEUS.js";
20
20
  import "./chunk-DGUM43GV.js";
21
21
  export {
@@ -34,4 +34,4 @@ export {
34
34
  readsAsNativeInstall,
35
35
  shouldRunClaudeCodeUpdater
36
36
  };
37
- //# sourceMappingURL=claude-code-updater-F7A6PTT6.js.map
37
+ //# sourceMappingURL=claude-code-updater-QFDDREKD.js.map
@@ -8,7 +8,7 @@ import {
8
8
  import {
9
9
  redactPaneFrame,
10
10
  sanitizeTerminalFrame
11
- } from "./chunk-LBEB7SZN.js";
11
+ } from "./chunk-DKTSGG7Q.js";
12
12
  import {
13
13
  CLAUDE_CONFIG_DIR_ENV,
14
14
  claudeConfigDirFor,
@@ -321,7 +321,7 @@ async function spawnPairSession(session) {
321
321
  return { ok: true };
322
322
  } catch {
323
323
  }
324
- const { resolveClaudeBinary } = await import("./persistent-session-OG2MVQUR.js");
324
+ const { resolveClaudeBinary } = await import("./persistent-session-DBAPNU35.js");
325
325
  const claudeBin = resolveClaudeBinary();
326
326
  const pairEnv = {
327
327
  ...process.env,
@@ -836,4 +836,4 @@ export {
836
836
  startClaudePair,
837
837
  submitClaudePairCode
838
838
  };
839
- //# sourceMappingURL=claude-pair-runtime-4X7ST7J3.js.map
839
+ //# sourceMappingURL=claude-pair-runtime-3YHQHU45.js.map
@@ -85,7 +85,7 @@ import {
85
85
  tripClass,
86
86
  writeEtcEnvironment,
87
87
  writeProfileDScript
88
- } from "../chunk-EZOHUWIF.js";
88
+ } from "../chunk-SIVBDXES.js";
89
89
  import {
90
90
  CLAUDE_CODE_SECURITY_FLOOR,
91
91
  SELF_UPDATE_TIMEOUTS,
@@ -99,7 +99,7 @@ import {
99
99
  runSafeCleanup,
100
100
  tightestDiskStat,
101
101
  withPackageCacheLock
102
- } from "../chunk-C6VRK3J2.js";
102
+ } from "../chunk-M53VVKTM.js";
103
103
  import {
104
104
  rewriteSupervisorApiKey,
105
105
  supervisorChannelsRefusing
@@ -192,7 +192,7 @@ import {
192
192
  webFetchBaselineValue,
193
193
  webFetchRestartNeeded,
194
194
  writeEgressAllowlist
195
- } from "../chunk-4HPJCR5S.js";
195
+ } from "../chunk-XF6SM5RR.js";
196
196
  import {
197
197
  isAgentIdle,
198
198
  isStaleForToday,
@@ -201,8 +201,9 @@ import {
201
201
  peekPreviousSession,
202
202
  sessionTranscriptDir,
203
203
  subagentActivityAgeSeconds,
204
+ subagentTranscriptDir,
204
205
  transcriptActivityAgeSeconds
205
- } from "../chunk-3QWPLCMX.js";
206
+ } from "../chunk-GBPHP6FI.js";
206
207
  import {
207
208
  classifyUnanswerablePane,
208
209
  focusedConfirmDialogBlock,
@@ -305,6 +306,7 @@ import {
305
306
  isUnsetTimezone,
306
307
  isVacuousDeliverReason,
307
308
  laneTagFragment,
309
+ newBackgroundTaskLedger,
308
310
  normaliseSlackPeerAgentMode,
309
311
  normaliseSlackPeerGroupIds,
310
312
  pairToolCallBrackets,
@@ -314,6 +316,7 @@ import {
314
316
  parseUsageBanner,
315
317
  parseUsageReport,
316
318
  pickNewerClassification,
319
+ recordBackgroundTaskLine,
317
320
  redactPaneFrame,
318
321
  remoteMcpServerKey,
319
322
  resolveAgentTimezone,
@@ -323,6 +326,7 @@ import {
323
326
  resolveDmTarget,
324
327
  resolveInheritedForDelivery,
325
328
  resolveSessionActivityState,
329
+ runningBackgroundTaskCount,
326
330
  scrubPreservingIdentifiers,
327
331
  senderPolicyIsEnforcedOn,
328
332
  serializeAccountEnforcementMarker,
@@ -330,7 +334,7 @@ import {
330
334
  stabiliseResetInstant,
331
335
  sumTranscriptUsageInWindow,
332
336
  summarizeTranscriptActivity
333
- } from "../chunk-LBEB7SZN.js";
337
+ } from "../chunk-DKTSGG7Q.js";
334
338
  import {
335
339
  CLAUDE_CONFIG_DIR_ENV,
336
340
  claudeConfigDirFor,
@@ -4926,7 +4930,7 @@ function failingTurnLoops(now = Date.now(), threshold = failingTurnThreshold(),
4926
4930
  }
4927
4931
 
4928
4932
  // src/lib/session-activity.ts
4929
- import { readFileSync as readFileSync12, readdirSync as readdirSync3, statSync as statSync3 } from "fs";
4933
+ import { closeSync as closeSync2, openSync as openSync2, readFileSync as readFileSync12, readSync as readSync2, readdirSync as readdirSync3, statSync as statSync3 } from "fs";
4930
4934
  import { join as join18 } from "path";
4931
4935
  var RULE = /^[─━]{10,}/;
4932
4936
  var CARET_LINE = /^\s*❯(\s|$)/;
@@ -5034,6 +5038,135 @@ function readTranscript(cacheKey, dir, sessionId, nowMs) {
5034
5038
  cache.set(cacheKey, next);
5035
5039
  return next;
5036
5040
  }
5041
+ var BACKGROUND_SCAN_BYTES_PER_POLL = 8 * 1024 * 1024;
5042
+ var backgroundScans = /* @__PURE__ */ new Map();
5043
+ var NO_BACKGROUND_SIGNAL = { newestSubagentMs: null, running: null };
5044
+ function scanNewLines(path, size, scan, budget, log2) {
5045
+ const offset = scan.offsets.get(path) ?? 0;
5046
+ const length = Math.min(size - offset, budget);
5047
+ if (length <= 0) return 0;
5048
+ const buffer = Buffer.alloc(length);
5049
+ const fd = openSync2(path, "r");
5050
+ let read;
5051
+ try {
5052
+ read = readSync2(fd, buffer, 0, length, offset);
5053
+ } finally {
5054
+ closeSync2(fd);
5055
+ }
5056
+ let window = buffer.subarray(0, read);
5057
+ let base = offset;
5058
+ if (scan.skippingLine.has(path)) {
5059
+ const lineEnd = window.indexOf(10);
5060
+ if (lineEnd < 0) {
5061
+ scan.offsets.set(path, offset + read);
5062
+ return read;
5063
+ }
5064
+ scan.skippingLine.delete(path);
5065
+ window = window.subarray(lineEnd + 1);
5066
+ base = offset + lineEnd + 1;
5067
+ scan.offsets.set(path, base);
5068
+ }
5069
+ const end = window.lastIndexOf(10);
5070
+ if (end < 0) {
5071
+ if (window.length >= BACKGROUND_SCAN_BYTES_PER_POLL) {
5072
+ log2?.(`[session-activity] skipping a transcript line over ${BACKGROUND_SCAN_BYTES_PER_POLL} bytes in ${path}`);
5073
+ scan.skippingLine.add(path);
5074
+ scan.offsets.set(path, base + window.length);
5075
+ } else if (read === budget && read < size - offset) {
5076
+ scan.cutOff = path;
5077
+ }
5078
+ return read;
5079
+ }
5080
+ for (const line of window.toString("utf8", 0, end).split("\n")) {
5081
+ recordBackgroundTaskLine(line, scan.ledger, scan.spawnedAtMs);
5082
+ }
5083
+ scan.offsets.set(path, base + end + 1);
5084
+ return read;
5085
+ }
5086
+ function subagentFiles(dir) {
5087
+ let names;
5088
+ try {
5089
+ names = readdirSync3(dir);
5090
+ } catch (err) {
5091
+ if (err.code === "ENOENT") return [];
5092
+ throw err;
5093
+ }
5094
+ return names.flatMap((name) => {
5095
+ if (!name.endsWith(".jsonl")) return [];
5096
+ const path = join18(dir, name);
5097
+ try {
5098
+ const st = statSync3(path);
5099
+ return st.isFile() ? [{ path, mtimeMs: st.mtimeMs, size: st.size }] : [];
5100
+ } catch {
5101
+ return [];
5102
+ }
5103
+ });
5104
+ }
5105
+ function knownProcessStartMs(session) {
5106
+ if (!session || session.startedAt === null) return null;
5107
+ return session.startedAt === session.estimatedStartedAt ? null : session.startedAt;
5108
+ }
5109
+ function drainScan(scan, dir, log2) {
5110
+ const main = join18(dir, `${scan.sessionId}.jsonl`);
5111
+ let budget = BACKGROUND_SCAN_BYTES_PER_POLL;
5112
+ try {
5113
+ budget -= scanNewLines(main, statSync3(main).size, scan, budget, log2);
5114
+ } catch {
5115
+ }
5116
+ for (const file of subagentFiles(subagentTranscriptDir(dir, scan.sessionId))) {
5117
+ budget -= scanNewLines(file.path, file.size, scan, budget, log2);
5118
+ }
5119
+ return budget > 0;
5120
+ }
5121
+ function readBackgroundActivity(codeName, dir, sessionId, spawnedAtMs, nowMs, log2) {
5122
+ if (!sessionId || !SESSION_ID.test(sessionId)) return NO_BACKGROUND_SIGNAL;
5123
+ const prev = backgroundScans.get(codeName);
5124
+ const sameRun = prev?.sessionId === sessionId && prev.spawnedAtMs === spawnedAtMs;
5125
+ if (prev && sameRun && nowMs - prev.checkedAt < MIN_TRANSCRIPT_CHECK_MS) return prev;
5126
+ try {
5127
+ const main = join18(dir, `${sessionId}.jsonl`);
5128
+ let size;
5129
+ try {
5130
+ size = statSync3(main).size;
5131
+ } catch {
5132
+ return NO_BACKGROUND_SIGNAL;
5133
+ }
5134
+ const subagents = subagentFiles(subagentTranscriptDir(dir, sessionId));
5135
+ const files = [{ path: main, size }, ...subagents];
5136
+ const reusable = prev && sameRun && files.every((f) => f.size >= (prev.offsets.get(f.path) ?? 0));
5137
+ const ledger = newBackgroundTaskLedger();
5138
+ if (prev && prev.sessionId !== sessionId && spawnedAtMs !== null && prev.spawnedAtMs === spawnedAtMs) {
5139
+ if (!drainScan(prev, dir, log2)) return NO_BACKGROUND_SIGNAL;
5140
+ }
5141
+ if (prev && spawnedAtMs !== null && prev.spawnedAtMs === spawnedAtMs) {
5142
+ for (const id of prev.ledger.started) if (!prev.ledger.ended.has(id)) ledger.started.add(id);
5143
+ }
5144
+ const scan = reusable ? prev : {
5145
+ checkedAt: nowMs,
5146
+ sessionId,
5147
+ spawnedAtMs,
5148
+ offsets: /* @__PURE__ */ new Map(),
5149
+ skippingLine: /* @__PURE__ */ new Set(),
5150
+ cutOff: null,
5151
+ ledger,
5152
+ newestSubagentMs: null,
5153
+ running: null
5154
+ };
5155
+ let budget = BACKGROUND_SCAN_BYTES_PER_POLL;
5156
+ const cutOff = scan.cutOff;
5157
+ scan.cutOff = null;
5158
+ const ordered = cutOff ? [...files].sort((a, b) => Number(b.path === cutOff) - Number(a.path === cutOff)) : files;
5159
+ for (const file of ordered) budget -= scanNewLines(file.path, file.size, scan, budget, log2);
5160
+ scan.checkedAt = nowMs;
5161
+ scan.newestSubagentMs = subagents.reduce((n, f) => n === null || f.mtimeMs > n ? f.mtimeMs : n, null);
5162
+ scan.running = budget > 0 ? runningBackgroundTaskCount(scan.ledger) : null;
5163
+ backgroundScans.set(codeName, scan);
5164
+ return scan;
5165
+ } catch (err) {
5166
+ log2?.(`[session-activity] background scan failed for '${codeName}': ${err.message}`);
5167
+ return NO_BACKGROUND_SIGNAL;
5168
+ }
5169
+ }
5037
5170
  function readRecordedSession(agentDir) {
5038
5171
  try {
5039
5172
  const parsed = JSON.parse(readFileSync12(join18(agentDir, "session-state.json"), "utf-8"));
@@ -5099,13 +5232,17 @@ function buildSessionActivityReport(args) {
5099
5232
  // must not age a transcript that has since moved into `turn_killed`.
5100
5233
  nowMs: transcript.checkedAt
5101
5234
  });
5235
+ const processStartMs = args.processStartedAtMs === void 0 ? args.spawnedAtMs ?? null : args.processStartedAtMs;
5236
+ const background = readBackgroundActivity(args.codeName, args.transcriptDir, liveId, processStartMs, nowMs, args.log);
5102
5237
  return {
5103
5238
  state: state10,
5104
5239
  promptKind: state10 === "blocked_on_prompt" || state10 === "idle_at_prompt" ? pane.promptKind : null,
5105
5240
  lastToolName: transcript.activity.lastToolName?.slice(0, TOOL_NAME_MAX) ?? null,
5106
5241
  lastToolAt: iso(transcript.activity.lastToolAtMs),
5107
5242
  lastCompletedTurnAt: iso(transcript.activity.lastCompletedTurnAtMs),
5108
- transcriptMtime: iso(transcript.mtimeMs)
5243
+ transcriptMtime: iso(transcript.mtimeMs),
5244
+ newestSubagentWrite: iso(background.newestSubagentMs),
5245
+ runningBackgroundTasks: background.running
5109
5246
  };
5110
5247
  } catch (err) {
5111
5248
  args.log?.(`[session-activity] failed for '${args.codeName}': ${err.message}`);
@@ -6236,7 +6373,7 @@ function readToolCallPathSalt(codeName, homeDir) {
6236
6373
  import { statSync as statSync6 } from "fs";
6237
6374
 
6238
6375
  // src/lib/tool-call-extractor.ts
6239
- import { closeSync as closeSync2, fstatSync, openSync as openSync2, readFileSync as readFileSync17, readSync as readSync2, readdirSync as readdirSync6 } from "fs";
6376
+ import { closeSync as closeSync3, fstatSync, openSync as openSync3, readFileSync as readFileSync17, readSync as readSync3, readdirSync as readdirSync6 } from "fs";
6240
6377
  import { basename as basename2, join as join23, relative } from "path";
6241
6378
  import { StringDecoder } from "string_decoder";
6242
6379
 
@@ -6486,7 +6623,7 @@ var WINDOW_BUDGET_BYTES = 4 * 1024 * 1024;
6486
6623
  function extractTranscriptWindow(file, opts, from) {
6487
6624
  let fd;
6488
6625
  try {
6489
- fd = openSync2(file.absPath, "r");
6626
+ fd = openSync3(file.absPath, "r");
6490
6627
  } catch {
6491
6628
  return {
6492
6629
  records: [],
@@ -6532,7 +6669,7 @@ function extractTranscriptWindow(file, opts, from) {
6532
6669
  hitBudget = true;
6533
6670
  break;
6534
6671
  }
6535
- const bytesRead = readSync2(fd, buf, 0, WINDOW_CHUNK_BYTES, position);
6672
+ const bytesRead = readSync3(fd, buf, 0, WINDOW_CHUNK_BYTES, position);
6536
6673
  if (bytesRead <= 0) break;
6537
6674
  position += bytesRead;
6538
6675
  carry += decoder.write(buf.subarray(0, bytesRead));
@@ -6555,7 +6692,7 @@ function extractTranscriptWindow(file, opts, from) {
6555
6692
  } catch {
6556
6693
  } finally {
6557
6694
  try {
6558
- closeSync2(fd);
6695
+ closeSync3(fd);
6559
6696
  } catch {
6560
6697
  }
6561
6698
  }
@@ -11254,7 +11391,7 @@ var BlockedPromptReportCadence = class {
11254
11391
  };
11255
11392
 
11256
11393
  // src/lib/occupancy-gate.ts
11257
- import { closeSync as closeSync3, openSync as openSync3, readdirSync as readdirSync11, readSync as readSync3, statSync as statSync13 } from "fs";
11394
+ import { closeSync as closeSync4, openSync as openSync4, readdirSync as readdirSync11, readSync as readSync4, statSync as statSync13 } from "fs";
11258
11395
  import { join as join40 } from "path";
11259
11396
  function rostersMeasuredZero(mode, attested, runtimeRunning) {
11260
11397
  return mode === "enforce" && attested && runtimeRunning;
@@ -11271,7 +11408,7 @@ function readAlignedTail(path, tailBytes, maxAlignBytes) {
11271
11408
  try {
11272
11409
  const size = statSync13(path).size;
11273
11410
  if (size <= 0) return { content: "", complete: true, truncated: false };
11274
- fd = openSync3(path, "r");
11411
+ fd = openSync4(path, "r");
11275
11412
  let readStart = Math.max(0, size - tailBytes);
11276
11413
  if (readStart > 0) {
11277
11414
  const scanFloor = Math.max(0, readStart - maxAlignBytes);
@@ -11282,7 +11419,7 @@ function readAlignedTail(path, tailBytes, maxAlignBytes) {
11282
11419
  const from = Math.max(scanFloor, pos - CHUNK);
11283
11420
  const len2 = pos - from;
11284
11421
  const b = Buffer.allocUnsafe(len2);
11285
- if (readSync3(fd, b, 0, len2, from) !== len2) return null;
11422
+ if (readSync4(fd, b, 0, len2, from) !== len2) return null;
11286
11423
  const idx = b.lastIndexOf(10);
11287
11424
  if (idx !== -1) {
11288
11425
  boundary = from + idx + 1;
@@ -11300,14 +11437,14 @@ function readAlignedTail(path, tailBytes, maxAlignBytes) {
11300
11437
  }
11301
11438
  const len = size - readStart;
11302
11439
  const buf = Buffer.allocUnsafe(len);
11303
- if (readSync3(fd, buf, 0, len, readStart) !== len) return null;
11440
+ if (readSync4(fd, buf, 0, len, readStart) !== len) return null;
11304
11441
  return { content: buf.toString("utf-8", 0, len), complete: true, truncated: readStart > 0 };
11305
11442
  } catch {
11306
11443
  return null;
11307
11444
  } finally {
11308
11445
  if (fd != null) {
11309
11446
  try {
11310
- closeSync3(fd);
11447
+ closeSync4(fd);
11311
11448
  } catch {
11312
11449
  }
11313
11450
  }
@@ -15695,7 +15832,7 @@ var pendingDayRolloverReset = /* @__PURE__ */ new Set();
15695
15832
  var dayRolloverInboundHold = /* @__PURE__ */ new Map();
15696
15833
  var INBOUND_HOLD_EPISODE_GAP_MS = 12e4;
15697
15834
  async function channelInboundActivityAgeSecondsFor(codeName) {
15698
- const { newestPendingInboundActivityMtimeMs } = await import("../responsiveness-probe-HOXQTWME.js");
15835
+ const { newestPendingInboundActivityMtimeMs } = await import("../responsiveness-probe-6S34EWLC.js");
15699
15836
  const newest = newestPendingInboundActivityMtimeMs(dirname11(paneLogPath(codeName)));
15700
15837
  if (newest === null) return null;
15701
15838
  return Math.max(0, Math.floor((Date.now() - newest) / 1e3));
@@ -16495,7 +16632,7 @@ var agentRestartTimezoneInputs = /* @__PURE__ */ new Map();
16495
16632
  var lastVersionCheckAt = 0;
16496
16633
  var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
16497
16634
  var lastResponsivenessProbeAt = 0;
16498
- var agtCliVersion = true ? "0.28.1224" : "dev";
16635
+ var agtCliVersion = true ? "0.28.1226" : "dev";
16499
16636
  function resolveBrewPath(execFileSync3) {
16500
16637
  try {
16501
16638
  const out = execFileSync3("which", ["brew"], { timeout: 5e3 }).toString().trim();
@@ -18260,6 +18397,7 @@ function sessionActivityFor(codeName, pane) {
18260
18397
  sessionId: session?.currentSessionId ?? null,
18261
18398
  // ENG-11817: `/clear` and rotations change the session under the same pane.
18262
18399
  spawnedAtMs: session?.startedAt ?? null,
18400
+ processStartedAtMs: knownProcessStartMs(session),
18263
18401
  recordedSession: readRecordedSession(dirname11(projectDir)),
18264
18402
  previousSessionId: peekPreviousSession(codeName)?.sessionId ?? null,
18265
18403
  tmuxAlive: pane.tmuxAlive,
@@ -18491,7 +18629,7 @@ function flushRestartedAgentDiagnostics(hostId, codeNames) {
18491
18629
  if (codeNames.length === 0) return;
18492
18630
  void (async () => {
18493
18631
  try {
18494
- const { collectDiagnostics } = await import("../persistent-session-OG2MVQUR.js");
18632
+ const { collectDiagnostics } = await import("../persistent-session-DBAPNU35.js");
18495
18633
  await api.post("/host/heartbeat", {
18496
18634
  host_id: hostId,
18497
18635
  agent_diagnostics: collectDiagnostics(codeNames, quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor, sessionActivityFor)
@@ -18634,7 +18772,7 @@ async function pollCycleInner() {
18634
18772
  }
18635
18773
  try {
18636
18774
  const { detectHostSecurity } = await import("../host-security-KQYYZZVW.js");
18637
- const { collectDiagnostics } = await import("../persistent-session-OG2MVQUR.js");
18775
+ const { collectDiagnostics } = await import("../persistent-session-DBAPNU35.js");
18638
18776
  const diagCodeNames = [...agentState.persistentSessionAgents];
18639
18777
  const agentDiagnostics = diagCodeNames.length > 0 ? collectDiagnostics(diagCodeNames, quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor, sessionActivityFor) : void 0;
18640
18778
  let tailscaleHostname;
@@ -18899,7 +19037,7 @@ async function pollCycleInner() {
18899
19037
  }
18900
19038
  try {
18901
19039
  const desiredClaudeCodeVersion = hbResp?.desired_claude_code_version?.trim();
18902
- const { maybeUpdateClaudeCode, shouldRunClaudeCodeUpdater } = await import("../claude-code-updater-F7A6PTT6.js");
19040
+ const { maybeUpdateClaudeCode, shouldRunClaudeCodeUpdater } = await import("../claude-code-updater-QFDDREKD.js");
18903
19041
  const securityFloor = currentSecurityFloor();
18904
19042
  claudeUpdaterInFlight = true;
18905
19043
  if (desiredClaudeCodeVersion && (claudePairLoop.busy || claudePairingInProgress())) {
@@ -18934,7 +19072,7 @@ async function pollCycleInner() {
18934
19072
  collectPanelessActivityProbes,
18935
19073
  getResponsivenessIntervalMs,
18936
19074
  occupancyQualificationClassifications
18937
- } = await import("../responsiveness-probe-HOXQTWME.js");
19075
+ } = await import("../responsiveness-probe-6S34EWLC.js");
18938
19076
  const probeIntervalMs = getResponsivenessIntervalMs();
18939
19077
  if (now - lastResponsivenessProbeAt > probeIntervalMs) {
18940
19078
  const probeCodeNames = [...agentState.persistentSessionAgents];
@@ -19051,7 +19189,7 @@ async function pollCycleInner() {
19051
19189
  collectResponsivenessProbes,
19052
19190
  livePendingInboundOldestAgeSeconds,
19053
19191
  parkPendingInbound
19054
- } = await import("../responsiveness-probe-HOXQTWME.js");
19192
+ } = await import("../responsiveness-probe-6S34EWLC.js");
19055
19193
  const { getProjectDir: wedgeProjectDir } = await import("../scheduler-engine-M6AFZWNU.js");
19056
19194
  const wedgeNow = /* @__PURE__ */ new Date();
19057
19195
  const liveAgents = agentState.persistentSessionAgents;
@@ -19337,7 +19475,7 @@ async function pollCycleInner() {
19337
19475
  }
19338
19476
  }
19339
19477
  );
19340
- const { parkPendingInbound } = await import("../responsiveness-probe-HOXQTWME.js");
19478
+ const { parkPendingInbound } = await import("../responsiveness-probe-6S34EWLC.js");
19341
19479
  const { parked, deadLettered } = parkPendingInbound(codeName, new Date(fatalNowMs));
19342
19480
  paneFatalStreak.delete(codeName);
19343
19481
  paneFatalRestarts.set(codeName, [...history, fatalNowMs]);
@@ -19368,7 +19506,7 @@ async function pollCycleInner() {
19368
19506
  TRANSCRIPT_MOUNT_ESCALATION_REFRESH_MS,
19369
19507
  bindSourceEscalations
19370
19508
  } = await import("../transcript-mount-health-OHE6IVJV.js");
19371
- const { transcriptBindSourcesFor, ensureTranscriptBindSources } = await import("../persistent-session-OG2MVQUR.js");
19509
+ const { transcriptBindSourcesFor, ensureTranscriptBindSources } = await import("../persistent-session-DBAPNU35.js");
19372
19510
  const mountConfig = resolveTranscriptMountConfig();
19373
19511
  const liveAgents = agentState.persistentSessionAgents;
19374
19512
  for (const tracked of [
@@ -19533,7 +19671,7 @@ async function pollCycleInner() {
19533
19671
  }
19534
19672
  try {
19535
19673
  const { scrapeMcpFailedBannerCount } = await import("../pane-mcp-banner-scraper-VR5QGP3J.js");
19536
- const { probeSessionAuth } = await import("../session-auth-dead-GQGLYVIG.js");
19674
+ const { probeSessionAuth } = await import("../session-auth-dead-TDTU2CHO.js");
19537
19675
  const observations = [];
19538
19676
  const pendingCacheCommits = [];
19539
19677
  const modelApiErrorReportingOn = hostFlagStore().getBoolean("model-api-error-reporting");
@@ -24279,7 +24417,7 @@ async function handleRestartDoorbell(agentId, requestedAt, restartReason) {
24279
24417
  try {
24280
24418
  const freshId = rotateSessionForWedge(codeName);
24281
24419
  consecutiveWedgeCycles.delete(codeName);
24282
- const { parkPendingInbound: parkForRestart } = await import("../responsiveness-probe-HOXQTWME.js");
24420
+ const { parkPendingInbound: parkForRestart } = await import("../responsiveness-probe-6S34EWLC.js");
24283
24421
  const { parked, deadLettered } = parkForRestart(codeName, /* @__PURE__ */ new Date());
24284
24422
  const parkNote = parked > 0 ? `, ${parked} inbound parked` : "";
24285
24423
  const deadNote = deadLettered > 0 ? `, ${deadLettered} undeliverable dead-lettered` : "";
@@ -24322,7 +24460,7 @@ async function handleRestartDoorbell(agentId, requestedAt, restartReason) {
24322
24460
  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}`));
24323
24461
  void (async () => {
24324
24462
  try {
24325
- const { collectDiagnostics } = await import("../persistent-session-OG2MVQUR.js");
24463
+ const { collectDiagnostics } = await import("../persistent-session-DBAPNU35.js");
24326
24464
  await api.post("/host/heartbeat", {
24327
24465
  host_id: hostId,
24328
24466
  agent_diagnostics: collectDiagnostics([codeName], quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor, sessionActivityFor)
@@ -24373,7 +24511,7 @@ async function respawnAgentAfterMcpStop(codeName, reason) {
24373
24511
  }
24374
24512
  try {
24375
24513
  const hostId = await getHostId();
24376
- const { collectDiagnostics } = await import("../persistent-session-OG2MVQUR.js");
24514
+ const { collectDiagnostics } = await import("../persistent-session-DBAPNU35.js");
24377
24515
  await api.post("/host/heartbeat", {
24378
24516
  host_id: hostId,
24379
24517
  agent_diagnostics: collectDiagnostics([codeName], quarantineEntriesFor, claudeMdSizeFor, spawnOutcomeForDiagnostics, pidPressureFor, forwardedToolsFor, runtimeVersionFor, sessionActivityFor)
@@ -25075,7 +25213,7 @@ async function processClaudePairSessions(agents) {
25075
25213
  snapshotPairConfig,
25076
25214
  // ENG-11659: result -> report body + the manager.log line that records it.
25077
25215
  planPairStartReport
25078
- } = await import("../claude-pair-runtime-4X7ST7J3.js");
25216
+ } = await import("../claude-pair-runtime-3YHQHU45.js");
25079
25217
  const { resetClaudeSignin, describeSigninResetForLog, describeSigninResetFailure } = await import("../claude-signin-reset-6IJMMVYG.js");
25080
25218
  for (const pairId of pendingResp.cancelled_pair_ids ?? []) {
25081
25219
  log(`[claude-pair] sweeping orphan tmux session for pair ${pairId.slice(0, 8)}`);