From 32c870244e4dbae91d9d07231e93088e64496cb7 Mon Sep 17 00:00:00 2001 From: Harshal Sheth Date: Mon, 23 Sep 2024 19:57:30 -0700 Subject: [PATCH] fix(ingest/dbt): allow custom owner types for dbt meta (#11460) --- .../src/datahub/ingestion/source/dbt/dbt_common.py | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/metadata-ingestion/src/datahub/ingestion/source/dbt/dbt_common.py b/metadata-ingestion/src/datahub/ingestion/source/dbt/dbt_common.py index 12812aad441f2..acbfd65f67d30 100644 --- a/metadata-ingestion/src/datahub/ingestion/source/dbt/dbt_common.py +++ b/metadata-ingestion/src/datahub/ingestion/source/dbt/dbt_common.py @@ -415,15 +415,7 @@ def meta_mapping_validator( if v["operation"] == "add_owner": owner_category = v["config"].get("owner_category") if owner_category: - allowed_categories = [ - value - for name, value in vars(OwnershipTypeClass).items() - if not name.startswith("_") - ] - if (owner_category.upper()) not in allowed_categories: - raise ValueError( - f"Owner category {owner_category} is not one of {allowed_categories}" - ) + mce_builder.validate_ownership_type(owner_category) return meta_mapping @validator("include_column_lineage")