Before submitting
Area
apps/server
Steps to reproduce
- Add a Codex provider instance whose launch args add a stdio MCP server, e.g.
-c mcp_servers.extra.command="/path/to/server" (plus any args).
- Start a thread on that instance.
- Ask the agent to list its tools, or check which MCP servers Codex started.
Expected behavior
The thread gets T3's t3-code MCP server and the extra server from the instance's launch args, the same way a Claude instance with an extra --mcp-config gets both.
Actual behavior
Only t3-code is available. The extra server is never started.
codexThreadRuntimeParams (apps/server, Codex provider) sends:
config: {
...CODEX_THREAD_CONFIG, // { "tools.update_plan.enabled": true }
mcp_servers: { "t3-code": { url, http_headers } },
}
Codex applies per-thread overrides after the process's -c flags, in the same session-flags layer. A single-segment key (mcp_servers) replaces the whole table those -c mcp_servers.extra.* flags built. Servers in ~/.codex/config.toml survive, because that is a lower layer and layers are deep-merged. This happens on every thread/start, thread/resume and thread/fork, so no launch-arg quoting can work around it.
Suggested fix (not tested)
Use a dotted key, as CODEX_THREAD_CONFIG already does for tools.update_plan.enabled:
"mcp_servers.t3-code": { url, http_headers },
That should set only T3's entry and keep other servers.
Impact
A Codex provider instance can't add its own MCP server through launch args, though Claude instances can with --mcp-config. The remaining options are editing the global ~/.codex/config.toml (which affects every Codex use on the machine) or wrapping the Codex binary to re-add the server.
Version or commit
T3 Code 0.0.46-nightly.20261003.2638 (Linux AppImage)
Environment
Fedora Linux, codex-cli 0.160.0, provider instance with custom launch args.
Workaround
A wrapper executable as the instance's binaryPath that re-adds the server, or a global ~/.codex/config.toml entry.
Before submitting
Area
apps/server
Steps to reproduce
-c mcp_servers.extra.command="/path/to/server"(plus anyargs).Expected behavior
The thread gets T3's
t3-codeMCP server and theextraserver from the instance's launch args, the same way a Claude instance with an extra--mcp-configgets both.Actual behavior
Only
t3-codeis available. Theextraserver is never started.codexThreadRuntimeParams(apps/server, Codex provider) sends:Codex applies per-thread overrides after the process's
-cflags, in the same session-flags layer. A single-segment key (mcp_servers) replaces the whole table those-c mcp_servers.extra.*flags built. Servers in~/.codex/config.tomlsurvive, because that is a lower layer and layers are deep-merged. This happens on everythread/start,thread/resumeandthread/fork, so no launch-arg quoting can work around it.Suggested fix (not tested)
Use a dotted key, as
CODEX_THREAD_CONFIGalready does fortools.update_plan.enabled:That should set only T3's entry and keep other servers.
Impact
A Codex provider instance can't add its own MCP server through launch args, though Claude instances can with
--mcp-config. The remaining options are editing the global~/.codex/config.toml(which affects every Codex use on the machine) or wrapping the Codex binary to re-add the server.Version or commit
T3 Code 0.0.46-nightly.20261003.2638 (Linux AppImage)
Environment
Fedora Linux, codex-cli 0.160.0, provider instance with custom launch args.
Workaround
A wrapper executable as the instance's
binaryPaththat re-adds the server, or a global~/.codex/config.tomlentry.