"""require stage_number match_id uniqueness

Revision ID: bd2fc147be53
Revises: c27a53ccd1d3
Create Date: 2023-01-23 22:34:52.068605

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = "bd2fc147be53"
down_revision = "c27a53ccd1d3"
branch_labels = None
depends_on = None


def upgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_unique_constraint(
        "stage_score_stage_number_unique_per_match", "match_report_stage", ["match_id", "stage_number"]
    )
    # ### end Alembic commands ###


def downgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_constraint("stage_score_stage_number_unique_per_match", "match_report_stage", type_="unique")
    # ### end Alembic commands ###
