grepmax 0.26.79 → 0.26.80

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.
@@ -10,7 +10,7 @@
10
10
  "name": "grepmax",
11
11
  "source": "./plugins/grepmax",
12
12
  "description": "Semantic code search for Claude Code. Automatically indexes your project and provides intelligent search capabilities.",
13
- "version": "0.26.79",
13
+ "version": "0.26.80",
14
14
  "author": {
15
15
  "name": "Robert Owens",
16
16
  "email": "robowens@me.com"
package/README.md CHANGED
@@ -532,7 +532,7 @@ Production recovery currently requires macOS, a persistent `autostart-disabled`
532
532
 
533
533
  The child waits for launch and deletion admission tokens, with verified helper PID/start identity recorded as the primary exclusive owner. Existing readers retain exclusion if the parent dies while the helper is alive. Current/tagged/post-cutoff metadata is verified after pruning; recovery refuses more than 256 protected versions before deletion to bound verification. Interrupted attempts require verification and explicit acknowledgement before retry. Linux/APFS fixtures exercise native retention and interruption; supported production host admission is tested separately and still runs freshly for each operation.
534
534
 
535
- If a short-lived client child exits during memory sampling, confirmed dead processes can leave the sample while all surviving processes retain measured footprints. An uncertain exit, new process or changed identity requires a complete fresh measurement; a normal-pressure sample may do that once within the original deadline. It never accepts an unmeasured live process. Continued changes, unavailable measurements and critical pressure still refuse admission; warning admission follows the recovery policy above.
535
+ If a short-lived client child exits during memory sampling, confirmed dead processes can leave the sample while all surviving processes retain measured footprints. An uncertain exit, new process or changed identity requires a complete fresh measurement; a recovery sample may do that once within the original deadline while retaining any observed OS warning for the final policy check. Normal service requires normal pressure for this retry. It never accepts an unmeasured live process. Continued changes, unavailable measurements and critical pressure still refuse admission; warning admission follows the recovery policy above.
536
536
 
537
537
  For an operator-coordinated recovery window:
538
538
 
@@ -60,6 +60,9 @@ function createRecoveryBudget() {
60
60
  kernelProbeTimeoutMs: 5000,
61
61
  commandProbeTimeoutMs: 3000,
62
62
  footprintProbeTimeoutMs: 3000,
63
+ // Re-measure a changing cohort while retaining warning severity. The
64
+ // fresh policy check above still decides whether that warning is allowed.
65
+ retryWarningPressure: true,
63
66
  },
64
67
  sampleMaxAgeMs: 10000,
65
68
  });
@@ -134,13 +134,20 @@ function sampleHostResources(extraPids = [], overrides = {}, extraGroups = []) {
134
134
  const monotonic = (_a = overrides.monotonic) !== null && _a !== void 0 ? _a : (() => performance.now());
135
135
  const deadline = monotonic() + ((_b = overrides.sampleTimeoutMs) !== null && _b !== void 0 ? _b : exports.HOST_SAMPLE_TIMEOUT_MS);
136
136
  let snapshot;
137
+ let observedWarning = false;
137
138
  for (let attempt = 0; attempt < 2; attempt++) {
138
139
  snapshot = sampleHostResourcesOnce(extraPids, Object.assign(Object.assign({}, overrides), { monotonic, sampleTimeoutMs: Math.max(0, deadline - monotonic()) }), extraGroups);
140
+ observedWarning || (observedWarning = snapshot.memoryPressure === "warn");
141
+ // A fresh complete cohort may retain an observed warning; retrying must
142
+ // never downgrade it to normal or weaken the caller's final policy check.
143
+ if (observedWarning && snapshot.memoryPressure === "normal")
144
+ snapshot.memoryPressure = "warn";
139
145
  // Short-lived client children routinely exit during footprint sampling.
140
146
  // Re-measure the entire cohort once, within the original deadline. Never
141
- // accept a partial total or retry away observed warning/critical pressure.
147
+ // accept a partial total or downgrade observed warning/critical pressure.
142
148
  if (attempt === 1 ||
143
- snapshot.memoryPressure !== "normal" ||
149
+ (snapshot.memoryPressure !== "normal" &&
150
+ !(overrides.retryWarningPressure && snapshot.memoryPressure === "warn")) ||
144
151
  snapshot.kernelPressure !== "ok" ||
145
152
  snapshot.incompleteReasons.length !== 1 ||
146
153
  snapshot.incompleteReasons[0] !==
@@ -163,7 +170,7 @@ function sampleHostResourcesOnce(extraPids, overrides, extraGroups) {
163
170
  return false;
164
171
  throw new Error("process liveness unavailable");
165
172
  }
166
- }, sampleTimeoutMs: exports.HOST_SAMPLE_TIMEOUT_MS, kernelProbeTimeoutMs: 500, commandProbeTimeoutMs: 500, footprintProbeTimeoutMs: 1500, run: (command, args, timeoutMs) => (0, node_child_process_1.execFileSync)(command, args, {
173
+ }, sampleTimeoutMs: exports.HOST_SAMPLE_TIMEOUT_MS, kernelProbeTimeoutMs: 500, commandProbeTimeoutMs: 500, footprintProbeTimeoutMs: 1500, retryWarningPressure: false, run: (command, args, timeoutMs) => (0, node_child_process_1.execFileSync)(command, args, {
167
174
  encoding: "utf8",
168
175
  timeout: timeoutMs,
169
176
  maxBuffer: 512 * 1024,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "grepmax",
3
- "version": "0.26.79",
3
+ "version": "0.26.80",
4
4
  "author": "Robert Owens <78518764+reowens@users.noreply.github.com>",
5
5
  "homepage": "https://github.com/reowens/grepmax",
6
6
  "bugs": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "grepmax",
3
- "version": "0.26.79",
3
+ "version": "0.26.80",
4
4
  "description": "Semantic code search for Claude Code. Automatically indexes your project and provides intelligent search capabilities.",
5
5
  "author": {
6
6
  "name": "Robert Owens",