Skip to content

fix(dsh): diagnose native MCP tool catalog - #1876

Merged
Teingi merged 1 commit into
oceanbase:masterfrom
DongYao0:codex/fix-1785-mcp-catalog-diagnosis
Oct 8, 2026
Merged

Teingi merged 1 commit into
oceanbase:masterfrom
DongYao0:codex/fix-1785-mcp-catalog-diagnosis

Conversation

@DongYao0

@DongYao0 DongYao0 commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Which issue or RFC does this PR close?

Addresses the MCP catalog diagnosis portion of #1785.

Rationale for this change

The documented DSH plugin uses HTTP and exposes pc_* tools, while native DSH MCP is optional. /pc doctor could verify HTTP/plugin health but could not distinguish an absent native PowerContext MCP catalog from a healthy HTTP setup.

What changes are included in this PR?

  • Inspect the active DSH tools.schemas(agent) catalog only when /pc doctor runs.
  • Report visible mcp__powercontext__* tools.
  • Report a separate recovery action when other MCP tools are present but PowerContext is missing.
  • Keep unavailable or unconfigured native MCP as a non-blocking result for the documented HTTP-only DSH plugin.
  • Add regression coverage for visible, absent, missing, and unreadable catalog states.
  • Document the optional native-MCP diagnostic in the plugin README and English/Chinese DSH guides.

Are there any user-facing changes?

Yes. /pc doctor includes checks.mcp_catalog with explicit native MCP visibility status and recovery guidance. It does not change HTTP plugin health semantics or public HTTP APIs.

How was this change tested?

  • pnpm test — 275 passed, 1 skipped.
  • pnpm build
  • pnpm test:e2e — 9 passed.
  • Website: pnpm lint, pnpm test, and pnpm build — 875 public pages and links verified.

The local Windows commit hook’s repository-wide ty check reports pre-existing POSIX-only Python attribute diagnostics in unrelated files; no Python source was changed. The DSH package build and all relevant tests above passed.

AI usage statement

Implemented and verified with OpenAI Codex. AI assistance was used for source tracing, implementation, regression-test design, documentation, and validation; the resulting changes were reviewed locally.

@Alanxtl

Alanxtl commented Oct 8, 2026

Copy link
Copy Markdown
Collaborator

@DongYao0 Thanks for your contribution, however, I'm refactoring the dsh plugin to MCP native in #1784, what about push forward this issue after #1784?

@DongYao0

DongYao0 commented Oct 8, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the heads-up. That makes sense.

Since #1784 is refactoring the DSH plugin to native MCP, I agree it is safer to move the MCP catalog diagnosis forward after that work lands, rather than merge a change against the current HTTP-plugin architecture.

I’ll keep this PR open as a reference for now and refresh or rework it on top of #1784 once the refactor is available. Please let me know if you would prefer that I close this PR and submit a new focused follow-up instead.

@Teingi
Teingi merged commit f28f8ed into oceanbase:master Oct 8, 2026
26 checks passed
@hidb4ai hidb4ai added the 1.3.0 label Oct 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants