Skip to content

fix(codex): stabilize awsknowledge MCP startup with codex-specific compatibility transport#139

Open
faishal882 wants to merge 1 commit intoawslabs:mainfrom
faishal882:fix/codex-awsknowledge-compat-layer
Open

fix(codex): stabilize awsknowledge MCP startup with codex-specific compatibility transport#139
faishal882 wants to merge 1 commit intoawslabs:mainfrom
faishal882:fix/codex-awsknowledge-compat-layer

Conversation

@faishal882
Copy link
Copy Markdown

Summary

This PR fixes Codex startup failures for awsknowledge MCP by introducing a Codex-specific compatibility transport path.

Issue: #130

Problem

Users running Codex could hit MCP startup failure for awsknowledge with:

Transport channel closed, when send initialized notification

Observed behavior from reproduction:

  • POST JSON-RPC initialize to https://knowledge-mcp.global.api.aws returns valid MCP init response.
  • GET/stream path behavior can redirect/close, which can break Codex streamable-http startup flow.

This caused handshake failure during the initialized notification phase.

What changed

1) Added Codex-specific MCP configs in affected plugins

New files:

  • plugins/deploy-on-aws/.mcp.codex.json
  • plugins/migration-to-aws/.mcp.codex.json
  • plugins/databases-on-aws/.mcp.codex.json

In these Codex-specific files, awsknowledge uses a local stdio proxy transport:

{
  "type": "stdio",
  "command": "uvx",
  "args": ["fastmcp", "run", "https://knowledge-mcp.global.api.aws"],
  "env": { "FASTMCP_LOG_LEVEL": "ERROR" },
  "timeout": 120000
}

2) Pointed Codex manifests to Codex-specific MCP configs

Updated:

  • plugins/deploy-on-aws/.codex-plugin/plugin.json
  • plugins/migration-to-aws/.codex-plugin/plugin.json
  • plugins/databases-on-aws/.codex-plugin/plugin.json

Change:

  • from "mcpServers": "./.mcp.json"
  • to "mcpServers": "./.mcp.codex.json"

3) Added Codex troubleshooting and rollback guidance

Updated:

  • docs/TROUBLESHOOTING.md

Added:

Why this approach

  • Limits risk: scoped to Codex only; non-Codex behavior remains unchanged.
  • Deterministic startup path: avoids direct streamable-http fragility for this endpoint in Codex.
  • Provides operator escape hatch: direct HTTP override path is documented.

Validation

Ran full project build requirements via mise run build:

  • markdown lint
  • manifest/schema validation
  • cross-reference validation
  • formatting check
  • reference/size validation
  • security scans (bandit, semgrep, gitleaks, checkov, grype)

All checks passed.

Notes

  • This PR intentionally does not include unrelated untracked planning docs from local workspace.
  • No changes were made to Claude plugin manifests or shared .mcp.json files.

@faishal882 faishal882 requested review from a team as code owners April 17, 2026 17:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant