Repository navigation
OpenCode fails to start: "no such column: project_id" - #519
Merged
balazsotakomaiya merged 2 commits intoNov 2, 2026
Merged
balazsotakomaiya merged 2 commits into
balazsotakomaiya merged 2 commits into
Conversation
…ad 2.x OpenCode 2's workspace_domain migration drops workspace.project_id, which OpenCode 1.x still updates on opening a repository, so it stops with 'no such column: project_id' (anomalyco/opencode#42170). The stuck card now says what's wrong and how to update to version 2, and Althar's own download of OpenCode takes the newest 2.x release rather than GitHub's latest, which is still 1.x. Co-authored-by: Althar <[email protected]>
1.x's upgrade and installer refuse a 2.x version, so the card points at OpenCode 2's docs, which give its installer for each platform. Co-authored-by: Althar <[email protected]>
balazsotakomaiya
deleted the
althar/opencode-fails-to-start-no-such-column-project-i
branch
November 2, 2026 19:44
ninemate
pushed a commit
to ninemate/althar
that referenced
this pull request
Nov 3, 2026
The conflict was a disagreement: AltharIDE#519 moved Althar's OpenCode download to 2.x and told people to install OpenCode 2, while this branch starts no session on 2.x. Run on 2.2.5, Althar's MCP switch-off still doesn't stop the person's servers starting and a rejected command still ends the turn, so the gate stays and the download stays on 1.x (`line` goes). For a data folder 2.x has migrated, the card now points at another account, a home of its own. The findings are in docs/plans/opencode-2.md. Co-authored-by: Althar <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
A review on OpenCode stopped with "OpenCode couldn't start. The agent stopped: no such column: project_id." The error is OpenCode's, from its own database. OpenCode 2's
workspace_domainmigration rebuilds theworkspacetable withoutproject_id. OpenCode 1.x still updates that column when it opens a repository, so a 1.x OpenCode on a data folder that 2.x (or its beta) has migrated fails on every start in a repository (anomalyco/opencode#42170). That is the case here: the data folder was migrated by the 2.x beta, and OpenCode was later put back on stable 1.18.31.What changed
line: 'v2.'). In that case Althar lists the repository's releases and takes the newest one on that line that is neither a draft nor a prerelease.How I went about it
GitHub's latest OpenCode release is still on the 1.x line (v1.19.5), which has the same bug. It also lacks
auth list --standalone --format json, which the adapter already uses for OpenCode 2. So a download of "latest" would have given a build that doesn't fit the adapter and can't open a migrated data folder. The card points at OpenCode 2's docs rather than naming a command: neitheropencode upgradenor 1.x's installer moves to 2 (the installer refuses a 2.x version), and 2's installer differs by platform. Nothing touches the person's database. Moving it aside would lose their history in OpenCode, and OpenCode 2 opens it as it is.How it was checked
opencode acpin a repository on a copy of the affected database. On an empty data folder it starts.auth list --standalone --format json; 1.18.31 exits 1 on it.Reviewed by Claude Sonnet 5.5 in 1 pass, at
7cccb03Built by Claude Opus 5.5 · Reviewed by Claude Sonnet 5.5
Opened by Althar.