fix(ingest/tableau): handle missing query in tableau views (#7186)

This commit is contained in:
Harshal Sheth 2023-02-07 03:09:26 +05:30 committed by GitHub
parent 389aa8c1d0
commit b24f206e04
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -920,7 +920,7 @@ class TableauSource(StatefulIngestionSourceBase):
view_properties = ViewPropertiesClass(
materialized=False,
viewLanguage="SQL",
viewLogic=clean_query(csql.get("query", "")),
viewLogic=clean_query(csql.get("query") or ""),
)
dataset_snapshot.aspects.append(view_properties)

View File

@ -616,7 +616,7 @@ def get_unique_custom_sql(custom_sql_list: List[dict]) -> List[dict]:
return unique_custom_sql
def clean_query(query):
def clean_query(query: str) -> str:
"""
Clean special chars in query
"""