"""Fix ARTIST_SOCIAL enum value to uppercase to match SQLAlchemy name convention Revision ID: f6d9b3e18c42 Revises: e5c8f2a47d91 Create Date: 2026-06-03 12:01:00.000000 """ from alembic import op revision = 'f6d9b3e18c42' down_revision = 'e5c8f2a47d91' branch_labels = None depends_on = None def upgrade() -> None: # The existing lowercase 'artist_social' value was added inconsistently with the # rest of the enum (LOCAL_UPLOAD, GOOGLE_DRIVE_URL are uppercase). # SQLAlchemy serializes Python enum names (uppercase), so add the uppercase form. op.execute("ALTER TYPE projectsourcetype ADD VALUE IF NOT EXISTS 'ARTIST_SOCIAL'") def downgrade() -> None: # PostgreSQL does not support removing enum values — intentionally a no-op pass