Files
codex/codex-rs
Charlie Marsh c08843a5bd Skip redundant history materialization on flush (#62085)
## Why

Flushing an already projected rollout still reads its metadata and opens its history for SQLite materialization, even when no durable bytes remain to project.

## What changed

For paginated thread history, compare the plain rollout file length with the saved projection offset on flush and return early when a nonzero offset matches. Use only plain file lengths because compressed sizes are not decoded JSONL byte offsets. Continue materializing any durable suffix when the projection is behind.

## Testing

Extend the flush regression test to verify that an up-to-date projection preserves existing rows and that flush catches up with durable suffixes in both plain and compressed rollouts.

GitOrigin-RevId: 7078fe77e2b43beed7ceee024f309501da3a1d2b
2026-11-17 17:29:51 +00:00
..
…
…
…
…