@henryqw/pi-herdr 0.4.9 → 0.5.0

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.
Files changed (2) hide show
  1. package/README.md +2 -2
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -8,7 +8,7 @@ Call the Herdr CLI from Node through one thin client. Extension authors share pr
8
8
  npm install @henryqw/pi-herdr
9
9
  ```
10
10
 
11
- Install the Herdr CLI and make `herdr` available on the calling process's `PATH`. Run `herdr --version` to verify it.
11
+ Install the Herdr CLI and make `herdr` available on the calling process's `PATH`. Requires Herdr 0.9.3 or later. Run `herdr --version` to verify it.
12
12
 
13
13
  ## Use
14
14
 
@@ -31,6 +31,6 @@ For a ready-to-use Pi workflow, see [`@henryqw/pi-herdr-tools`](https://pi.henry
31
31
  | `run` | function | Requires a successful exit and returns stdout. |
32
32
  | `json` | function | Requires a successful exit and parses a JSON object. |
33
33
  | `hasHerdrErrorCode` | function | Detects structured CLI errors in stdout or stderr. |
34
- | `startPiAgent` | function | Validates and builds the shared `agent start --kind pi --pane ... --` boundary. Before each start it checks with `pane process-info` that the pane shell still owns the foreground process group, runs `pane run <pane> "echo <token>"`, and polls `pane read` for up to 20 seconds until the token appears as its own output line with a prompt drawn after it. That proves the shell is reading input; without it, a launch command longer than 1024 bytes typed into a shell that is still starting or running a prompt hook loses its Enter on macOS and the pane waits forever. An occupied pane is not probed, so `agent start` still reports `agent_pane_busy`. A failed probe is returned as the result without starting the agent. These commands exist in Herdr 0.7.4 and later. It retries structured `agent_pane_busy` responses allowed by the caller's result-aware policy, with a five-attempt limit, and returns the raw final result. |
34
+ | `startPiAgent` | function | Validates and builds the shared `agent start --kind pi --pane ... --` boundary. Before each start it checks with `pane process-info` that the pane shell still owns the foreground process group, runs `pane run <pane> "echo <token>"`, and polls `pane read` for up to 20 seconds until the token appears as its own output line with a prompt drawn after it. That proves the shell is reading input; without it, a launch command longer than 1024 bytes typed into a shell that is still starting or running a prompt hook loses its Enter on macOS and the pane waits forever. An occupied pane is not probed, so `agent start` still reports `agent_pane_busy`. A failed probe is returned as the result without starting the agent. It retries structured `agent_pane_busy` responses allowed by the caller's result-aware policy, with a five-attempt limit, and returns the raw final result. |
35
35
 
36
36
  Callers build Pi-specific arguments and validate responses. The client does not mirror the Herdr command catalog. Herdr remains the source of truth for supported commands and response shapes.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@henryqw/pi-herdr",
3
- "version": "0.4.9",
3
+ "version": "0.5.0",
4
4
  "description": "Shared client for interacting with Herdr from Node.js tools and Pi packages.",
5
5
  "keywords": [
6
6
  "pi-package",