Skip to content

Commit 75ee3c9

Browse files
fix(logs): Warn instead of error on schema extract failure (#15230)
Co-authored-by: Sergio Gómez Villamor <sgomezvillamor@gmail.com>
1 parent d46c767 commit 75ee3c9

File tree

1 file changed

+5
-2
lines changed
  • metadata-ingestion/src/datahub/ingestion/source/s3

1 file changed

+5
-2
lines changed

metadata-ingestion/src/datahub/ingestion/source/s3/source.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -735,8 +735,11 @@ def ingest_table(
735735
)
736736
aspects.append(schema_metadata)
737737
except Exception as e:
738-
logger.error(
739-
f"Failed to extract schema from file {table_data.full_path}. The error was:{e}"
738+
self.report.report_warning(
739+
title="Failed to extract schema from file",
740+
message="Schema may be missed for dataset because of failure when extracting schema from file",
741+
context=f"dataset={table_data.display_name}, file={table_data.full_path}",
742+
exc=e,
740743
)
741744
else:
742745
logger.info(

0 commit comments

Comments
 (0)