"""license-copied fields in LicensePeriod should be Nullable

Revision ID: 4eae969dcac2
Revises: c08c3e7c3b1a
Create Date: 2025-05-18 20:13:11.555330

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '4eae969dcac2'
down_revision = 'c08c3e7c3b1a'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('license_period', schema=None) as batch_op:
        batch_op.alter_column('currency',
               existing_type=sa.VARCHAR(length=20),
               nullable=True)
        batch_op.alter_column('basic_fee',
               existing_type=sa.DOUBLE_PRECISION(precision=53),
               nullable=True)
        batch_op.alter_column('max_storage_mb',
               existing_type=sa.INTEGER(),
               nullable=True)
        batch_op.alter_column('additional_storage_price',
               existing_type=sa.DOUBLE_PRECISION(precision=53),
               nullable=True)
        batch_op.alter_column('additional_storage_bucket',
               existing_type=sa.INTEGER(),
               nullable=True)
        batch_op.alter_column('included_embedding_mb',
               existing_type=sa.INTEGER(),
               nullable=True)
        batch_op.alter_column('additional_embedding_price',
               existing_type=sa.NUMERIC(precision=10, scale=4),
               nullable=True)
        batch_op.alter_column('additional_embedding_bucket',
               existing_type=sa.INTEGER(),
               nullable=True)
        batch_op.alter_column('included_interaction_tokens',
               existing_type=sa.INTEGER(),
               nullable=True)
        batch_op.alter_column('additional_interaction_token_price',
               existing_type=sa.NUMERIC(precision=10, scale=4),
               nullable=True)
        batch_op.alter_column('additional_interaction_bucket',
               existing_type=sa.INTEGER(),
               nullable=True)
        batch_op.alter_column('additional_storage_allowed',
               existing_type=sa.BOOLEAN(),
               nullable=True)
        batch_op.alter_column('additional_embedding_allowed',
               existing_type=sa.BOOLEAN(),
               nullable=True)
        batch_op.alter_column('additional_interaction_allowed',
               existing_type=sa.BOOLEAN(),
               nullable=True)

    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    pass
    # ### end Alembic commands ###
