db creation fix
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
2025-09-06 09:09:07 +09:00
parent 405e663da4
commit c6104455d8
3 changed files with 6 additions and 2 deletions

View File

@@ -9,6 +9,10 @@ import os
# this is the Alembic Config object, which provides
# access to the values within the .ini file in use.
config = context.config
import os
db_url = os.getenv("DATABASE_URL", "sqlite+aiosqlite:///db/bot.db")
db_url_sync = db_url.replace("sqlite+aiosqlite", "sqlite") # Alembic нужен sync-драйвер
config.set_main_option("sqlalchemy.url", db_url_sync)
# Interpret the config file for Python logging.
# This line sets up loggers basically.