"""Add col saved_in_hdf5

Revision ID: 04ae19b32c08
Revises: 1318a586f31d
Create Date: 2021-08-01 14:18:43.052881+00:00

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
from sqlalchemy import text

revision = "04ae19b32c08"
down_revision = "1318a586f31d"
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column(
        "Results",
        sa.Column(
            "saved_in_hdf5",
            sa.Boolean(),
            nullable=False,
            default=False,
            server_default=text("False"),
        ),
    )
    op.add_column(
        "ExperimentMetadata",
        sa.Column(
            "saved_in_hdf5",
            sa.Boolean(),
            nullable=False,
            default=False,
            server_default=text("False"),
        ),
    )
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_column("Results", "saved_in_hdf5")
    op.drop_column("ExperimentMetadata", "saved_in_hdf5")
    # ### end Alembic commands ###
