MVP frontend+backend
This commit is contained in:
@@ -12,9 +12,10 @@ from typing import Any
|
||||
|
||||
from alembic import context
|
||||
|
||||
# Load the alembic.ini logging config.
|
||||
# Load the alembic.ini logging config without disabling existing loggers —
|
||||
# when running inside the FastAPI app the app's own loggers must not be reset.
|
||||
if context.config.config_file_name is not None:
|
||||
fileConfig(context.config.config_file_name)
|
||||
fileConfig(context.config.config_file_name, disable_existing_loggers=False)
|
||||
|
||||
|
||||
def run_migrations_offline() -> None:
|
||||
|
||||
@@ -149,8 +149,14 @@ DROP TABLE IF EXISTS workspace;
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
op.execute(_UPGRADE_SQL)
|
||||
from sqlalchemy import text
|
||||
|
||||
for stmt in [s.strip() for s in _UPGRADE_SQL.split(";") if s.strip()]:
|
||||
op.execute(text(stmt))
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
op.execute(_DOWNGRADE_SQL)
|
||||
from sqlalchemy import text
|
||||
|
||||
for stmt in [s.strip() for s in _DOWNGRADE_SQL.split(";") if s.strip()]:
|
||||
op.execute(text(stmt))
|
||||
|
||||
Reference in New Issue
Block a user