pi-crew 0.11.7 → 0.11.9
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/.githooks/pre-commit +22 -0
- package/.githooks/pre-push +56 -0
- package/CHANGELOG.md +196 -1
- package/dist/index.mjs +533 -515
- package/docs/publishing.md +29 -0
- package/docs/usage.md +1 -1
- package/index.ts +3 -3
- package/install.mjs +4 -1
- package/package.json +8 -5
- package/scripts/install-hooks.mjs +32 -0
- package/skills/real-test-pi-crew/SKILL.md +57 -18
- package/src/config/config-validation.ts +8 -1
- package/src/config/defaults.ts +8 -1
- package/src/config/env-vars.ts +16 -1
- package/src/config/types.ts +28 -4
- package/src/extension/command-completions.ts +44 -22
- package/src/extension/registration/foreground-run-controller.ts +19 -10
- package/src/extension/registration/lifecycle-handlers.ts +6 -491
- package/src/extension/registration/lifecycle.ts +7 -90
- package/src/extension/registration/render-loop.ts +532 -0
- package/src/extension/team-tool/doctor.ts +6 -0
- package/src/extension/team-tool/handle-settings.ts +4 -1
- package/src/runtime/child-pi/child-pi-spawn.ts +7 -0
- package/src/runtime/child-pi/child-pi.ts +37 -2
- package/src/runtime/child-pi/pi-version.ts +187 -0
- package/src/runtime/classifier/classifier-service.ts +298 -0
- package/src/runtime/dispatch-batch.ts +4 -0
- package/src/runtime/live-session/live-session-runtime.ts +31 -0
- package/src/runtime/model/pi-args.ts +62 -3
- package/src/runtime/process/zombie-scanner.ts +168 -7
- package/src/runtime/rpc/README.md +64 -25
- package/src/runtime/rpc/rpc-worker.ts +146 -26
- package/src/runtime/run-worker.ts +89 -15
- package/src/runtime/scheduling/run-coalesced-task-group.ts +3 -0
- package/src/runtime/skill-instructions.ts +66 -1
- package/src/runtime/surface/resolve-surface.ts +34 -19
- package/src/runtime/task-runner/child-executor.ts +132 -0
- package/src/runtime/task-runner/pre-execution.ts +8 -0
- package/src/runtime/task-runner.ts +6 -0
- package/src/schema/config-schema.ts +20 -8
- package/src/schema/team-tool-schema.ts +4 -2
- package/src/state/contracts.ts +5 -0
- package/src/ui/dashboard-panes/agents-pane.ts +3 -2
- package/src/ui/dashboard-panes/health-pane.ts +6 -1
- package/src/ui/dashboard-panes/mailbox-pane.ts +12 -7
- package/src/ui/dashboard-panes/plan-pane.ts +5 -2
- package/src/ui/dashboard-panes/progress-pane.ts +8 -2
- package/src/ui/format-helpers.ts +11 -0
- package/src/ui/live-conversation-overlay.ts +5 -3
- package/src/ui/live-duration.ts +5 -4
- package/src/ui/live-run-sidebar.ts +90 -20
- package/src/ui/overlays/mailbox-compose-overlay.ts +31 -1
- package/src/ui/rail.ts +14 -1
- package/src/ui/run-action-dispatcher.ts +2 -1
- package/src/ui/run-dashboard.ts +62 -22
- package/src/ui/run-snapshot-cache.ts +32 -0
- package/src/ui/settings-overlay.ts +36 -3
- package/src/ui/tool-renderers/brief-mode.ts +2 -2
- package/src/ui/transcript-viewer.ts +4 -1
- package/src/ui/widget/index.ts +10 -2
- package/src/ui/widget/task-list.ts +22 -7
- package/src/ui/widget/widget-model.ts +5 -4
- package/src/ui/widget/widget-renderer.ts +212 -37
- package/src/utils/relative-time.ts +11 -3
- package/src/utils/socket-path.ts +48 -8
- package/src/utils/visual.ts +32 -2
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# pi-crew pre-commit hook — block lockfile-drift commits locally.
|
|
3
|
+
#
|
|
4
|
+
# Catches the "bump a devDependency in package.json but forget `npm install`"
|
|
5
|
+
# class of CI failure BEFORE it is pushed. Runs the fast (<50ms, no install)
|
|
6
|
+
# check-lockfile-sync.mjs gate only when package.json or package-lock.json is
|
|
7
|
+
# staged, so it adds zero overhead to unrelated commits.
|
|
8
|
+
#
|
|
9
|
+
# Activate once per clone: git config core.hooksPath .githooks
|
|
10
|
+
# Bypass for a WIP commit: git commit --no-verify (CI will still catch it)
|
|
11
|
+
|
|
12
|
+
set -euo pipefail
|
|
13
|
+
|
|
14
|
+
# Only run when the manifests are staged (cheap path for unrelated commits).
|
|
15
|
+
if git diff --cached --name-only -- package.json package-lock.json | grep -q .; then
|
|
16
|
+
echo "[pre-commit] checking package.json ↔ package-lock.json sync…"
|
|
17
|
+
if ! node scripts/check-lockfile-sync.mjs; then
|
|
18
|
+
echo "[pre-commit] ✋ commit blocked: package-lock.json is out of sync."
|
|
19
|
+
echo "[pre-commit] Fix: run 'npm install' and 'git add package-lock.json', or use --no-verify to bypass (CI still gates)."
|
|
20
|
+
exit 1
|
|
21
|
+
fi
|
|
22
|
+
fi
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# pi-crew pre-push hook — broaden the local release gate (D3).
|
|
3
|
+
#
|
|
4
|
+
# The 2026-10 CI-red recurrence: pushes to origin/main ran only
|
|
5
|
+
# test:critical (~120 tests) locally, while CI runs the FULL unit suite —
|
|
6
|
+
# three waves in a row shipped red. This hook closes that gap BEFORE the
|
|
7
|
+
# push leaves the machine.
|
|
8
|
+
#
|
|
9
|
+
# Scope:
|
|
10
|
+
# push to refs/heads/main → check:conflict-markers + typecheck, then the
|
|
11
|
+
# FULL unit suite (npm run test:unit — the same
|
|
12
|
+
# gate CI runs); any failure blocks the push
|
|
13
|
+
# any other ref → fast gates only (check:conflict-markers +
|
|
14
|
+
# typecheck)
|
|
15
|
+
#
|
|
16
|
+
# Activated by `npm install` (prepare → scripts/install-hooks.mjs sets
|
|
17
|
+
# git config core.hooksPath .githooks) or manually:
|
|
18
|
+
# git config core.hooksPath .githooks
|
|
19
|
+
# Emergency bypass: git push --no-verify (CI still gates main).
|
|
20
|
+
|
|
21
|
+
set -euo pipefail
|
|
22
|
+
|
|
23
|
+
cd "$(git rev-parse --show-toplevel)"
|
|
24
|
+
|
|
25
|
+
pushes_main=0
|
|
26
|
+
while read -r local_ref local_sha remote_ref remote_sha; do
|
|
27
|
+
if [ "$remote_ref" = "refs/heads/main" ]; then
|
|
28
|
+
pushes_main=1
|
|
29
|
+
fi
|
|
30
|
+
done
|
|
31
|
+
|
|
32
|
+
if ! npm run check:conflict-markers; then
|
|
33
|
+
echo "[pre-push] ✋ push blocked: conflict markers present."
|
|
34
|
+
echo "[pre-push] Fix: resolve the markers, or bypass with 'git push --no-verify' (CI still gates)."
|
|
35
|
+
exit 1
|
|
36
|
+
fi
|
|
37
|
+
if ! npm run typecheck; then
|
|
38
|
+
echo "[pre-push] ✋ push blocked: typecheck failed."
|
|
39
|
+
echo "[pre-push] Fix the errors above, or bypass with 'git push --no-verify' (CI still gates)."
|
|
40
|
+
exit 1
|
|
41
|
+
fi
|
|
42
|
+
|
|
43
|
+
if [ "$pushes_main" = "1" ]; then
|
|
44
|
+
echo "[pre-push] push to main: running the FULL unit suite (test:unit)…"
|
|
45
|
+
# Capture the full log so a flake's failing test is identifiable even when
|
|
46
|
+
# the push output is truncated by tooling (lesson 2026-10-07: three hook
|
|
47
|
+
# blocks lost their failure detail to a trailing `| tail`).
|
|
48
|
+
UNIT_LOG="${TMPDIR:-/tmp}/pi-crew-prepush-unit.log"
|
|
49
|
+
if ! npm run test:unit 2>&1 | tee "$UNIT_LOG"; then
|
|
50
|
+
echo "[pre-push] ✋ push blocked: test:unit failed (full log: $UNIT_LOG)."
|
|
51
|
+
echo "[pre-push] Fix the failures above, or bypass with 'git push --no-verify' (CI still gates)."
|
|
52
|
+
exit 1
|
|
53
|
+
fi
|
|
54
|
+
fi
|
|
55
|
+
|
|
56
|
+
echo "[pre-push] gates green."
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,201 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.11.9] — F-BAT1: broker socket dir dodges /tmp pi-crew-* sweeps + stale-probe race (2026-10-08)
|
|
4
|
+
|
|
5
|
+
Live-caught by the full-tier battery (T9b-W): worker coordination (`ask`/`message`/`delegate`)
|
|
6
|
+
returned ENOENT in BOTH sync and async runs while the runs stayed green (graceful degrade —
|
|
7
|
+
the exact silent-failure class the battery exists to catch).
|
|
8
|
+
|
|
9
|
+
Two stacked root causes:
|
|
10
|
+
|
|
11
|
+
1. **Namespace collision** — with `XDG_RUNTIME_DIR` absent (sessions launched from
|
|
12
|
+
non-login envs), the broker's per-user dir fell back to `/tmp/pi-crew-<uid>`, which
|
|
13
|
+
THREE /tmp workspace sweeps (`cleanupLegacyOrphanTempDirs`, the orphan temp
|
|
14
|
+
reconciler, the health zombie scan) pattern-match as `pi-crew-*` debris and `rmSync`
|
|
15
|
+
— deleting the LIVE broker socket dir. Sessions with XDG_RUNTIME_DIR were
|
|
16
|
+
unaffected (/run/user is never swept), which is why this only bit some launches.
|
|
17
|
+
Fix: the no-XDG fallback now uses `.pi-crew-broker-<uid>` (dot-prefixed — no sweep
|
|
18
|
+
matches). XDG path unchanged.
|
|
19
|
+
2. **Stale-probe race** — `removeStaleBrokerSocket` treated a connect TIMEOUT as
|
|
20
|
+
"stale" and unlinked a HEALTHY (slow-to-accept) broker socket. Only a definitive
|
|
21
|
+
`ECONNREFUSED` (kernel rejects connect on a listener-less socket) may ever unlink.
|
|
22
|
+
|
|
23
|
+
Cross-platform hardening (CI 2026-10-08, macOS catch): a NON-SOCKET entry at the
|
|
24
|
+
socket path (the classic leftover corpse) is now removed deterministically via
|
|
25
|
+
`lstat` — no connect probe — because connect() to a non-socket path is undefined
|
|
26
|
+
across kernels (Linux yields ECONNREFUSED, macOS a different errno). Sockets keep
|
|
27
|
+
the probe path: ECONNREFUSED → remove, timeout/other → keep.
|
|
28
|
+
|
|
29
|
+
Live re-verified end-to-end on the fixed bundle: socket binds at
|
|
30
|
+
`/tmp/.pi-crew-broker-1000/`, `ask` round-trip delivers the leader reply through
|
|
31
|
+
dependency-context (worker quotes it verbatim), `message` notify delivered, socket
|
|
32
|
+
survives the whole run. Pin suite `socket-path-fbat1.test.ts` (6 tests,
|
|
33
|
+
mutation-checked both halves; single mutations are neutralized by the paired guard —
|
|
34
|
+
defense-in-depth by design).
|
|
35
|
+
|
|
36
|
+
## [0.11.9] — UI instability fix wave L1–L9 (2026-10-07)
|
|
37
|
+
|
|
38
|
+
Live-battery-driven fixes from the 2026-10-07 UI review
|
|
39
|
+
(docs/real-test/reports/real-test-2026-10-07-ui-instability-review.md +
|
|
40
|
+
real-test-2026-10-07-ui-fix-wave.md — 4 real runs, 308 live frames, T1/T5/T13 gates,
|
|
41
|
+
5/5 mutation-verified pins).
|
|
42
|
+
|
|
43
|
+
### Fixed
|
|
44
|
+
|
|
45
|
+
- **L1 — crew dock renders in every session (HIGH)**: `activeWidgetRuns()` no longer filters
|
|
46
|
+
runs by `ownerSessionId` — bystander terminals now see active runs owned by other sessions
|
|
47
|
+
(live evidence: 308 frames across 3 async runs + 1 headless run rendered 0 docks; widget of
|
|
48
|
+
another extension updated fine in the same session). Crash-recovery scoping unchanged.
|
|
49
|
+
- **L2 — no more flicker around run completion (HIGH-MED)**: the render-loop health gates
|
|
50
|
+
(GATE 1 / FIX#1 / GATE 3) now rebuild snapshots in place (`scheduleRefresh`) instead of
|
|
51
|
+
hard-deleting cache entries — restoring the FLICKER FIX invariant the gates had been
|
|
52
|
+
violating on every tick for terminal/divergent runs.
|
|
53
|
+
- **L3 — dashboard defaults to the right-anchored panel**: `ui.dashboardPlacement` default
|
|
54
|
+
`"center"` → `"right"` (mirrors updated in install.mjs + both EFFECTIVE_DEFAULTS maps). The
|
|
55
|
+
centered 90% overlay exposed chopped background words at both margins on every width probed
|
|
56
|
+
(160/100/80) — pi-tui keeps base content visible outside overlay bounds by design.
|
|
57
|
+
- **L4 — sidebar auto-close deadline no longer slides**: the deadline is captured on first
|
|
58
|
+
eligibility and re-armed only when the run leaves terminal state; the "auto-close in 3s…"
|
|
59
|
+
countdown now reflects a fixed deadline instead of being reset by every re-render.
|
|
60
|
+
- **L6 — sidebar height locked** (dashboard `targetHeight()` pattern): loading → loaded →
|
|
61
|
+
shrunk frames share one height, killing ghost `┃` rows.
|
|
62
|
+
- **L5 — sync snapshot rebuild off the paint path**: new `readForRender()` cached-only accessor
|
|
63
|
+
+ coalesced async refresh for render(); keypress paths with sync read-after-write keep
|
|
64
|
+
`refreshIfStale` (Tier 11a read-your-writes preserved).
|
|
65
|
+
|
|
66
|
+
### Changed
|
|
67
|
+
|
|
68
|
+
- **L7 — TUI dialect sweep**: dashboard agent preview + mailbox pane now use `↑/↓` compact
|
|
69
|
+
usage instead of `tok=/in=/out=/model=/age=` wire format; live-conversation overlay uses
|
|
70
|
+
`formatDuration` (`5m44s`) instead of raw seconds; dead `formatLiveDuration` export removed.
|
|
71
|
+
- **L8 — `CURSOR_MARKER` defensive resolve** (settings overlay, mailbox compose): named import
|
|
72
|
+
replaced with the W4/G22 typeof-guard pattern — no ESM crash on hosts whose pi-tui lacks the
|
|
73
|
+
export.
|
|
74
|
+
- **L9 — dock truncation priority**: status pieces (`1 running`, `3/5 done`) are atomic — they
|
|
75
|
+
render whole or drop, never split mid-word (`1 runnin…` gone at 40 cols); meta pieces drop
|
|
76
|
+
first; plurals via `formatCount` across dashboard/panes/dispatcher.
|
|
77
|
+
|
|
78
|
+
## [0.11.8] — Pi 1.0.4 adoption + RPC/surface hardening + battery-proven stability (2026-10-07)
|
|
79
|
+
|
|
80
|
+
### Added — deep-learn polish batch (docs/reviews/pi-1.0.0-deep-learn-r3-2026-10-03.md R3 matrix)
|
|
81
|
+
|
|
82
|
+
- **RPC worker transport wired (P2-3 integration)** — after a live-fire probe against a real
|
|
83
|
+
`pi --mode rpc` (24 ui-requests drained by the drain policy; dialog auto-answered `cancel`
|
|
84
|
+
with no deadlock; steer honored at 53 ms RTT), the `runtime.workerTransport: "rpc"` path now
|
|
85
|
+
dispatches real RPC workers with worker-cap parity, a pre-abort short-circuit, and a guarded
|
|
86
|
+
stdio fallback. Still experimental: minimal input mapping, raw model passthrough, ephemeral
|
|
87
|
+
sessions (see src/runtime/rpc/README.md).
|
|
88
|
+
- **Skill advertisement dedup (R3-23)** — the worker spawn path no longer duplicates the host's
|
|
89
|
+
`<available_skills>` block with pi-crew's own per-skill index; measured ~232–284 tokens/worker
|
|
90
|
+
(~65% of the block) saved, ~1.9k tokens per 8-role wave. Live-session/scaffold keep the full
|
|
91
|
+
block.
|
|
92
|
+
- **Foreign-pi orphan scan (R3-16)** — `doctor --zombies` now WARN-lists orphaned pi processes
|
|
93
|
+
via `AI_AGENT`/`PI_CODING_AGENT` markers (exact-value match, argv pi-binary gate, self/ancestor
|
|
94
|
+
exclusion). Report-only by design — never a kill candidate.
|
|
95
|
+
- **Worker session labels (R3-15)** — headless workers spawn with `--name crew-<taskId>` for
|
|
96
|
+
human-friendly session pickers.
|
|
97
|
+
- **Live-session scoped models (R3-12)** — live sessions bind `scopedModels` to the configured
|
|
98
|
+
fallback chain (explicit-chain-only; user overrides preserved — scope is visibility, not gate).
|
|
99
|
+
- **OSC-8 dock link (R3-9)** — the crew dock subject is a `file://` hyperlink to the latest run's
|
|
100
|
+
artifacts dir; degrades to plain text on old hosts, escape-safe under truncation.
|
|
101
|
+
|
|
102
|
+
### Changed
|
|
103
|
+
|
|
104
|
+
- **Local pre-push release gate broadened via committed `.githooks/` (D3)** — a new
|
|
105
|
+
`pre-push` hook (activated by the `prepare` script on `npm install`, or manually via
|
|
106
|
+
`git config core.hooksPath .githooks`) runs `check:conflict-markers` + `typecheck` on every
|
|
107
|
+
push, and additionally the FULL `test:unit` suite when pushing to `refs/heads/main` — the
|
|
108
|
+
same gate CI runs — so a leader's local fast-gate-only push can no longer ship red.
|
|
109
|
+
Emergency bypass: `git push --no-verify` (CI still gates). Documented in docs/publishing.md.
|
|
110
|
+
- **`runtime.workerTransport` config plumbed to the run-worker seam (D1/DR2)** — the config key
|
|
111
|
+
is no longer parse+emit-only dead: callers carrying runtimeConfig (child-executor,
|
|
112
|
+
run-coalesced-task-group) thread it to `runWorker`, with the established precedence
|
|
113
|
+
env > config > default stdio (`PI_CREW_WORKER_TRANSPORT` still wins when set; invalid values
|
|
114
|
+
fail safe to stdio). The three stale "not-implemented" doc blocks (config-schema.ts,
|
|
115
|
+
config/types.ts, env-vars.ts) now describe the wired state; the F19-1 comment records that
|
|
116
|
+
emission without a consumer is still dead. dynamic-workflow-context and goal-evaluator have
|
|
117
|
+
no runtimeConfig and deliberately keep default stdio.
|
|
118
|
+
- `setupRenderLoop` extracted byte-identically into `src/extension/registration/render-loop.ts`
|
|
119
|
+
(lifecycle-handlers.ts 1347→897 lines) (QW#2).
|
|
120
|
+
- `formatDuration` name collision resolved with domain names (`formatTaskElapsed`,
|
|
121
|
+
`formatRelativeCompact`) — zero output-format changes (QW#5).
|
|
122
|
+
- wc-gate now scans **all of `src/`** (527 files; 0 violations, max 1908) (QW#3).
|
|
123
|
+
- f19-config-parity test now auto-derives runtime keys 3-way (types ↔ schema ↔ parser) — no hand
|
|
124
|
+
lists; mutation-verified (parse-dead and phantom keys both fail loudly).
|
|
125
|
+
- IME-safe cursors: hand-written text inputs emit pi-tui `CURSOR_MARKER` (R3-6).
|
|
126
|
+
- Bundle benchmark comment refreshed to the re-measured ~36% cold-start gap (QW#6).
|
|
127
|
+
- R3-10 (withFileMutationQueue) skipped with evidence: pi-crew's flock-based mutation locks
|
|
128
|
+
already cover the named paths; the SDK helper is in-process-only — double-lock for no gain.
|
|
129
|
+
|
|
130
|
+
### Added — Pi 1.0.4 adoption wave (see docs/reviews/pi-1.0.4-upgrade-notes-2026-10-06.md)
|
|
131
|
+
|
|
132
|
+
- **devDeps on the pi SDK 1.0.4 (U1, P0)** — all four `@earendil-works` devDeps bumped
|
|
133
|
+
`^1.0.0`→`^1.0.4` with a lockfile refresh. pi-coding-agent@1.0.4 direct-pins
|
|
134
|
+
`brace-expansion 5.0.12`, closing the accepted dev-scope 5.0.9 finding: the top level now
|
|
135
|
+
hoists 5.0.12 and the pi subtree no longer nests a copy.
|
|
136
|
+
- **Thinking level `max` (U4)** — `THINKING_LEVELS` carries all 7 pi levels (was 6);
|
|
137
|
+
frontmatter `thinking: max` was previously rejected by `isValidThinkingLevel` even though
|
|
138
|
+
pi's CLI documents it.
|
|
139
|
+
- **MCP cut for parity spawns (U2-lite)** — pi 1.0.4 no longer cuts MCP under `--tools`, so
|
|
140
|
+
parity (NON-hermetic) spawns fold `mcp__*` into their single `--exclude-tools` value
|
|
141
|
+
(merged comma-sep with frontmatter `disallowedTools`; pi's strict parser rejects duplicate
|
|
142
|
+
flags). Hermetic defaults gain no new flag — `--no-extensions` already kills built-in MCP
|
|
143
|
+
on 1.0.4. Cross-version-safe: on pre-1.0.4 hosts the pattern matches no literal tool name.
|
|
144
|
+
- **Classifier seam, dormant (P2-1)** — `runtime.classifierEnabled` (default **false**) +
|
|
145
|
+
`runtime.classifierModel` (default `opencode/jev-1.13-free`; env `PI_CREW_CLASSIFIER_ENABLED`
|
|
146
|
+
/ `PI_CREW_CLASSIFIER_MODEL` beats config) land with full config ceremony (schema → types →
|
|
147
|
+
validation → env registry → snapshot test). Host-process `classifyBool()` is never-rejects:
|
|
148
|
+
missing registry / no classifier available / classify throw / `stopReason:"error"` all return
|
|
149
|
+
the caller-supplied fallback decision with log-once + `crew.classifier.calls_total` counters —
|
|
150
|
+
never an exception up to the orchestrator. Spike consumer: child-executor retry-triage
|
|
151
|
+
classifies transient-vs-permanent before burning a re-attempt (event `task.retry_triage`,
|
|
152
|
+
metric `crew.classifier.decisions_total`); default-off never touches the registry (zero
|
|
153
|
+
behavior change, test-pinned). Live-fire probe for post-credential runs:
|
|
154
|
+
`scripts/probe-classifier.mjs`.
|
|
155
|
+
- **Pi version floor + `--no-mcp` on parity spawns (U9)** — new `probePiVersion()` (single-flight
|
|
156
|
+
per process, ~5 s timeout, failure → null = unknown) probes the same binary worker spawns
|
|
157
|
+
use, plus hand-rolled `comparePiVersion` (no semver dependency — deliberate, see the module;
|
|
158
|
+
malformed → null, conservative). Non-hermetic parity spawns now append `--no-mcp` when the
|
|
159
|
+
host pi is ≥ 1.0.4 — disconnecting ambient MCP servers, strictly stronger than the U2-lite
|
|
160
|
+
`mcp__*` tool-cut (kept as the cross-version-safe baseline). Below the floor or unknown →
|
|
161
|
+
no flag; hermetic path unchanged.
|
|
162
|
+
|
|
163
|
+
### Fixed
|
|
164
|
+
|
|
165
|
+
- **RPC transport lifecycle hardening (DR1/DR5)** — the experimental RPC worker transport can
|
|
166
|
+
no longer hang a worker-cap slot forever: the settle wait races `client.exited()` + a
|
|
167
|
+
belt-and-suspenders turn timeout (env `PI_CREW_RPC_TURN_TIMEOUT_MS`, default 600 000 ms,
|
|
168
|
+
env-only while RPC stays experimental; invalid/≤0 → default). Exit-before-`agent_settled`
|
|
169
|
+
and turn-timeout map to the early-failure shape so the stdio fallback engages and the slot
|
|
170
|
+
is released. DR5 closes the double-execution window: a session event after the prompt marks
|
|
171
|
+
the turn as started (`result.rpcAgentStarted`), and started-but-unsettled failures are
|
|
172
|
+
surfaced, never retried. New seam tests: crash-before-settle (fallback + slot released),
|
|
173
|
+
started-then-fail (no fallback), turn timeout (early-failure shape).
|
|
174
|
+
- **`consumeAnsi` handles APC sequences (U6/DR4)** — an APC branch (ESC `_` … terminated by
|
|
175
|
+
BEL 0x07 or ST ESC `\`) sits beside the OSC branch with mirrored terminators and
|
|
176
|
+
control-char fallback, so pi-tui's `CURSOR_MARKER` (an APC string) measures zero-width;
|
|
177
|
+
`truncateToWidth`/`wrapHard` no longer count it as ~6 visible columns.
|
|
178
|
+
|
|
179
|
+
- **herdr liveness ping survives ESM hosts** (battery 2026-10-07, T10c) — `pingSocketSync`'s eval'd
|
|
180
|
+
Worker used bare `require(...)`; under a `--input-type=module` host the eval source parses as ESM,
|
|
181
|
+
`require` throws, and the ping fail-closed to false → herdr degraded "socket not live" against a
|
|
182
|
+
LIVE socket (CJS hosts like the pi CLI were unaffected). The worker source is now dual-mode
|
|
183
|
+
(`require` try → dynamic `import()` fallback) and exported for tests;
|
|
184
|
+
`test/unit/runtime/surface/resolve-surface-ping.test.ts` pins both module contexts + fail-closed.
|
|
185
|
+
- **resume-liveness F1 test stabilized** (battery 2026-10-07) — the "re-checks liveness INSIDE the run lock"
|
|
186
|
+
test raced the lock ACQUISITION itself (test vs resume; ~1/3 red even isolated — it blocked the new
|
|
187
|
+
pre-push hook twice). Entered-signal now guarantees the lock is held before the resume starts, making
|
|
188
|
+
both orderings of the pre-lock check deterministic refusals. 8/8 green isolated (was ~2/3).
|
|
189
|
+
|
|
190
|
+
### Ops notes
|
|
191
|
+
|
|
192
|
+
- **Azure provider rename in pi 1.0.3 (U3)** — pi renamed provider id
|
|
193
|
+
`azure-openai-responses`→`azure`; `AZURE_OPENAI_*` env vars are unchanged. User config
|
|
194
|
+
(`auth.json`/`models.json`/`settings.json`) entries under the old id need renaming.
|
|
195
|
+
pi-crew code is unaffected — `env-filter.ts` PROVIDER_ENV_KEY_MAP already keys `azure`
|
|
196
|
+
and `azure-openai` (both → `AZURE_OPENAI_*`).
|
|
197
|
+
|
|
198
|
+
|
|
3
199
|
## [0.11.7] — Pi 1.0.0 adoption waves + deep-learn execution (2026-10-04)
|
|
4
200
|
### Added — Pi 1.0.0 adoption wave (see docs/reviews/pi-1.0.0-adoption-review-2026-10-03.md)
|
|
5
201
|
|
|
@@ -5118,7 +5314,6 @@ the user sees "Goal failed: Background runner died unexpectedly" instead of
|
|
|
5118
5314
|
an infinite "running" state.
|
|
5119
5315
|
|
|
5120
5316
|
|
|
5121
|
-
|
|
5122
5317
|
### `goal` — autonomous goal loop (P0a + P0 + P1)
|
|
5123
5318
|
|
|
5124
5319
|
- `team action='goal' config.subAction='start|status|pause|resume|stop|step|clear'`.
|