fix(desktop): preserve Windows PATH for ACP probes#2420
Open
11w5 wants to merge 1 commit into
Open
Conversation
Signed-off-by: 11w5 <sloan@wombleco.com>
11w5
force-pushed
the
agent/fix-windows-agent-harness-launches
branch
from
July 22, 2026 21:21
cbecbd2 to
d645dba
Compare
11w5
marked this pull request as ready for review
July 22, 2026 21:27
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this fixes
On Windows, Buzz can find a current
codex-acp.cmdinstallation and still report it as outdated. The adapter is present; the version probe is what fails.The failure comes from how the child
PATHis assembled. Windows intentionally skips the Git Bash login-shell PATH because it is POSIX-shaped and unsafe for native processes. Buzz then builds an augmented PATH from its managed directories and executable directory. Because that value is set explicitly on the child, it replaces the desktop process's native PATH—including the directory containingnode.exe.That leaves an npm shim in an awkward state: Buzz resolves
codex-acp.cmdsuccessfully, but the shim cannot start Node. The failed--versionprobe is then interpreted as an outdated adapter.Closes #2342.
What changed
The behavior on macOS and Linux is unchanged; those platforms continue to use the login-shell PATH.
Scope and related work
I kept this PR deliberately focused on the missing-runtime PATH that causes the false "outdated" result. The broader Windows installer and hidden-console work is already being handled in #2247, with additional harness child console suppression in #2416. This PR does not duplicate those changes.
Validation
just desktop-tauri-fmt-check.cmdshim that invokes barenode.exethrough the composed PATHThe complete pre-push hook could not finish in this WSL environment: Flutter is not installed, and the Tauri test build requires the system ALSA development package. A full local Windows Tauri cross-check also stops in the unrelated native Opus build. GitHub CI should provide the complete supported build matrix.
Checklist
just cipasses locally (environment blockers described above)unwrap()in production code pathsunsafeblocks