mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-06-08 15:17:14 +00:00
43 lines
1.3 KiB
Python
43 lines
1.3 KiB
Python
"""init
|
|
|
|
Revision ID: e9c714da8d57
|
|
Revises:
|
|
Create Date: 2025-05-30 20:14:33.772039
|
|
|
|
"""
|
|
from typing import Sequence, Union
|
|
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision: str = 'e9c714da8d57'
|
|
down_revision: Union[str, None] = None
|
|
branch_labels: Union[str, Sequence[str], None] = None
|
|
depends_on: Union[str, Sequence[str], None] = None
|
|
|
|
|
|
def upgrade() -> None:
|
|
"""Upgrade schema."""
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
op.create_table('model',
|
|
sa.Column('type', sa.Text(), nullable=False),
|
|
sa.Column('path', sa.Text(), nullable=False),
|
|
sa.Column('file_name', sa.Text(), nullable=True),
|
|
sa.Column('file_size', sa.Integer(), nullable=True),
|
|
sa.Column('hash', sa.Text(), nullable=True),
|
|
sa.Column('hash_algorithm', sa.Text(), nullable=True),
|
|
sa.Column('source_url', sa.Text(), nullable=True),
|
|
sa.Column('date_added', sa.DateTime(), server_default=sa.text('(CURRENT_TIMESTAMP)'), nullable=True),
|
|
sa.PrimaryKeyConstraint('type', 'path')
|
|
)
|
|
# ### end Alembic commands ###
|
|
|
|
|
|
def downgrade() -> None:
|
|
"""Downgrade schema."""
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
op.drop_table('model')
|
|
# ### end Alembic commands ###
|