fix(plugin): give the Codex plugin server REA's 30-second startup timeout

The Codex manifest left startup_timeout_sec at the client default, unlike
the registration rea setup writes, so a cold npx start could be cut off
before tools appeared. Carry the owned timeout in the Codex server entry
and assert it against MCP_STARTUP_POLICY.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
GamerDubz 2026-10-12 05:50:28 +02:00
parent 2aea370e1c
commit d3359ebef0
2 changed files with 13 additions and 1 deletions

View File

@ -19,7 +19,8 @@
"mcpServers": {
"rea": {
"command": "npx",
"args": ["-y", "rea-agents@latest", "mcp"]
"args": ["-y", "rea-agents@latest", "mcp"],
"startup_timeout_sec": 30
}
},
"interface": {

View File

@ -3,6 +3,7 @@ import { readFile } from "node:fs/promises";
import { describe, expect, it } from "vitest";
import { SUPPORTED_NODE_VERSION_RANGE } from "../../src/domain/runtimeVersion.js";
import { MCP_STARTUP_POLICY } from "../../src/mcpStartupPolicy.js";
const readJson = async (path: string): Promise<unknown> =>
JSON.parse(await readFile(path, "utf8")) as unknown;
@ -122,6 +123,16 @@ describe("release configuration", () => {
);
});
it("carries the owned Codex startup timeout in the Codex plugin server entry", async () => {
expect(await readJson(".codex-plugin/plugin.json")).toMatchObject({
mcpServers: {
rea: {
startup_timeout_sec: MCP_STARTUP_POLICY.codexStartupTimeoutSeconds,
},
},
});
});
it("keeps the npm package and MCP Registry metadata aligned", async () => {
const packageJson = (await readJson("package.json")) as {
name: string;