From cfac57a41bcf3adf8b3f60153d733583532d05ad Mon Sep 17 00:00:00 2001 From: Cameron Reeves Date: Thu, 6 Aug 2026 13:12:27 +1000 Subject: [PATCH] fix(migrations): renumber the AI-support migration above the release line MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `202607050000000_add_ai_support_agent_tables.sql` is 15 digits where every recent migration is 17, so its version_id is ~100x smaller than the migrations already applied everywhere: already applied on any 2.2607.3 database : 20,260,730,100,500,000 the AI-support migration : 202,607,050,000,000 micrate sorts by version_id, so this lands BEFORE migrations that are already applied and `verify_unordered_migrations` raises `Micrate::UnorderedMigrationsException` — at which point NOTHING further applies, including 20260730101000000_alter_user_logged_out_at_timestamptz. This is not hypothetical. It is already breaking the dev server: `init` is crash-looping on exactly this exception right now, and a scan of every migration against dev's applied set shows this file is the ONLY one out of order. Padding to 17 digits would not be enough — 2026-07-05 still predates the 2026-07-30 migrations already in the field — so it is renumbered to 20260806100500000, above everything currently released. Renaming is safe here: the migration has not been applied anywhere (no `micrate_db_version` row for it on dev), and every statement in it is `CREATE TABLE/INDEX IF NOT EXISTS` (12 tables, 52 indexes), so even a re-application would be a no-op. Nothing in the codebase references the filename. Content is untouched — this is a pure rename. Co-Authored-By: Claude Opus 5 (1M context) --- ...bles.sql => 20260806100500000_add_ai_support_agent_tables.sql} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename migration/db/migrations/{202607050000000_add_ai_support_agent_tables.sql => 20260806100500000_add_ai_support_agent_tables.sql} (100%) diff --git a/migration/db/migrations/202607050000000_add_ai_support_agent_tables.sql b/migration/db/migrations/20260806100500000_add_ai_support_agent_tables.sql similarity index 100% rename from migration/db/migrations/202607050000000_add_ai_support_agent_tables.sql rename to migration/db/migrations/20260806100500000_add_ai_support_agent_tables.sql