Preserve MCP launch argument boundaries on Windows - #465
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7c8e7c3619
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| (defun ai-code-mcp-agent-prepare-launch (backend working-dir argv) | ||
| "Return MCP launch metadata for BACKEND, WORKING-DIR, and ARGV." |
There was a problem hiding this comment.
Preserve legacy string inputs to the public launch helper
When existing integrations call the public ai-code-mcp-agent-prepare-launch with its previously documented command string, ai-code-mcp-agent--inject-argv passes that string to append, producing a list of character codes rather than an argv list; the shared command normalizer then rejects the launch as invalid. Since the repository's naming convention identifies this single-dash function as public, normalize legacy strings here before injection so existing custom backends continue to start.
AGENTS.md reference: AGENTS.md:L148-L150
Useful? React with 👍 / 👎.
|
@copilot resolve the merge conflicts in this pull request |
# Conflicts: # ai-code-backends-infra.el # ai-code-claude-code.el # ai-code-github-copilot-cli.el # ai-code-mcp-agent.el # test/test_ai-code-backends-infra.el # test/test_ai-code-codex-cli.el # test/test_ai-code-github-copilot-cli.el # test/test_ai-code-open-interpreter-cli.el Co-authored-by: tninja <714625+tninja@users.noreply.github.com>
Resolved all merge conflicts in commit
|
Summary
Fixes #464 by keeping CLI launch commands as argv lists from command resolution through MCP injection and terminal startup. This prevents Windows paths, arguments containing spaces, and inline MCP configuration from being corrupted by shell quote/split round trips.
c:/...paths, spaced arguments, and backend-specific MCP configuration.Verification
209 focused ERT tests pass, and strict byte compilation of the touched production files completes without warnings. The full suite produced only the same nine unrelated failures that also reproduce at the base commit.