"""create flask_articles section

Revision ID: 427d9b3f48f0
Revises: dd167341e9d8
Create Date: 2025-05-29 12:58:11.131497

"""
from alembic import op
import sqlalchemy as sa
from sqlalchemy.dialects import mysql

# revision identifiers, used by Alembic.
revision = '427d9b3f48f0'
down_revision = 'dd167341e9d8'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('scraped_article', schema=None) as batch_op:
        batch_op.alter_column('section',
               existing_type=mysql.VARCHAR(length=255),
               type_=sa.String(length=50),
               existing_nullable=True)

    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('scraped_article', schema=None) as batch_op:
        batch_op.alter_column('section',
               existing_type=sa.String(length=50),
               type_=mysql.VARCHAR(length=255),
               existing_nullable=True)

    # ### end Alembic commands ###
