mirror of
https://github.com/openai/codex.git
synced 2026-11-20 22:40:37 +00:00
Release persisted MCP tool results from active-turn memory (#62641)
## Why Active turns in paginated threads retain completed MCP tool results in memory even when history can supply the same payloads. History can also store a truncated preview, so dropping a result requires checking that the full payload is recoverable. ## What changed For persisted paginated threads, check successful MCP calls in batches and release an active-turn result only when the stored result matches it exactly. When resuming with full history, fetch released results by item ID so a stale history page cannot supply an older result. ## Testing Add a regression test that restores the latest result despite a stale page and checks that truncated, metadata-mismatched, missing, and failed results remain in memory. GitOrigin-RevId: 49f6f1414201e4327433043050d65a1f4adc9720
This commit is contained in:
@@ -580,6 +580,7 @@ impl MessageProcessor {
|
||||
);
|
||||
let turn_processor = TurnRequestProcessor::new(
|
||||
Arc::clone(&thread_manager),
|
||||
Arc::clone(&thread_store),
|
||||
outgoing.clone(),
|
||||
analytics_events_client.clone(),
|
||||
Arc::clone(&config),
|
||||
|
||||
Reference in New Issue
Block a user