Skip to content

Commit fbbc4cd

Browse files
Narrow exception handling for single table ingestion.
1 parent b1e64e4 commit fbbc4cd

File tree

1 file changed

+5
-2
lines changed
  • src/databricks/labs/lakebridge/assessments/dashboards

1 file changed

+5
-2
lines changed

src/databricks/labs/lakebridge/assessments/dashboards/execute.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,11 @@ def _ingest_profiler_tables(catalog_name: str, schema_name: str, extract_locatio
7777
logger.info(f"Ingesting profiler table: '{fq_source_table_name}'")
7878
_ingest_table(extract_location, fq_source_table_name, fq_delta_table_name)
7979
successful_tables.append(fq_source_table_name)
80-
except Exception:
81-
logger.error(f"Skipping the ingestion of table '{source_table}' from profiler extract.")
80+
except (ValueError, IndexError, TypeError) as e:
81+
logger.error(f"Failed to construct source and destination table names: {e}")
82+
unsuccessful_tables.append(source_table)
83+
except duckdb.Error as e:
84+
logger.error(f"Failed to ingest table from profiler database: {e}")
8285
unsuccessful_tables.append(source_table)
8386
logger.info(f"Ingested {len(successful_tables)} tables from profiler extract.")
8487
logger.info(",".join(successful_tables))

0 commit comments

Comments
 (0)