"""add workflow_run_id & workflow_run_block_id to script_blocks table

Revision ID: 2903b6252f31
Revises: d135e472622c
Create Date: 2025-11-03 04:24:52.201400+00:00

"""

from typing import Sequence, Union

import sqlalchemy as sa

from alembic import op

# revision identifiers, used by Alembic.
revision: str = "2903b6252f31"
down_revision: Union[str, None] = "d135e472622c"
branch_labels: Union[str, Sequence[str], None] = None
depends_on: Union[str, Sequence[str], None] = None


def upgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column("script_blocks", sa.Column("workflow_run_id", sa.String(), nullable=True))
    op.add_column("script_blocks", sa.Column("workflow_run_block_id", sa.String(), nullable=True))
    # ### end Alembic commands ###


def downgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_column("script_blocks", "workflow_run_block_id")
    op.drop_column("script_blocks", "workflow_run_id")
    # ### end Alembic commands ###
