fix: migration 0031 no-op — status column is TEXT not a PG enum

This commit is contained in:
2026-03-28 01:17:00 -04:00
parent ac90548823
commit 51d2fd9d0a
@@ -1,4 +1,8 @@
"""Add 'cancelled' value to task_status enum."""
"""Add 'cancelled' task status.
The status column is plain TEXT (not a PostgreSQL enum type), so no DDL
change is required — the application layer already accepts the new value.
"""
from alembic import op
@@ -9,10 +13,9 @@ depends_on = None
def upgrade() -> None:
op.execute("ALTER TYPE task_status ADD VALUE IF NOT EXISTS 'cancelled'")
# No-op: status is stored as TEXT; the new value is valid without DDL changes.
pass
def downgrade() -> None:
# PostgreSQL does not support removing enum values without a full type rebuild.
# Downgrade is a no-op; the value simply becomes unused.
pass