Taragolis commented on code in PR #34404:
URL: https://github.com/apache/airflow/pull/34404#discussion_r1327695754
##########
airflow/settings.py:
##########
@@ -237,9 +237,7 @@ def configure_orm(disable_connection_pool=False,
pool_class=None):
session = Session()
try:
result = session.execute(
- sqlalchemy.text(
- "SELECT is_read_committed_snapshot_on FROM sys.databases
WHERE name=:database_name"
- ),
+ sa.text("SELECT is_read_committed_snapshot_on FROM
sys.databases WHERE name=:database_name"),
Review Comment:
I think `import sqlalchemy as sa` it is not common pattern if we compare to
`import pandas as pd`, `import numpy as np` and `import multiprocessing as mp`,
I know only one place where this pattern uses -
[`alembic`](https://alembic.sqlalchemy.org/en/latest/tutorial.html#running-our-second-migration),
in all other places include SQLAlchemy's documentation common import pattern
is `from sqlalchemy import something`.
Particular in this file we've already imported `text` from `sqlalchemy`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]