@integrity-labs/agt-cli 0.28.879 → 0.28.881

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 CHANGED
@@ -40,7 +40,7 @@ import {
40
40
  success,
41
41
  table,
42
42
  warn
43
- } from "../chunk-QXIOZLOL.js";
43
+ } from "../chunk-3GJ22IH2.js";
44
44
  import {
45
45
  getProjectDir,
46
46
  isSessionResumeDisabled,
@@ -5467,7 +5467,7 @@ import { execFileSync, execSync } from "child_process";
5467
5467
  import { existsSync as existsSync11, realpathSync as realpathSync2 } from "fs";
5468
5468
  import chalk18 from "chalk";
5469
5469
  import ora16 from "ora";
5470
- var cliVersion = true ? "0.28.879" : "dev";
5470
+ var cliVersion = true ? "0.28.881" : "dev";
5471
5471
  async function fetchLatestVersion() {
5472
5472
  const host2 = getHost();
5473
5473
  if (!host2) return null;
@@ -6658,7 +6658,7 @@ function handleError(err) {
6658
6658
  }
6659
6659
 
6660
6660
  // src/bin/agt.ts
6661
- var cliVersion2 = true ? "0.28.879" : "dev";
6661
+ var cliVersion2 = true ? "0.28.881" : "dev";
6662
6662
  var program = new Command();
6663
6663
  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");
6664
6664
  program.hook("preAction", async (thisCommand, actionCommand) => {
@@ -6771,7 +6771,7 @@ function exchangeFailureKind(err) {
6771
6771
  }
6772
6772
 
6773
6773
  // src/lib/api-client.ts
6774
- var agtCliVersion = true ? "0.28.879" : "dev";
6774
+ var agtCliVersion = true ? "0.28.881" : "dev";
6775
6775
  var lastConfigHash = null;
6776
6776
  function setConfigHash(hash) {
6777
6777
  lastConfigHash = hash && hash.length > 0 ? hash : null;
@@ -11381,4 +11381,4 @@ export {
11381
11381
  managerInstallSystemUnitCommand,
11382
11382
  managerUninstallSystemUnitCommand
11383
11383
  };
11384
- //# sourceMappingURL=chunk-QXIOZLOL.js.map
11384
+ //# sourceMappingURL=chunk-3GJ22IH2.js.map
@@ -63,7 +63,7 @@ import {
63
63
  safeWriteJsonAtomic,
64
64
  setConfigHash,
65
65
  tripClass
66
- } from "../chunk-QXIOZLOL.js";
66
+ } from "../chunk-3GJ22IH2.js";
67
67
  import {
68
68
  getProjectDir as getProjectDir2,
69
69
  getReadyTasks,
@@ -13684,7 +13684,7 @@ var agentRestartTimezoneInputs = /* @__PURE__ */ new Map();
13684
13684
  var lastVersionCheckAt = 0;
13685
13685
  var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
13686
13686
  var lastResponsivenessProbeAt = 0;
13687
- var agtCliVersion = true ? "0.28.879" : "dev";
13687
+ var agtCliVersion = true ? "0.28.881" : "dev";
13688
13688
  function resolveBrewPath(execFileSync2) {
13689
13689
  try {
13690
13690
  const out = execFileSync2("which", ["brew"], { timeout: 5e3 }).toString().trim();
@@ -45081,6 +45081,7 @@ function deadLetterSlackMarker(fullPath, filename) {
45081
45081
  return false;
45082
45082
  }
45083
45083
  }
45084
+ var SWEEP_MAX_REMOVALS_PER_PASS = 25;
45084
45085
  function sweepSlackStaleMarkers(thresholdMs) {
45085
45086
  if (!SLACK_PENDING_INBOUND_DIR) return;
45086
45087
  if (!existsSync10(SLACK_PENDING_INBOUND_DIR)) return;
@@ -45097,10 +45098,15 @@ function sweepSlackStaleMarkers(thresholdMs) {
45097
45098
  const now = Date.now();
45098
45099
  const replayEnabled = channelReplayEnabled();
45099
45100
  let cleared = 0;
45101
+ let capped = false;
45100
45102
  const lostMarkers = [];
45101
45103
  for (const filename of filenames) {
45102
45104
  if (!filename.endsWith(".json")) continue;
45103
45105
  if (filename.endsWith(".tmp")) continue;
45106
+ if (cleared >= SWEEP_MAX_REMOVALS_PER_PASS) {
45107
+ capped = true;
45108
+ break;
45109
+ }
45104
45110
  const fullPath = join20(SLACK_PENDING_INBOUND_DIR, filename);
45105
45111
  let marker;
45106
45112
  try {
@@ -45111,9 +45117,11 @@ function sweepSlackStaleMarkers(thresholdMs) {
45111
45117
  `
45112
45118
  );
45113
45119
  recordChannelDeflection(SLACK_AGENT_DIR, "slack", "marker_corrupt");
45114
- try {
45115
- unlinkSync7(fullPath);
45116
- } catch {
45120
+ if (!deadLetterSlackMarker(fullPath, filename)) {
45121
+ try {
45122
+ unlinkSync7(fullPath);
45123
+ } catch {
45124
+ }
45117
45125
  }
45118
45126
  cleared++;
45119
45127
  continue;
@@ -45160,7 +45168,7 @@ function sweepSlackStaleMarkers(thresholdMs) {
45160
45168
  const detail = lostMarkers.slice(0, 20).join(" ");
45161
45169
  const overflow = lostMarkers.length > 20 ? ` (+${lostMarkers.length - 20} more)` : "";
45162
45170
  process.stderr.write(
45163
- `slack-channel(${AGENT_CODE_NAME}): stale-marker sweep cleared=${cleared}${detail ? ` lost=[${detail}${overflow}]` : ""}
45171
+ `slack-channel(${AGENT_CODE_NAME}): stale-marker sweep cleared=${cleared}${capped ? ` CAPPED at ${SWEEP_MAX_REMOVALS_PER_PASS} \u2014 more remain, and this many going stale in one pass is not ordinary ageing (check for a clock step)` : ""}${detail ? ` lost=[${detail}${overflow}]` : ""}
45164
45172
  `
45165
45173
  );
45166
45174
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integrity-labs/agt-cli",
3
- "version": "0.28.879",
3
+ "version": "0.28.881",
4
4
  "description": "Augmented Team CLI — agent provisioning and management",
5
5
  "type": "module",
6
6
  "engines": {