Describe the bug
When attempting to launch the rebuilt Codex app on an Intel Mac, the application fails to start and displays a critical database access error popup.
Error Message
The popup displays the following:
Codex cannot access its local database.
The app cannot finish launching until its SQLite database is accessible.
Database path: /Users/lee/.codex/sqlite/codex-dev.db
...
Error: better-sqlite3 is only bundled with the Electron app
Steps to reproduce
- Run the rebuilt Codex.app on an Intel-based Mac.
- The UI initializes, but immediately throws the database error popup blocking further usage.
Environment
- Device: 16-inch MacBook Pro (2019) - Intel (x86_64)
- OS: macOS
Objective Analysis / Possible Root Cause
Based on the error better-sqlite3 is only bundled with the Electron app, it appears that the rebuild_codex.js script successfully modifies the main application but fails to recompile or swap out the native Node modules (specifically the better-sqlite3 binary) for the x86_64 architecture. The app seems to be trying to load an incompatible database driver.
Describe the bug
When attempting to launch the rebuilt Codex app on an Intel Mac, the application fails to start and displays a critical database access error popup.
Error Message
The popup displays the following:
Steps to reproduce
Environment
Objective Analysis / Possible Root Cause
Based on the error
better-sqlite3 is only bundled with the Electron app, it appears that therebuild_codex.jsscript successfully modifies the main application but fails to recompile or swap out the native Node modules (specifically thebetter-sqlite3binary) for thex86_64architecture. The app seems to be trying to load an incompatible database driver.