From 1bf12c83efba371f273c13cfb826f63b75689fee Mon Sep 17 00:00:00 2001 From: Alexander Sutcliffe Date: Wed, 15 Apr 2026 10:52:55 +0200 Subject: [PATCH 1/4] feat: add deprecation_date col to dbt_models --- macros/edr/dbt_artifacts/upload_dbt_models.sql | 3 +++ 1 file changed, 3 insertions(+) diff --git a/macros/edr/dbt_artifacts/upload_dbt_models.sql b/macros/edr/dbt_artifacts/upload_dbt_models.sql index 60d36b965..9d577d31f 100644 --- a/macros/edr/dbt_artifacts/upload_dbt_models.sql +++ b/macros/edr/dbt_artifacts/upload_dbt_models.sql @@ -40,6 +40,7 @@ ("incremental_strategy", "string"), ("group_name", "string"), ("access", "string"), + ("deprecation_date", "string"), ] %} {% if target.type == "bigquery" or elementary.get_config_var( "include_other_warehouse_specific_columns" @@ -114,6 +115,8 @@ "bigquery_cluster_by": config_dict.get("cluster_by"), "group_name": config_dict.get("group") or node_dict.get("group"), "access": config_dict.get("access") or node_dict.get("access"), + "deprecation_date": config_dict.get("deprecation_date") + or node_dict.get("deprecation_date"), } %} {% do flatten_model_metadata_dict.update( { From 83dee535359cbb02326ab37fbebb004a388eea73 Mon Sep 17 00:00:00 2001 From: Alexander Sutcliffe Date: Wed, 15 Apr 2026 10:54:10 +0200 Subject: [PATCH 2/4] chore: add deprecation_date to properties + other missing cols --- models/dbt_artifacts.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/models/dbt_artifacts.yml b/models/dbt_artifacts.yml index 29d7e2e78..48025af5b 100644 --- a/models/dbt_artifacts.yml +++ b/models/dbt_artifacts.yml @@ -7,6 +7,8 @@ models: Each row contains information about a single model. Data is loaded every time this model is executed. It is recommended to execute the model every time a change is merged to the project. + On BigQuery, or when the elementary variable include_other_warehouse_specific_columns is true, + the table also includes bigquery_partition_by and bigquery_cluster_by (not listed below). columns: - name: unique_id data_type: string @@ -72,10 +74,38 @@ models: data_type: string description: Short path of the model file. + - name: patch_path + data_type: string + description: Path to the YAML file that patches this model, if any. + - name: generated_at data_type: string description: Update time of the table. + - name: metadata_hash + data_type: string + description: Hash of the captured model metadata for change detection. + + - name: unique_key + data_type: string + description: Incremental unique_key from model config, if set. + + - name: incremental_strategy + data_type: string + description: Incremental strategy from model config, if set. + + - name: group_name + data_type: string + description: dbt group for the model, if assigned. + + - name: access + data_type: string + description: Model access level (for example private, protected, or public). + + - name: deprecation_date + data_type: string + description: Model deprecation_date property from the dbt graph, if set. + - name: dbt_tests description: > Metadata about tests in the project, including configuration and properties from the dbt graph. Each row contains information about a single test. From 842ff07f8a93326e56dae06fcac92c817bf8db5e Mon Sep 17 00:00:00 2001 From: Alexander Sutcliffe Date: Wed, 15 Apr 2026 11:21:00 +0200 Subject: [PATCH 3/4] fix: treat same as other top level keys --- macros/edr/dbt_artifacts/upload_dbt_models.sql | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/macros/edr/dbt_artifacts/upload_dbt_models.sql b/macros/edr/dbt_artifacts/upload_dbt_models.sql index 9d577d31f..183dd3b03 100644 --- a/macros/edr/dbt_artifacts/upload_dbt_models.sql +++ b/macros/edr/dbt_artifacts/upload_dbt_models.sql @@ -115,8 +115,7 @@ "bigquery_cluster_by": config_dict.get("cluster_by"), "group_name": config_dict.get("group") or node_dict.get("group"), "access": config_dict.get("access") or node_dict.get("access"), - "deprecation_date": config_dict.get("deprecation_date") - or node_dict.get("deprecation_date"), + "deprecation_date": node_dict.get("deprecation_date"), } %} {% do flatten_model_metadata_dict.update( { From 72a3b31b9f4e43bd3c9b53b1791c5ab226e7de34 Mon Sep 17 00:00:00 2001 From: Alexander Sutcliffe Date: Wed, 15 Apr 2026 11:22:35 +0200 Subject: [PATCH 4/4] fix: remove bloat --- models/dbt_artifacts.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/models/dbt_artifacts.yml b/models/dbt_artifacts.yml index 48025af5b..7902e97aa 100644 --- a/models/dbt_artifacts.yml +++ b/models/dbt_artifacts.yml @@ -7,8 +7,6 @@ models: Each row contains information about a single model. Data is loaded every time this model is executed. It is recommended to execute the model every time a change is merged to the project. - On BigQuery, or when the elementary variable include_other_warehouse_specific_columns is true, - the table also includes bigquery_partition_by and bigquery_cluster_by (not listed below). columns: - name: unique_id data_type: string