Skip to content

Commit

Permalink
fix(ingest/looker): Add flag for Looker metadata extraction
Browse files Browse the repository at this point in the history
  • Loading branch information
sagar-salvi-apptware committed Dec 23, 2024
1 parent eceb799 commit d3b75c7
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ def _get_last_line(query: str) -> str:
class ToolMetaExtractorReport(Report):
num_queries_meta_extracted: Dict[str, int] = field(default_factory=int_top_k_dict)
failures: List[str] = field(default_factory=list)
looker_mapping_missing = False


class ToolMetaExtractor:
Expand Down Expand Up @@ -108,7 +109,9 @@ def extract_looker_user_mapping_from_graph(
PlatformResource.search_by_filters(query=query, graph_client=graph)
)

if len(platform_resources) > 1:
if len(platform_resources) == 0:
report.looker_mapping_missing = True
elif len(platform_resources) > 1:
report.failures.append(
"Looker user metadata extraction failed. Found more than one looker user id mappings."
)
Expand Down

0 comments on commit d3b75c7

Please sign in to comment.