release: bump version to 0.39.0

This commit is contained in:
rayd1o
2026-04-24 00:48:33 +08:00
parent d5f3784ffb
commit 8b8f7138c0
22 changed files with 1490 additions and 762 deletions

View File

@@ -1,4 +1,3 @@
import logging
from typing import AsyncGenerator
from sqlalchemy import text
@@ -6,8 +5,9 @@ from sqlalchemy.ext.asyncio import AsyncSession, create_async_engine, async_sess
from sqlalchemy.orm import declarative_base
from app.core.config import settings
from app.core.logging import get_logger
logger = logging.getLogger(__name__)
logger = get_logger(__name__)
DB_POOL_CONFIG = {
"pool_pre_ping": True,
@@ -111,13 +111,16 @@ async def init_db():
import app.models.playground_message # noqa: F401
import app.models.system_log # noqa: F401
logger.warning(
"Database pool settings active: pre_ping=%s recycle=%ss size=%s overflow=%s timeout=%ss",
DB_POOL_CONFIG["pool_pre_ping"],
DB_POOL_CONFIG["pool_recycle"],
DB_POOL_CONFIG["pool_size"],
DB_POOL_CONFIG["max_overflow"],
DB_POOL_CONFIG["pool_timeout"],
logger.warning_event(
"Database pool settings active",
event="database.pool.initialized",
context={
"pool_pre_ping": DB_POOL_CONFIG["pool_pre_ping"],
"pool_recycle": DB_POOL_CONFIG["pool_recycle"],
"pool_size": DB_POOL_CONFIG["pool_size"],
"max_overflow": DB_POOL_CONFIG["max_overflow"],
"pool_timeout": DB_POOL_CONFIG["pool_timeout"],
},
)
async with engine.begin() as conn: