chore(server): remove obsolete migration repair - #113
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f9e8d17254
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (!trial) { | ||
| yield* sql`PRAGMA journal_mode = WAL;`; | ||
| yield* repairMainMigrationLedger(); | ||
| yield* runMigrations(); |
There was a problem hiding this comment.
Preserve the ledger repair for dormant fork upgrades
Keep the repair for users upgrading directly from fork version 0.0.24, whose main ledger can end at migration 31 named ProjectionThreadGoals. The Effect migrator only runs IDs greater than the latest recorded ID, so this direct call skips the current migration 31 (AuthAuthorizationScopes) and proceeds with the old role-based auth tables intact; current pairing and session queries then access missing scopes columns and break authentication. A distributed fork cannot assume every dormant installation has already passed through an intermediate repairing release.
AGENTS.md reference: AGENTS.md:L13-L15
Useful? React with 👍 / 👎.
What Changed
Removed the startup repair that deleted the legacy
ProjectionThreadGoalsentry from the main database migration ledger.Why
All fork databases have completed the one-time migration. Rewriting the ledger on every startup is no longer needed, so startup can go straight to the standard migration runner.
Checklist
Model: gpt-5.6-sol
Harness: T3 Code