fix: force local dolt sql helper to use TCP client mode#3470
fix: force local dolt sql helper to use TCP client mode#3470Bella-Giraffety wants to merge 1 commit intogastownhall:mainfrom
Conversation
Code ReviewSummaryThe core fix in Blocking Issues1. Unrelated files committedFiles: These are not mentioned in the PR description and appear to be development environment artifacts:
Please remove these from this PR or split them into a separate commit with explanation. 2. Mirror function in
|
|
Thanks — that review is right. I rebuilt this PR on a clean upstream main base and force-pushed it so it now contains only the intended doltserver helper change and its focused tests. I did not fold in daemon parity here because that would broaden the PR beyond the verified bug scope; I’m treating that as a separate follow-up if still needed after this narrower fix is reviewed. |
8312694 to
2c72f51
Compare
|
Follow-up note: the daemon mirror-helper gap raised in review is now addressed separately in #3482, so this PR can stay scoped to the shared internal/doltserver helper only. |
Problem
buildDoltSQLCmd() used bare dolt sql for local servers, which lets the CLI fall back to embedded-mode or autodiscovery behavior based on the working directory instead of querying the live shared Dolt server.
That can make local verification and status paths read the wrong database context, and it can also trigger interactive credential prompts in non-interactive health checks.
Fix
Always build the helper as an explicit TCP client command using host, port, user, no-tls, and the sql subcommand.
Also always set DOLT_CLI_PASSWORD, including the empty-string case, so these helper calls stay non-interactive.
This keeps the change narrowly scoped to the shared helper in internal/doltserver and does not change doctor semantics, daemon parity helpers, or IsRunning behavior.
Testing
Notes
This PR is intentionally limited to the helper and its focused tests. It does not attempt to clean up other Dolt shellout call sites or broaden local-server detection behavior.