"""Add uniqueness constraints Revision ID: 8a37924fd1be Revises: 251a8108d7ff Create Date: 2025-05-15 09:52:01.887077 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = '8a37924fd1be' down_revision = '251a8108d7ff' branch_labels = None depends_on = None def upgrade(): # ### commands auto generated by Alembic - please adjust! ### with op.batch_alter_table('events', schema=None) as batch_op: batch_op.create_unique_constraint('uq_events_discord_message_id', ['discord_message_id']) # ### end Alembic commands ### def downgrade(): # ### commands auto generated by Alembic - please adjust! ### with op.batch_alter_table('events', schema=None) as batch_op: batch_op.drop_constraint('uq_events_discord_message_id', type_='unique') # ### end Alembic commands ###