Skipped stdout draining after ProcessTerminal observes a native Windows terminal disconnect, while preserving normal postmortem cleanup and drain behavior for every other shutdown path.
Fixes#6917
(cherry picked from commit b45fc00ab4b5075ccb9650584947dde061beea20)
Compiled Bun binaries autoload project dotenv files, so snapshotting Bun.env inside one captured the secrets as launcher-owned and forwarded them to every shell. Drop that branch and record launcher values, restoring an empty launcher value that Bun overwrote with a dotenv secret.
- filterChildShellEnv now also filters Bun-autoloaded .env.{NODE_ENV||development}
entries, closing the .env.production/.env.development leak into child shells.
- parseEnvLine skips backslash-escaped quotes when locating the closing
delimiter, restoring baseline/Bun-literal handling of values like JSON="{\"a\":1}"
that the new parser truncated.
- Adds a parseEnvFile regression test for escaped quotes.
- The 2s deadline returned the -999 kill sentinel when a cold bun spawn
transpiling the pi-utils module graph exceeded it on loaded parallel CI
runners; green runs still resolve on child exit, so the bound only
guards genuine hangs.
Handled export prefixes and quote-aware inline comments when parsing dotenv files, and filtered child shells by launcher provenance so injected values are dropped regardless of value formatting.
Covered export and inline-comment forms in unit and shell-filter tests.
Fixes#6813
Tracked project values loaded by OMP separately from names present in the original launch environment, preserving parent values even when dotenv repeats the same bytes.
Covered Bun-autoloaded and no-env-file launch modes.
Fixes#6813
Bun's `process.title` setter is a JS-level no-op: it stores the value
internally but never calls `prctl(PR_SET_NAME)`, so `omp` appeared as
`bun` in ps/pgrep/killall/top and `pkill bun` became a footgun killing
every Bun process. Add `setProcessName` in pi-utils that also drives
prctl via bun:ffi on Linux, and use it at CLI startup and in the daemon
broker.
Fixes#6815
Matched both raw OMP-loaded values and Bun-expanded project values when removing launch dotenv entries from child shell environments.
Covered Bun autoload and no-env-file execution modes.
Fixes#6813
Filtered launch-directory .env and .env.local values from the base shell environment while preserving explicit per-command overrides.
Expanded the shell environment regression test across both dotenv files.
Fixes#6813
- Recorded the scoop/no-bash startup fix (No bash shell found) in pi-utils
and pi-coding-agent 17.1.4 sections, which were finalized before the fix
commit landed on the release.
- Added resolveWindowsShell to locate Git Bash, scoop installs, and path binaries with a fallback to cmd.exe.
- Updated bash-executor to prevent wrapping user commands in cmd.exe when using fallback shell paths.
- Updated installation script to report optional shell status rather than failing when bash is absent.
- getShellConfig returned the module cache before validating customShellPath, so a broken configured shell was silently masked once any earlier caller resolved a shell in the same process; PR #6581's settings-manager tests exposed the ordering under the full suite.
- A differing valid customShellPath now rebuilds the cached config instead of being ignored.
- Observed timed-out child lifecycle failures without altering awaited rejection semantics.
- Added coverage for callers that settle without observing the lifecycle promise.
Fixes#6635
Tracked the effective global, project, overlay, or runtime source of shellPath so resolution errors identify the configuration users must edit.
Covered custom agent directories and higher-precedence settings layers with focused regressions.
Fixes#6579
Updated Windows shell resolution errors to point at the canonical config.yml file instead of the migration-only settings.json path.
Added a regression test for the invalid custom shell path error.
Fixes#6579
Routed postmortem.quit through the mutable process.exit path while retaining captured native exits for host-owned shutdown.
Added child-process coverage proving guarded postmortem.quit calls surface ExtensionExitError without terminating the host.
Fixes#6488
- Captured the native hard-exit function for postmortem signal, fatal, and manual exits.
- Added bounded child-process coverage for SIGINT and fatal cleanup during pending guarded loads.
- Preserved extension and hook exit isolation and made the EPIPE race assertion observe the real exit event.
Fixes#6488
- Extracted internal handlers and logic from AgentSession into dedicated runner, guard, and coordinator modules.
- Created standalone modules for bash execution, evaluation runners, IRC bridging, and prewalk coordination.
- Established dedicated session components for tracking stats, todos, streams, and retry fallback chains.
- Preserved existing session behavior while significantly reducing monolithic class size and complexity.