看股功能更新
This commit is contained in:
@@ -15,7 +15,7 @@ from sqlalchemy import delete, select
|
||||
from app.auth import hash_password, token_digest
|
||||
from app.db import async_session, engine
|
||||
from app.main import app
|
||||
from app.models import AuthSession, MarketDaily, User
|
||||
from app.models import AuthSession, Candle, User
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
@@ -100,7 +100,7 @@ async def main() -> None:
|
||||
print("logout and revoke: ok")
|
||||
|
||||
async with async_session() as db:
|
||||
has_market_data = bool(await db.scalar(select(MarketDaily.id).limit(1)))
|
||||
has_market_data = bool(await db.scalar(select(Candle.id).limit(1)))
|
||||
print("market data present:", has_market_data)
|
||||
finally:
|
||||
async with async_session() as db:
|
||||
|
||||
Reference in New Issue
Block a user