Skip to content

Surface MCP server startup errors when preparing cached tool calls - #60038

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/434074eb748165b2fe19de3a40046835f26992df
Nov 7, 2026
Merged

copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/434074eb748165b2fe19de3a40046835f26992df

Conversation

@copyberry

@copyberry copyberry Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Surface MCP server startup errors when preparing cached tool calls

Why

A cached MCP tool can remain advertised after its server fails to start. Calling it previously returned a generic unavailable-tool error, hiding the startup failure from the model.

What changed

Propagate preparation errors through MCP tool calls and recorded approval preparation, preserving the error chain and adding the server name to startup failures. Keep the unavailable-tool error for tools that are missing, filtered, or no longer visible to the model.

Testing

Update the executor capability downgrade test to require the credential resolution startup error in the model's tool output and assert that the host token is absent.

…60038)

## Why

A cached MCP tool can remain advertised after its server fails to start. Calling it previously returned a generic unavailable-tool error, hiding the startup failure from the model.

## What changed

Propagate preparation errors through MCP tool calls and recorded approval preparation, preserving the error chain and adding the server name to startup failures. Keep the unavailable-tool error for tools that are missing, filtered, or no longer visible to the model.

## Testing

Update the executor capability downgrade test to require the credential resolution startup error in the model's tool output and assert that the host token is absent.

GitOrigin-RevId: 434074eb748165b2fe19de3a40046835f26992df
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/434074eb748165b2fe19de3a40046835f26992df branch from c09525f to fb2b06a Compare November 7, 2026 02:28
@chatgpt-codex-connector

Copy link
Copy Markdown
Contributor
Codex Review Summary: 🔄 Running

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review 🔄 Running since 2026-11-07T02:28:33.523514Z c09525f PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@copyberry
copyberry Bot merged commit fb2b06a into main Nov 7, 2026
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/434074eb748165b2fe19de3a40046835f26992df branch November 7, 2026 02:28
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 7, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant