From d37388423d323fc6025f7f1fb1ecc3226de50198 Mon Sep 17 00:00:00 2001 From: Agent Zero Date: Fri, 31 Jul 2026 18:51:15 +0200 Subject: [PATCH] =?UTF-8?q?gate2:=20fix=20ix=5Fcontacts=5Ftenant=5Fid=20co?= =?UTF-8?q?nflict=20=E2=80=94=20drop=20old=20index=20before=20recreate=20i?= =?UTF-8?q?n=200021?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- alembic/versions/0021_unified_contacts.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/alembic/versions/0021_unified_contacts.py b/alembic/versions/0021_unified_contacts.py index 5b520e8..d6b58d9 100644 --- a/alembic/versions/0021_unified_contacts.py +++ b/alembic/versions/0021_unified_contacts.py @@ -70,6 +70,8 @@ def upgrade() -> None: logger.info("Table %s does not exist — nothing to rename", tbl) # ── 2. Create new contacts table ────────────────────────────────── + # Drop indexes that were carried over from the renamed old tables + op.execute("DROP INDEX IF EXISTS ix_contacts_tenant_id") op.create_table( "contacts", sa.Column("id", UUID(as_uuid=True), primary_key=True, server_default=sa.text("gen_random_uuid()")),