Repository navigation
fix(mcp): ignore bare sanitized OpenCode server prefixes - #3727
Merged
dyoshikawa merged 2 commits intoNov 3, 2026
Merged
Conversation
521Peter
marked this pull request as ready for review
November 1, 2026 18:06
Closed
4 tasks
…ith dyoshikawa#3723 Keep both new test blocks in opencode-mcp.test.ts. In opencode-mcp.ts, merge the two comments above the orphan pre-filter: dyoshikawa#3723 called the raw second pass redundant, which no longer holds once bare sanitized prefixes are dropped here, so the comment now says what each pass catches. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0179ZomNiDQHCzgoxeRVmfth
Owner
This was referenced Nov 3, 2026
Merged
Contributor
Author
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.
Addresses the bare sanitized-prefix import bug in #3725 (item 2).
With server
a.bandtools: { a_b_: false }, import currently creates a transport-less serverawithdisabledTools: ["b_"]. The owner lookup requires a nonempty tool suffix, and the orphan fallback only recognizes raw server prefixes.Exclude an exact sanitized server prefix before the orphan fallback. Valid tool filters and filters for genuinely unlisted servers still import normally. This is independent of #3723; the other comment/docs follow-ups in #3725 remain open.
The regression matrix covers OpenCode, OpenCode V1 and MiMo Code, project/global scope, raw/sanitized server names, and the flat/V2 server envelope where supported. It checks the complete imported object, including preservation of valid allows, denies and orphan filters.
Validation:
VITEST_MAX_WORKERS=2 pnpm cicheck: formatting, lint, type checking, all 605 test files (16,398 passed, 4 skipped), generated content, spelling and secret checks passed.pnpm build: passed; existing unrelated ineffective dynamic import warning.Earlier runs hit unrelated cleanup/test timeouts and worker startup timeouts. The complete check passed with two workers while keeping the machine awake; no test timeouts or repository configuration were changed.
Implemented with assistance from OpenAI Codex. I reviewed the diff and verified the failing baseline and checks locally.