Skip to content

Fix cliUrl to auto-correct useStdio for backend service scenarios#97

Merged
brunoborges merged 1 commit intomainfrom
fix/cliurl-auto-correct-usestdio
Feb 9, 2026
Merged

Fix cliUrl to auto-correct useStdio for backend service scenarios#97
brunoborges merged 1 commit intomainfrom
fix/cliurl-auto-correct-usestdio

Conversation

@brunoborges
Copy link
Member

Summary\n\nWhen cliUrl is set (connecting to an external CLI server), useStdio is now automatically set to false since TCP is inherently required.\n\nPreviously, users had to explicitly call setUseStdio(false) alongside setCliUrl(), which contradicted the setup.md documentation that shows:\n\njava\nvar options = new CopilotClientOptions()\n .setCliUrl(\"localhost:4321\");\n\n\n## Changes\n\n- CopilotClient: Auto-corrects useStdio to false when cliUrl is provided. Simplified mutual exclusion validation to only reject cliUrl + cliPath.\n- CliServerManager: Made connectToServer parameter-driven (routes by host/port availability) instead of flag-driven.\n- CopilotClientTest: Updated tests for new behavior, added testCliUrlAutoCorrectsUseStdio and testCliUrlOnlyConstruction.\n\n## Testing\n\nAll 14 CopilotClientTest tests pass. Full test suite passes (1 pre-existing unrelated E2E failure in SessionEventsE2ETest).

When cliUrl is set (connecting to an external CLI server), useStdio is now
automatically set to false since TCP is inherently required. Previously,
users had to explicitly call setUseStdio(false) alongside setCliUrl(),
which contradicted the setup.md documentation.

Also simplified CliServerManager.connectToServer to be parameter-driven
rather than flag-driven, and updated tests accordingly.
@brunoborges brunoborges merged commit 7951af7 into main Feb 9, 2026
3 checks passed
@brunoborges brunoborges deleted the fix/cliurl-auto-correct-usestdio branch February 16, 2026 15:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant