Failed to load sqlite-vec extension #9457

Open
opened 2026-02-16 18:12:29 -05:00 by yindo · 1 comment
Owner

Originally created by @uuc110 on GitHub (Feb 16, 2026).

Originally assigned to: @rekram1-node on GitHub.

Description

upgraded brew version to 1.2.0 from 1.64.0 and on running opencode it first migrated my whole data and then failed to start.

To check if it work with latest version I uninstalled brew version and got NPM one to get the latest release version. and still facing the issue.

Plugins

"@franlol/opencode-md-table-formatter@0.0.3", "opencode-antigravity-auth@1.5.1", "opencode-gemini-auth@latest", "opencode-websearch-cited@1.2.0", "opencode-beads", "opencode-mem", "oh-my-opencode"

OpenCode version

1.2.5

Steps to reproduce

  1. Upgrade to >=1.2.0 from any lower version
  2. Let the opencode migrate your chats to sqlite db
  3. run opencode and screen went black to start the opencode session
  4. fail and this error shows

{ "name": "UnknownError", "data": { "message": "Error: Failed to load sqlite-vec extension: Error: This build of sqlite3 does not support dynamic extension loading\n\nThis usually means SQLite extension loading is disabled.\nOn macOS, you must use Homebrew SQLite instead of Apple's SQLite.\n\nSolution:\n1. Install: brew install sqlite\n2. Configure customSqlitePath in ~/.config/opencode/opencode-mem.jsonc\n at initDatabase (/Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/connection-manager.js:90:23)\n at getConnection (/Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/connection-manager.js:127:14)\n at new ShardManager (/Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/shard-manager.js:12:45)\n at /Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/shard-manager.js:232:29\n at moduleEvaluation (native:1:11)\n at moduleEvaluation (native:1:11)\n at moduleEvaluation (native:1:11)\n at requestImportModule (native:2)\n at processTicksAndRejections (native:7:39)" } }

Screenshot and/or share link

Image

Operating System

macOS 26.2 (25C56)

Terminal

Ghostty

Originally created by @uuc110 on GitHub (Feb 16, 2026). Originally assigned to: @rekram1-node on GitHub. ### Description upgraded brew version to 1.2.0 from 1.64.0 and on running opencode it first migrated my whole data and then failed to start. To check if it work with latest version I uninstalled brew version and got NPM one to get the latest release version. and still facing the issue. ### Plugins "@franlol/opencode-md-table-formatter@0.0.3", "opencode-antigravity-auth@1.5.1", "opencode-gemini-auth@latest", "opencode-websearch-cited@1.2.0", "opencode-beads", "opencode-mem", "oh-my-opencode" ### OpenCode version 1.2.5 ### Steps to reproduce 1. Upgrade to >=1.2.0 from any lower version 2. Let the opencode migrate your chats to sqlite db 3. run `opencode` and screen went black to start the opencode session 4. fail and this error shows ` { "name": "UnknownError", "data": { "message": "Error: Failed to load sqlite-vec extension: Error: This build of sqlite3 does not support dynamic extension loading\n\nThis usually means SQLite extension loading is disabled.\nOn macOS, you must use Homebrew SQLite instead of Apple's SQLite.\n\nSolution:\n1. Install: brew install sqlite\n2. Configure customSqlitePath in ~/.config/opencode/opencode-mem.jsonc\n at initDatabase (/Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/connection-manager.js:90:23)\n at getConnection (/Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/connection-manager.js:127:14)\n at new ShardManager (/Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/shard-manager.js:12:45)\n at /Users/MY_USERNAME/.cache/opencode/node_modules/opencode-mem/dist/services/sqlite/shard-manager.js:232:29\n at moduleEvaluation (native:1:11)\n at moduleEvaluation (native:1:11)\n at moduleEvaluation (native:1:11)\n at requestImportModule (native:2)\n at processTicksAndRejections (native:7:39)" } } ` ### Screenshot and/or share link <img width="1179" height="180" alt="Image" src="https://github.com/user-attachments/assets/27724593-95ba-492e-87ea-c6fc7ccff594" /> ### Operating System macOS 26.2 (25C56) ### Terminal Ghostty
yindo added the bug label 2026-02-16 18:12:29 -05:00
Author
Owner

@biondogs commented on GitHub (Feb 16, 2026):

This error is related to the opencode-mem plugin.

In the short term you can disable that plugin to get opencode working.

For more context it looks like SQLite is being invoked before the customsqlitepath variable has a chance to tell opencode to use the brew version of sqllite.

It does definitely still work pre 1.2.0. and if opencode-mem is disabled, looks like the statically linked version of sqllite that ships with opencode doesn't support dynamic extensions.

@biondogs commented on GitHub (Feb 16, 2026): This error is related to the opencode-mem plugin. In the short term you can disable that plugin to get opencode working. For more context it looks like SQLite is being invoked before the customsqlitepath variable has a chance to tell opencode to use the brew version of sqllite. It does definitely still work pre 1.2.0. and if opencode-mem is disabled, looks like the statically linked version of sqllite that ships with opencode doesn't support dynamic extensions.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9457