Repository navigation
[EPMTIOOPS-20511] Keep args with spaces intact in MCP Servers Args field - #61
Open
DmytroHavryshGoTo wants to merge 1 commit into
Open
DmytroHavryshGoTo wants to merge 1 commit into
DmytroHavryshGoTo wants to merge 1 commit into
Conversation
Editing the Args field split every arg on whitespace, so a saved
`--device "Desktop Chrome"` became `--device Desktop Chrome` and the
server exited before the MCP handshake ("Connection closed").
- Parse the field with quote-aware splitting and quote args with spaces
on display; backslashes stay literal for Windows paths.
- Keep the typed text per card so the field isn't re-formatted mid-edit.
- Append the stdio server's stderr tail to connect errors.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
Code reviewNo issues found. Checked for bugs and CLAUDE.md compliance. 🤖 Generated with Claude Code |
dyachenko-yaroslav
approved these changes
Oct 6, 2026
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.
EPMTIOOPS-20511
Problem
Typing anything in the Args field on the MCP Servers page re-split every argument on whitespace. A saved
--device "Desktop Chrome"was written back as--device Desktop Chrome.@playwright/mcpthen exits withtoo many arguments, and the app only showsMCP error -32000: Connection closed. This affects every platform and any argument with a space (device names, paths).Fix
src/renderer/lib/args.ts: splits on whitespace but keeps quoted text together, and quotes arguments that contain spaces when showing them. Backslashes stay literal, so Windows paths work.McpServersPage.svelte: keeps the text you typed for each card, so the field isn't reformatted while you edit.mcp-client.ts: adds the last lines of the server's stderr to connect errors, e.g.Connection closed (server stderr: error: too many arguments...).Test
Desktop Chrome→ Save.--isolatedfrom Args → Save → Test.config.jsonkeeps"Desktop Chrome"as one argument, and Test passes.Configs that are already corrupted: pick the device again on the Config page and Save.
🤖 Generated with Claude Code