mirror of
https://github.com/openai/codex.git
synced 2026-11-14 21:40:39 +00:00
Apply session app overrides during MCP config refresh (#60730)
## Why MCP config refreshes previously retained session app overrides, leaving connector approval changes unapplied in existing sessions. ## What changed - Refresh explicit session `apps` overrides alongside `plugins`, allowing updated link approval settings to take effect on the next turn. - Preserve overrides for omitted sections and restore inheritance when a section is an empty table. - Validate app overrides and the effective app configuration, rejecting refreshes that expose invalid inherited settings. ## Testing Add coverage for independent and combined app/plugin updates, clearing overrides, and rejecting invalid inherited app settings. Add an integration test verifying that changing a link's approval mode from `approve` to `prompt` requests approval before executing the next turn's tool call. GitOrigin-RevId: 3fa36744a9ccd9e735e4cda7f061ccff1cf2a269
This commit is contained in:
@@ -1319,9 +1319,8 @@ impl CodexThread {
|
||||
self.session.disable_mcp_enterprise_auth().await;
|
||||
}
|
||||
|
||||
/// Refresh MCP configuration, managed requirements, and explicit session plugin overrides.
|
||||
/// Omitted session plugins preserve current overrides; an empty map restores inheritance.
|
||||
/// Other session overrides and user settings remain unchanged.
|
||||
/// Refresh MCP configuration, managed requirements, and session plugin and app overrides.
|
||||
/// An omitted section preserves its current overrides. An empty map restores inheritance.
|
||||
/// A stale owner requires reloading from the current config before retrying.
|
||||
pub async fn refresh_mcp_config(
|
||||
&self,
|
||||
|
||||
Reference in New Issue
Block a user