mirror of
https://github.com/openai/codex.git
synced 2026-09-13 11:47:17 +00:00
## Why A failed rollout append can leave a rejected line before a valid same-ordinal retry. Advancing the byte checkpoint past that line without also advancing the ordinal checkpoint can prevent subsequent history from being projected. ## What changed - Defer rejected and unknown rollout lines until a later valid ordinal shows whether they were replaced by a retry or consumed an ordinal. - Advance skipped ordinal ranges together with the durable byte checkpoint, while rejecting gaps that cannot be explained by rejected lines. - Prefer item event timestamps and parse the rollout timestamp only when an item needs it as a fallback. ## Testing Added coverage for same-ordinal retries, inferred ordinal gaps, unknown and malformed records, invalid fallback timestamps, and unexplained gaps. GitOrigin-RevId: 374beda316c605d562bd9526abed19916598d69f