Repository navigation
feat(config): start a project's MCP and LSP servers only after it is trusted - #528
Merged
Merged
Conversation
…trusted A project config comes with the repository. Its [mcp_servers] and [lsp.servers] tables name programs to start, and they were merged and started before the user approved anything. They are now left out of the layered config until the user runs `whycodes trust` in the project. The trust is stored with the exact definitions, so a change asks again. WHYCODES_TRUST_PROJECT=1 trusts every project config (CI, containers). The TUI lists the servers that were left out in the chat; `whycodes serve` prints them to stderr. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Co-Authored-By: Claude Fable 5.2 <[email protected]>
This was referenced Dec 2, 2026
Merged
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.
A project's
.whycodes/config.tomlcomes with the repository. Its[mcp_servers]and[lsp.servers]tables name programs to start and endpoints to connect to, and they were merged into the config and started (TUI startup,whycodes serve) before the user approved anything. Opening a cloned repository was enough to run a program it chose.What changes
whycodes trustrecords the trust in<data_dir>/trusted-projects.jsontogether with the exact definitions (canonical JSON, sorted keys), so any change to them asks again.whycodes trust --revokeforgets it.WHYCODES_TRUST_PROJECT=1trusts every project config, for CI and containers.whycodes serveprints them to stderr; the log has a warning.Behaviour change
Anyone who already has MCP or LSP servers in a project config has to run
whycodes trustonce in that project after upgrading.Not in this PR
<project>/.whycodes/pluginsis still loaded without a gate.[lsp.servers]entry (for exampledisabled = truenow also needs trust).Verification
trustreport, notice, argument parsing) and tui (chat notice).whycodes-configmeasured locally: no missed lines.mainthere (lockfile,upgrade,run_shell, twoplain_replintegration tests, the clipboard image test).🤖 Generated with Claude Code