@henryqw/pi-subagent 26.2.1 → 26.2.2

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.
@@ -19,7 +19,8 @@ export async function assertPrivateLease(path, allowMissing) {
19
19
  export async function scanProcessLease(path, execute, pid, allowMissing = false) {
20
20
  if (!await assertPrivateLease(path, allowMissing))
21
21
  return [];
22
- const args = ["-nP", "-a", ...(pid === undefined ? [] : ["-p", String(pid)]), "-F", "p", "--", path];
22
+ // -w: host-wide warnings (for example an unreachable network mount) are not lease evidence; real errors still reach stderr.
23
+ const args = ["-w", "-nP", "-a", ...(pid === undefined ? [] : ["-p", String(pid)]), "-F", "p", "--", path];
23
24
  const result = await execute(args);
24
25
  if (result.killed || ![0, 1].includes(result.code) || (result.code === 1 && (result.stdout.trim() || result.stderr.trim()))) {
25
26
  throw new Error("Exact process lease lsof scan failed or was ambiguous.");
@@ -28,7 +29,8 @@ export async function scanProcessLease(path, execute, pid, allowMissing = false)
28
29
  return [];
29
30
  if (result.stderr.trim())
30
31
  throw new Error("Exact process lease lsof scan returned unexpected diagnostics.");
31
- const lines = result.stdout.trim().split(/\r?\n/).filter(Boolean);
32
+ // lsof always selects the file descriptor field, so `-F p` also emits `f<fd>` lines.
33
+ const lines = result.stdout.trim().split(/\r?\n/).filter((line) => line && !/^f\w+$/.test(line));
32
34
  if (!lines.length || lines.some((line) => !/^p[1-9]\d*$/.test(line))) {
33
35
  throw new Error("Exact process lease lsof scan returned malformed PID fields.");
34
36
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@henryqw/pi-subagent",
3
- "version": "26.2.1",
3
+ "version": "26.2.2",
4
4
  "description": "Delegate bounded direct work or durable checked isolated task graphs to Pi roles.",
5
5
  "keywords": [
6
6
  "pi-package",