@integrity-labs/agt-cli 0.28.880 → 0.28.882

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.
@@ -63,7 +63,7 @@ import {
63
63
  safeWriteJsonAtomic,
64
64
  setConfigHash,
65
65
  tripClass
66
- } from "../chunk-SKLRC564.js";
66
+ } from "../chunk-XJQ3M2YV.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.880" : "dev";
13687
+ var agtCliVersion = true ? "0.28.882" : "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.880",
3
+ "version": "0.28.882",
4
4
  "description": "Augmented Team CLI — agent provisioning and management",
5
5
  "type": "module",
6
6
  "engines": {