Repository navigation
fix(core): tolerate missing workspace names - #41610
opencode-agent[bot] wants to merge 1 commit into
Conversation
1c33a82 to
db86d03
Compare
|
Additional Windows reproduction evidence: OpenCode Desktop 1.18.18 logged a fatal renderer error, no such column: name, immediately after its sidecar exited with code 1 during startup. The ADR Kit native plugin was not involved: the crash was logged on 2026-08-13, before the native plugin session began on 2026-08-14. A subsequent CLI startup completed at 2026-08-13T21:57:44Z and left a healthy migrated database. This confirms the desktop-upgrade failure mode addressed here. PR #37707 appears to cover the separate legacy Drizzle-journal path that can produce the same SQLite error. |
|
Automated PR Cleanup Thank you for contributing to opencode. Due to the high volume of PRs from users and AI agents, we periodically close older PRs using automated criteria so maintainers can focus review time on the most active and community-supported contributions. This PR was closed because it matched the following cleanup criteria:
PRs created within the last month are not affected by this cleanup. If you believe this PR was closed incorrectly, or if you are still actively working on it, please leave a comment explaining why it should be reopened. A maintainer can review and reopen it if appropriate. Thanks again for taking the time to contribute. |
Summary
workspacetable has thenamecolumn before rebuilding itno such column: namefailureWhy
Some drifted legacy databases contain the newer workspace fields but lack
workspace.name. Migration20260410174513_workspace-nameunconditionally selected that column while rebuilding the table, so affected Desktop upgrades failed during local server startup.The migration now keeps its existing rebuild behavior and changes only the copied name expression. Existing names are preserved; databases without the column receive the target schema's empty default value.
Closes #32430
Testing
bun test test/database-migration.test.ts(17 passed)bun typecheckbun x prettier --check src/database/migration/20260410174513_workspace-name.ts test/database-migration.test.tsgit diff --checkRequested by: @neriousy (Filip via Slack)