fix(linux): prevent AppImage env from breaking curl-based agent installers and stop false UI success - #229
Draft
cursor[bot] wants to merge 2 commits into
Draft
fix(linux): prevent AppImage env from breaking curl-based agent installers and stop false UI success#229cursor[bot] wants to merge 2 commits into
cursor[bot] wants to merge 2 commits into
Conversation
…allers - Strip AppImage runtime variables (LD_LIBRARY_PATH, etc.) from spawned host processes so curl/npm/node/MCP servers load system libraries. - Run goose/hermes/poolside/zed Unix installers through bash with pipefail so a failed curl aborts the pipeline instead of returning exit 0. - Add regression test for sanitize_appimage_env. Fixes ATO-416 Co-authored-by: Mike <Vect0rM@users.noreply.github.com>
Return the result of detect(agent) instead of unconditionally returning true, and only show the success toast when the binary is actually found. Prevents the UI from reporting a successful install when the installer exited without placing the binary on PATH. Fixes ATO-416 Co-authored-by: Mike <Vect0rM@users.noreply.github.com>
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.
Describe Your Changes
Sanitize AppImage runtime environment before spawning host processes.
apply_login_pathnow callssanitize_appimage_env, which removes theAppImage-injected
LD_LIBRARY_PATH,APPDIR, and other runtime variablesfrom spawned commands. This stops system
curl/npm/node/MCP serversfrom loading the bundled (older) OpenSSL and breaking with symbol errors.
The same list is also applied to MCP stdio server spawns in
src/core/mcp/helpers.rs.Use
bashwithpipefailfor Unix curl-based agent installers.goose,hermes,poolside, andzedUnix install commands now run asbash -c 'set -o pipefail; curl -fsSL ... | ...'instead ofsh -c '...'.A failed
curlnow aborts the pipeline with a non-zero exit code instead ofbeing masked by the trailing shell exiting cleanly on an empty script.
Return the post-install detection result in the Launch UI.
installAgentnow returnsawait detect(agent)and only shows the successtoast when the binary is actually found. This prevents the UI from
reporting a successful install when the installer failed silently.
Add regression test for
sanitize_appimage_envensuring it removes allAppImage runtime variables from a spawned command.
Fixes Issues
Self Checklist
Note: this is a targeted bug fix that does not change user-facing docs.