Persist paginated items in the local thread store (#32289)

## What changed

- Allow the local thread store to create paginated threads while keeping them unsupported through the app-server API.
- Filter live append items using the history mode recorded with the thread's live recorder, so paginated threads persist canonical `ItemCompleted` events instead of legacy history events.

## Testing

- Add a local-store test that creates a paginated thread and verifies that a paginated item is persisted while a legacy user-message event is omitted.

GitOrigin-RevId: 83d93660afd5f0217213d4f21b5bf2a97745ff19
This commit is contained in:
Owen Lin
2026-07-10 23:26:58 +00:00
committed by copyberry
parent 610f09abcf
commit bfe31598c7
4 changed files with 74 additions and 14 deletions
@@ -963,6 +963,12 @@ impl ThreadRequestProcessor {
thread_source,
environments,
} = params;
if matches!(
history_mode,
Some(codex_app_server_protocol::ThreadHistoryMode::Paginated)
) {
return Err(method_not_found("paginated_threads is not supported yet"));
}
if sandbox.is_some() && permissions.is_some() {
return Err(invalid_request(
"`permissions` cannot be combined with `sandbox`",