"""make secrets values optional [1ac1b9c04da1].

Revision ID: 1ac1b9c04da1
Revises: 0.54.0
Create Date: 2023-12-22 23:06:32.466128

"""

import sqlalchemy as sa
from alembic import op

# revision identifiers, used by Alembic.
revision = "1ac1b9c04da1"
down_revision = "0.54.0"
branch_labels = None
depends_on = None


def upgrade() -> None:
    """Upgrade database schema and/or data, creating a new revision."""
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table("secret", schema=None) as batch_op:
        batch_op.alter_column("values", existing_type=sa.TEXT(), nullable=True)

    # ### end Alembic commands ###


def downgrade() -> None:
    """Downgrade database schema and/or data back to the previous revision."""
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table("secret", schema=None) as batch_op:
        batch_op.alter_column(
            "values", existing_type=sa.TEXT(), nullable=False
        )

    # ### end Alembic commands ###
