fix(app-server): expose remote MCP servers in plugin read (#26453)

## Why

Remote plugin detail responses include MCP server metadata under
`release.mcp_servers`, but Codex did not deserialize or propagate that
field. As a result, `plugin/read` always returned an empty `mcpServers`
list for remote plugins, so the plugin details pane omitted the MCP
Servers section even when the remote plugin declares one.

This affects uninstalled plugins as well: the remote detail API is the
source of truth and returns MCP server keys without requiring a local
plugin bundle.

## What changed

- Deserialize MCP server entries from remote plugin detail responses.
- Normalize their keys into a sorted, deduplicated list on
`RemotePluginDetail`.
- Return those keys from app-server `plugin/read` instead of hardcoding
an empty list.
- Add regression coverage proving an uninstalled remote plugin returns
its MCP server names.

## Test plan

- `just test -p codex-core-plugins`
- `just test -p codex-app-server plugin_read`
This commit is contained in:
Eric Ning
2026-06-04 22:10:24 +00:00
committed by GitHub
parent 59ca34206b
commit 769c231aa1
3 changed files with 44 additions and 11 deletions
@@ -2026,7 +2026,7 @@ fn remote_plugin_detail_to_info(
.collect(),
hooks: Vec::new(),
apps,
mcp_servers: Vec::new(),
mcp_servers: detail.mcp_servers,
}
}