Skip to content

Extract reverse JSONL scanning from session indexing - #32246

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/66255f48492f74726d4ac4831cdc82f748de17d6
Jul 10, 2026
Merged

Extract reverse JSONL scanning from session indexing#32246
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/66255f48492f74726d4ac4831cdc82f748de17d6

Conversation

@copyberry

@copyberry copyberry Bot commented Jul 10, 2026

Copy link
Copy Markdown

Extract reverse JSONL scanning from session indexing

What changed

  • Add a generic ReverseJsonlScanner that reads seekable JSONL data from the
    end in bounded chunks, skips blank records, and reports malformed records
    without stopping the scan.
  • Use the scanner for reverse session-index lookups while preserving the
    existing behavior of ignoring invalid entries.

Testing

  • Add coverage for unterminated final records, malformed JSON, blank lines,
    chunk boundaries, and records spanning multiple chunks.
  • Verify session-index lookup can skip an invalid record and still find valid
    entries on either side of it.

## What changed

- Add a generic `ReverseJsonlScanner` that reads seekable JSONL data from the
  end in bounded chunks, skips blank records, and reports malformed records
  without stopping the scan.
- Use the scanner for reverse session-index lookups while preserving the
  existing behavior of ignoring invalid entries.

## Testing

- Add coverage for unterminated final records, malformed JSON, blank lines,
  chunk boundaries, and records spanning multiple chunks.
- Verify session-index lookup can skip an invalid record and still find valid
  entries on either side of it.

GitOrigin-RevId: 66255f48492f74726d4ac4831cdc82f748de17d6
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/66255f48492f74726d4ac4831cdc82f748de17d6 branch from c3c581a to a328f30 Compare July 10, 2026 19:19
@copyberry
copyberry Bot merged commit a328f30 into main Jul 10, 2026
14 of 32 checks passed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/66255f48492f74726d4ac4831cdc82f748de17d6 branch July 10, 2026 19:20
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 10, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants