chore: print generated/executed SQL

for debugging purposes
This commit is contained in:
surtur 2020-08-07 01:51:06 +02:00
parent e31994efd6
commit 35dbbffd49
Signed by: wanderer
GPG Key ID: 19CE1EC1D9E0486D

@ -5,7 +5,7 @@ from sqlalchemy.orm import sessionmaker
SQLALCHEMY_DATABASE_URL = "sqlite:///./sql_app.db"
engine = create_engine(
SQLALCHEMY_DATABASE_URL, connect_args={"check_same_thread": False}
SQLALCHEMY_DATABASE_URL, connect_args={"check_same_thread": False}, echo=True
)
SessionLocal = sessionmaker(autocommit=False, autoflush=False, bind=engine)