Skip to content

Commit f48a7d3

Browse files
author
Jesse Whitehouse
committed
Black the codebase
Signed-off-by: Jesse Whitehouse <[email protected]>
1 parent 1076619 commit f48a7d3

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/databricks/sqlalchemy/dialect/__init__.py

+7-3
Original file line numberDiff line numberDiff line change
@@ -267,18 +267,22 @@ def do_rollback(self, dbapi_connection):
267267
# Databricks SQL Does not support transactions
268268
pass
269269

270-
def has_table(self, connection, table_name, schema=None, catalog=None, **kwargs) -> bool:
270+
def has_table(
271+
self, connection, table_name, schema=None, catalog=None, **kwargs
272+
) -> bool:
271273
"""SQLAlchemy docstrings say dialect providers must implement this method"""
272274

273275
_schema = schema or self.schema
274276
_catalog = catalog or self.catalog
275-
277+
276278
# DBR >12.x uses underscores in error messages
277279
DBR_LTE_12_NOT_FOUND_STRING = "Table or view not found"
278280
DBR_GT_12_NOT_FOUND_STRING = "TABLE_OR_VIEW_NOT_FOUND"
279281

280282
try:
281-
res = connection.execute(f"DESCRIBE TABLE {_catalog}.{_schema}.{table_name}")
283+
res = connection.execute(
284+
f"DESCRIBE TABLE {_catalog}.{_schema}.{table_name}"
285+
)
282286
return True
283287
except DatabaseError as e:
284288
if DBR_GT_12_NOT_FOUND_STRING in str(

0 commit comments

Comments
 (0)