forked from openai/codex
-
Notifications
You must be signed in to change notification settings - Fork 0
Serialize the complete SQLite initialization sequence #101
Copy link
Copy link
Closed
Labels
bugSomething isn't workingSomething isn't workinglocal-ticket/enhancementAdds or improves behavior in the local Codex forkAdds or improves behavior in the local Codex forklocal-ticket/stateChanges local SQLite state or log persistence behaviorChanges local SQLite state or log persistence behavior
Milestone
Description
Activity
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinglocal-ticket/enhancementAdds or improves behavior in the local Codex forkAdds or improves behavior in the local Codex forklocal-ticket/stateChanges local SQLite state or log persistence behaviorChanges local SQLite state or log persistence behavior
Outcome
Serialize the complete database open, WAL-repair, and migration sequence across competing Codex processes while preserving current recovery and connection reuse.
Governing evidence
Closed issue #23 and commits
390e0706d0,a7569600dd, and0e4f62e125; upstream centralizes connections and migration locking but not the complete sequence.The issue and this evidence define required behavior. Port functional intent onto the current upstream architecture; patch identity is irrelevant.
Non-goals
Do not add a second database, disable WAL, or broaden the lock beyond initialization.
Acceptance criteria and verification
Multi-process integration tests demonstrate concurrent clean startup, WAL recovery, migration failure and retry, lock release on error/cancellation, and no corruption or deadlock. Run the smallest focused
just test -p <crate>checks that cover the changed crates under the repository reduced-priority wrapper. Regenerate schemas or snapshots only when this ticket changes them. For a large Rust change run scopedjust fix -p <crate>, thenjust fmt; do not rerun tests after fix/format. Remove disposable build artifacts afterward.Likely areas
State connection initialization, migration/WAL recovery, and process-concurrency tests.
Dependencies
Fully blocked by #81.
Do not begin ticket-owned mutation until every dependency is integrated; their landed contracts are authoritative.
Blocks #102, #104.
Delivery
The accepted result must integrate as exactly one issue-linked commit with subject
fix(state): serialize SQLite initialization. Tests, snapshots, generated files, and fixes belong in that commit; adaptation or test-only follow-up commits are not permitted.Agent routing
agent_level: 5Agent signature
gpt-5.6-sol@high:01a07441-98af-75c1-9950-8af46deb76de