Skip to content

Commit 4f1bc3e

Browse files
fix LegacyRow not being Dict
1 parent ebfb17c commit 4f1bc3e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

metadata-ingestion/src/datahub/ingestion/source/sql/hive_metastore.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -893,7 +893,10 @@ def get_schema_fields_for_column(
893893
return get_schema_fields_for_hive_column(
894894
column["col_name"],
895895
column["col_type"],
896-
description=column.get("col_description", ""),
896+
# column is actually an sqlalchemy.engine.row.LegacyRow, not a Dict and we cannot make column.get("col_description", "")
897+
description=(
898+
column["col_description"] if "col_description" in column else "" # noqa: SIM401
899+
),
897900
default_nullable=True,
898901
)
899902

0 commit comments

Comments
 (0)