@integrity-labs/agt-cli 0.28.384 → 0.28.386

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.
@@ -25,7 +25,7 @@ import {
25
25
  resolveConnectivityProbe,
26
26
  worseConnectivityOutcome,
27
27
  wrapScheduledTaskPrompt
28
- } from "./chunk-MQHDPJZD.js";
28
+ } from "./chunk-LAO2CUZU.js";
29
29
  import {
30
30
  parsePsRows
31
31
  } from "./chunk-XWVM4KPK.js";
@@ -6184,7 +6184,7 @@ function requireHost() {
6184
6184
  }
6185
6185
 
6186
6186
  // src/lib/api-client.ts
6187
- var agtCliVersion = true ? "0.28.384" : "dev";
6187
+ var agtCliVersion = true ? "0.28.386" : "dev";
6188
6188
  var lastConfigHash = null;
6189
6189
  function setConfigHash(hash) {
6190
6190
  lastConfigHash = hash && hash.length > 0 ? hash : null;
@@ -7030,7 +7030,11 @@ function reapMissingMcpSessions(args) {
7030
7030
  quarantineDwellMs = 0,
7031
7031
  quarantineMode = "off",
7032
7032
  onQuarantine,
7033
- isolated = false
7033
+ isolated = false,
7034
+ // ENG-8013: default false → a "no live child" observation is only excluded
7035
+ // from the give-up/quarantine budget when the caller positively identifies
7036
+ // the current generation as externally-churned. Legacy callers/tests unchanged.
7037
+ currentGenerationExternallyStarted = false
7034
7038
  } = args;
7035
7039
  const now = args.now ?? Date.now;
7036
7040
  const runPs = args.runPs ?? (isolated ? () => execFileSync2("docker", ["exec", `agt-${codeName}`, "ps", "-eo", "pid,ppid,args"], {
@@ -7127,12 +7131,16 @@ function reapMissingMcpSessions(args) {
7127
7131
  stableLiveSince: null,
7128
7132
  gaveUp: false
7129
7133
  };
7130
- if (state.firstMissingAt === null) state.firstMissingAt = nowMs;
7134
+ if (state.firstMissingAt === null || currentGenerationExternallyStarted) {
7135
+ state.firstMissingAt = nowMs;
7136
+ }
7131
7137
  state.stableLiveSince = null;
7132
7138
  if (state.lastAttemptedSessionStartedAt !== sessionStartedAt) {
7133
- state.attempts += 1;
7134
7139
  state.lastAttemptedSessionStartedAt = sessionStartedAt;
7135
- newGenerationKeys.add(key);
7140
+ if (!currentGenerationExternallyStarted) {
7141
+ state.attempts += 1;
7142
+ newGenerationKeys.add(key);
7143
+ }
7136
7144
  }
7137
7145
  state.restartHistory = state.restartHistory.filter((t) => nowMs - t < BACKOFF_WINDOW_MS);
7138
7146
  const restartsInWindow = state.restartHistory.length;
@@ -8630,4 +8638,4 @@ export {
8630
8638
  managerInstallSystemUnitCommand,
8631
8639
  managerUninstallSystemUnitCommand
8632
8640
  };
8633
- //# sourceMappingURL=chunk-IXN2AFOX.js.map
8641
+ //# sourceMappingURL=chunk-O37EMHVE.js.map