Skip to content

Gate paginated thread history on the state database - #35787

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/2eaa0f5f0de8d5e4d84375ec50b310746a0ee68e
Jul 28, 2026
Merged

copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/2eaa0f5f0de8d5e4d84375ec50b310746a0ee68e

Conversation

@copyberry

@copyberry copyberry Bot commented Jul 28, 2026 •

Copy link
Copy Markdown

Gate paginated thread history on the state database

Why

Local thread stores without an initialized state database should not implicitly
create SQLite files or partially delete threads that have materialized history.

What changed

  • Report paginated history listing as unsupported when no state database is
    available, and skip history projection and materialization in that mode.
  • Reject paginated forks without a state database.
  • Validate access to materialized history before deleting rollout files, so a
    failed deletion preserves both the rollout and its history rows.

Testing

Added coverage that a store without a state database creates no SQLite files
and preserves materialized history when deletion is unsupported. Existing
projection tests now initialize the state runtime explicitly.

## Why

Local thread stores without an initialized state database should not implicitly
create SQLite files or partially delete threads that have materialized history.

## What changed

- Report paginated history listing as unsupported when no state database is
  available, and skip history projection and materialization in that mode.
- Reject paginated forks without a state database.
- Validate access to materialized history before deleting rollout files, so a
  failed deletion preserves both the rollout and its history rows.

## Testing

Added coverage that a store without a state database creates no SQLite files
and preserves materialized history when deletion is unsupported. Existing
projection tests now initialize the state runtime explicitly.

GitOrigin-RevId: 2eaa0f5f0de8d5e4d84375ec50b310746a0ee68e
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/2eaa0f5f0de8d5e4d84375ec50b310746a0ee68e branch from 704220a to fa1d4c4 Compare July 28, 2026 16:01
@copyberry
copyberry Bot merged commit fa1d4c4 into main Jul 28, 2026
14 of 32 checks passed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/2eaa0f5f0de8d5e4d84375ec50b310746a0ee68e branch July 28, 2026 16:03
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 28, 2026
@y4ho0
y4ho0 temporarily deployed to issue-triage July 28, 2026 16:08 — with GitHub Actions Inactive
@y4ho0
y4ho0 temporarily deployed to issue-triage July 28, 2026 16:08 — with GitHub Actions Inactive
@y4ho0
y4ho0 temporarily deployed to issue-triage July 28, 2026 16:08 — with GitHub Actions Inactive
@y4ho0
y4ho0 temporarily deployed to issue-triage July 28, 2026 16:09 — with GitHub Actions Inactive

This branch was previously deployed

1 inactive deployment
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.

7 participants