Skip to content

Commit

Permalink
Remove project table
Browse files Browse the repository at this point in the history
  • Loading branch information
berrydenhartog committed Nov 15, 2024
1 parent 116ef9e commit 83511cb
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 99 deletions.
40 changes: 40 additions & 0 deletions amt/migrations/versions/f6da4d6dd867_remove_project_table.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
"""remove project table
Revision ID: f6da4d6dd867
Revises: ff46b7ecc348
Create Date: 2024-11-15 11:30:25.352543
"""

from collections.abc import Sequence

import sqlalchemy as sa
from alembic import op
from sqlalchemy.dialects import sqlite

# revision identifiers, used by Alembic.
revision: str = "f6da4d6dd867"
down_revision: str | None = "ff46b7ecc348"
branch_labels: str | Sequence[str] | None = None
depends_on: str | Sequence[str] | None = None


def upgrade() -> None:
# ### commands auto generated by Alembic - please adjust! ###
op.drop_table("project")
# ### end Alembic commands ###


def downgrade() -> None:
# ### commands auto generated by Alembic - please adjust! ###
op.create_table(
"project",
sa.Column("id", sa.INTEGER(), nullable=False),
sa.Column("name", sa.VARCHAR(length=255), nullable=False),
sa.Column("lifecycle", sa.VARCHAR(length=32), nullable=True),
sa.Column("last_edited", sa.DATETIME(), server_default=sa.text("(CURRENT_TIMESTAMP)"), nullable=False),
sa.Column("system_card_json", sqlite.JSON(), nullable=True),
sa.Column("deleted_at", sa.DATETIME(), nullable=True),
sa.PrimaryKeyConstraint("id", name="pk_project"),
)
# ### end Alembic commands ###
3 changes: 1 addition & 2 deletions amt/models/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from .algorithm import Algorithm
from .project import Project
from .task import Task
from .user import User

__all__ = ["Task", "User", "Algorithm", "Project"]
__all__ = ["Task", "User", "Algorithm"]
97 changes: 0 additions & 97 deletions amt/models/project.py

This file was deleted.

0 comments on commit 83511cb

Please sign in to comment.