Local changes: Updated model training, removed debug instrumentation, and configuration improvements
This commit is contained in:
21
check_db.py
Normal file
21
check_db.py
Normal file
@@ -0,0 +1,21 @@
|
||||
import os
|
||||
import asyncio
|
||||
from src.core.database import get_database
|
||||
from sqlalchemy import text
|
||||
|
||||
async def check_db():
|
||||
try:
|
||||
db = get_database()
|
||||
session = db.get_session()
|
||||
async with session:
|
||||
result = await session.execute(text("SELECT id, symbol, side, order_type, quantity, status, created_at FROM orders ORDER BY id DESC LIMIT 20;"))
|
||||
rows = result.fetchall()
|
||||
for row in rows:
|
||||
print(row)
|
||||
except Exception as e:
|
||||
print(f"Error: {e}")
|
||||
finally:
|
||||
await db.close()
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(check_db())
|
||||
Reference in New Issue
Block a user