diff --git a/metadata-ingestion/src/datahub/ingestion/source/looker/looker_file_loader.py b/metadata-ingestion/src/datahub/ingestion/source/looker/looker_file_loader.py index bc069bd1e59ac4..fd670c23ad9cb0 100644 --- a/metadata-ingestion/src/datahub/ingestion/source/looker/looker_file_loader.py +++ b/metadata-ingestion/src/datahub/ingestion/source/looker/looker_file_loader.py @@ -60,7 +60,12 @@ def _load_viewfile( with open(path) as file: raw_file_content = file.read() except Exception as e: - self.reporter.failure("Failed to read lkml file", path, exc=e) + self.reporter.failure( + title="LKML File Loading Error", + message="A lookml file is not present on local storage or GitHub", + context=f"file path: {path}", + exc=e, + ) self.viewfile_cache[path] = None return None try: @@ -86,8 +91,19 @@ def _load_viewfile( self.viewfile_cache[path] = looker_viewfile return looker_viewfile except Exception as e: - self.reporter.failure("Failed to parse lkml file", path, exc=e) + self.reporter.failure( + title="LKML File Parsing Error", + message="The input file is not lookml file", + context=f"file path: {path}", + exc=e, + ) + + logger.debug(f"Raw file content for path {path}") + + logger.debug(raw_file_content) + self.viewfile_cache[path] = None + return None def load_viewfile(