mirror of
https://github.com/openai/codex.git
synced 2026-11-25 23:30:49 +00:00
Drop descendant channel posts from retained remote compaction v2 history (#47249)
## Why Remote compaction v2 excluded descendant progress messages from retained history but kept `CHANNEL_POST` messages from those same agents. ## What changed Treat descendant `CHANNEL_POST` messages like `MESSAGE` progress updates when selecting history to retain after remote compaction v2. ## Testing Extend the remote compaction test to verify that a child channel post is included in the compaction input and omitted from the follow-up request. GitOrigin-RevId: 204bf44b8cddf1e6dc1e48234f51d4ac2aaf2e9f
This commit is contained in:
@@ -572,6 +572,7 @@ fn is_retained_for_remote_compaction_v2(
|
||||
content.first(),
|
||||
Some(AgentMessageInputContent::InputText { text })
|
||||
if text.starts_with("Message Type: MESSAGE\n")
|
||||
|| text.starts_with("Message Type: CHANNEL_POST\n")
|
||||
);
|
||||
let is_completion = matches!(
|
||||
content.first(),
|
||||
|
||||
Reference in New Issue
Block a user