Commit Graph
1 Commits
Author SHA1 Message Date
g-butandClaude Opus 4.7 a3e085f6fa fix(db): persist user_projects.org_id migration (control panel was empty)
Same schema-drift pattern as 0005/0006: Drizzle schema declared user_projects.org_id
(uuid → orgs.id, on delete set null) but no migration shipped it. Every SELECT
through Drizzle requested the column, so the query crashed on production,
ensureUserProjectEntityLinks landed in its .catch returning [], and /api/control
reported trackedProjectCount=0 despite 20 active user_projects rows for the
logged-in user. With the column in place, /api/control now returns all 20
project cards — the autonomous loop (outcome streak, sleep mode, dispatch
reasoner, beacon countdown) finally has a surface to render against.

Applied to the live Neon DB; verified via the production /api/control endpoint
returning 20 projects with full dirPath linkage.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 21:45:41 +02:00