From 15751e23193d5b910d9cee449d7699bc5a53a3a3 Mon Sep 17 00:00:00 2001 From: Ofek Weiss Date: Mon, 28 Jul 2025 15:53:30 +0300 Subject: [PATCH 1/3] full name in summary --- elementary/monitor/alerts/source_freshness_alert.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/elementary/monitor/alerts/source_freshness_alert.py b/elementary/monitor/alerts/source_freshness_alert.py index 9da7d831a..20ef99250 100644 --- a/elementary/monitor/alerts/source_freshness_alert.py +++ b/elementary/monitor/alerts/source_freshness_alert.py @@ -142,9 +142,12 @@ def data(self) -> Dict: freshness_description=self.freshness_description, ) + def get_source_full_name(self) -> str: + return f"{self.source_name}.{self.identifier}" + @property def concise_name(self) -> str: - return f"source freshness alert - {self.source_name}.{self.identifier}" + return f"source freshness alert - {self.get_source_full_name()}" @property def error_message(self) -> str: @@ -155,8 +158,8 @@ def error_message(self) -> str: @property def summary(self) -> str: if self.original_status == "runtime error": - return f'Failed to calculate the source freshness of "{self.source_name}"' - return f'Freshness exceeded the acceptable times on source "{self.source_name}"' + return f'Failed to calculate the source freshness of "{self.get_source_full_name()}"' + return f'Freshness exceeded the acceptable times on source "{self.get_source_full_name()}"' def get_report_link(self) -> Optional[ReportLinkData]: return get_test_runs_link(self.report_url, self.source_freshness_execution_id) From 4a7348bc1ae49bac7f2c466b933d104c32493472 Mon Sep 17 00:00:00 2001 From: Ofek Weiss Date: Mon, 28 Jul 2025 16:01:45 +0300 Subject: [PATCH 2/3] fixed tests --- ...s-True_path-True_error-True_suppression-False_env-False.json | 2 +- ...s-True_path-False_error-True_suppression-False_env-True.json | 2 +- ...False_path-False_error-False_suppression-True_env-False.json | 2 +- ...s-True_path-True_error-False_suppression-True_env-False.json | 2 +- ...rs-False_path-True_error-True_suppression-True_env-True.json | 2 +- ...alse_path-False_error-False_suppression-False_env-False.json | 2 +- ...s-False_path-False_error-True_suppression-True_env-True.json | 2 +- ...s-False_path-True_error-False_suppression-True_env-True.json | 2 +- ...s-True_path-False_error-True_suppression-False_env-True.json | 2 +- ...ers-True_path-True_error-True_suppression-True_env-True.json | 2 +- ...s-True_path-True_error-True_suppression-False_env-False.json | 2 +- ...s-True_path-False_error-True_suppression-False_env-True.json | 2 +- ...False_path-False_error-False_suppression-True_env-False.json | 2 +- ...s-True_path-True_error-False_suppression-True_env-False.json | 2 +- ...rs-False_path-True_error-True_suppression-True_env-True.json | 2 +- ...alse_path-False_error-False_suppression-False_env-False.json | 2 +- ...s-False_path-False_error-True_suppression-True_env-True.json | 2 +- ...s-False_path-True_error-False_suppression-True_env-True.json | 2 +- ...s-True_path-False_error-True_suppression-False_env-True.json | 2 +- ...ers-True_path-True_error-True_suppression-True_env-True.json | 2 +- 20 files changed, 20 insertions(+), 20 deletions(-) diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json index 8aace3306..bd0e28aa0 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json index bdd1ab80e..bbf98648d 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json index 1c89d23b8..e74a48d47 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json index dcae91454..ba5283487 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json index 391f2c6de..5ede629bb 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json index 3672f1464..e7c9498f0 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json index c84066c2b..9f95742f4 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json index 2762a7ecf..05a112f53 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json index b283f59e7..846c85e71 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json index 3120b0eee..4d55a5e7c 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json index ed584f87d..304e4fcce 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json index 6d05deb80..72b1a4a29 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json index f56e3e70e..adedd745c 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json index 9ffdc9614..7669e0e3e 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json index b80b1d9c8..0389ba2a6 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json index a95be5a7a..37d6ec496 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json index 51d707f2b..ae2e64464 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json index ad81d2a32..c99353dda 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json index 0dbca6a0b..805910c62 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json index ab9a790d0..4eec09efc 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" } }, { From 8f1bb0f68dd54d857c1480b1f6303c3804cac38e Mon Sep 17 00:00:00 2001 From: Ofek Weiss Date: Mon, 28 Jul 2025 16:25:12 +0300 Subject: [PATCH 3/3] use fqn --- .../monitor/alerts/source_freshness_alert.py | 16 ++++++++++------ ...e_error-True_suppression-False_env-False.json | 2 +- ...se_error-True_suppression-False_env-True.json | 2 +- ...e_error-False_suppression-True_env-False.json | 2 +- ...e_error-False_suppression-True_env-False.json | 2 +- ...rue_error-True_suppression-True_env-True.json | 2 +- ..._error-False_suppression-False_env-False.json | 2 +- ...lse_error-True_suppression-True_env-True.json | 2 +- ...ue_error-False_suppression-True_env-True.json | 2 +- ...se_error-True_suppression-False_env-True.json | 2 +- ...rue_error-True_suppression-True_env-True.json | 2 +- ...e_error-True_suppression-False_env-False.json | 2 +- ...se_error-True_suppression-False_env-True.json | 2 +- ...e_error-False_suppression-True_env-False.json | 2 +- ...e_error-False_suppression-True_env-False.json | 2 +- ...rue_error-True_suppression-True_env-True.json | 2 +- ..._error-False_suppression-False_env-False.json | 2 +- ...lse_error-True_suppression-True_env-True.json | 2 +- ...ue_error-False_suppression-True_env-True.json | 2 +- ...se_error-True_suppression-False_env-True.json | 2 +- ...rue_error-True_suppression-True_env-True.json | 2 +- .../alerts/alert_messages/test_alert_utils.py | 2 ++ 22 files changed, 32 insertions(+), 26 deletions(-) diff --git a/elementary/monitor/alerts/source_freshness_alert.py b/elementary/monitor/alerts/source_freshness_alert.py index 20ef99250..90bae3a50 100644 --- a/elementary/monitor/alerts/source_freshness_alert.py +++ b/elementary/monitor/alerts/source_freshness_alert.py @@ -142,12 +142,9 @@ def data(self) -> Dict: freshness_description=self.freshness_description, ) - def get_source_full_name(self) -> str: - return f"{self.source_name}.{self.identifier}" - @property def concise_name(self) -> str: - return f"source freshness alert - {self.get_source_full_name()}" + return f"source freshness alert - {self.source_name}.{self.identifier}" @property def error_message(self) -> str: @@ -157,9 +154,16 @@ def error_message(self) -> str: @property def summary(self) -> str: + source_fqn = ".".join( + [ + part + for part in [self.database_name, self.schema_name, self.identifier] + if part + ] + ) if self.original_status == "runtime error": - return f'Failed to calculate the source freshness of "{self.get_source_full_name()}"' - return f'Freshness exceeded the acceptable times on source "{self.get_source_full_name()}"' + return f'Failed to calculate the source freshness of "{source_fqn}"' + return f'Freshness exceeded the acceptable times on source "{source_fqn}"' def get_report_link(self) -> Optional[ReportLinkData]: return get_test_runs_link(self.report_url, self.source_freshness_execution_id) diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json index bd0e28aa0..ad9b40d92 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json index bbf98648d..e659a9db6 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json index e74a48d47..6b14553c7 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json index ba5283487..bda247eab 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json index 5ede629bb..3a6774d7f 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"", + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json index e7c9498f0..e02a53db9 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json index 9f95742f4..f60b016ea 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json index 05a112f53..1fc112382 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json index 846c85e71..eaff58089 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json index 4d55a5e7c..c917c5690 100644 --- a/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/adaptive_card/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json @@ -10,7 +10,7 @@ "items": [ { "type": "TextBlock", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"", + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"", "weight": "bolder", "size": "large", "wrap": true diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json index 304e4fcce..598d1de09 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-False_tags-True_owners-True_path-True_error-True_suppression-False_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json index 72b1a4a29..23fb2a576 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-False_message-True_tags-True_owners-True_path-False_error-True_suppression-False_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json index adedd745c..969f7b47c 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-False_owners-False_path-False_error-False_suppression-True_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json index 7669e0e3e..8d92eaaee 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-False_tags-True_owners-True_path-True_error-False_suppression-True_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json index 0389ba2a6..fc445ffb9 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-error_link-True_message-True_tags-False_owners-False_path-True_error-True_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Error: Freshness exceeded the acceptable times on source \"test_source.test_identifier\"" + "text": "Error: Freshness exceeded the acceptable times on source \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json index 37d6ec496..cf80aaaf2 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-False_tags-False_owners-False_path-False_error-False_suppression-False_env-False.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json index ae2e64464..f9f390fce 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-False_message-True_tags-True_owners-False_path-False_error-True_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json index c99353dda..9f464fa95 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-False_tags-True_owners-False_path-True_error-False_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json index 805910c62..ed9e5872c 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-False_owners-True_path-False_error-True_suppression-False_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json index 4eec09efc..d647c8186 100644 --- a/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json +++ b/tests/unit/alerts/alert_messages/fixtures/block_kit/source_freshness_alert_status-runtime error_link-True_message-True_tags-True_owners-True_path-True_error-True_suppression-True_env-True.json @@ -4,7 +4,7 @@ "type": "header", "text": { "type": "plain_text", - "text": "Runtime Error: Failed to calculate the source freshness of \"test_source.test_identifier\"" + "text": "Runtime Error: Failed to calculate the source freshness of \"test_db.test_schema.test_identifier\"" } }, { diff --git a/tests/unit/alerts/alert_messages/test_alert_utils.py b/tests/unit/alerts/alert_messages/test_alert_utils.py index f452e7c80..b0b4faa61 100644 --- a/tests/unit/alerts/alert_messages/test_alert_utils.py +++ b/tests/unit/alerts/alert_messages/test_alert_utils.py @@ -272,6 +272,8 @@ def build_base_source_freshness_alert_model( return SourceFreshnessAlertModel( id="test_id", source_name="test_source", + database_name="test_db", + schema_name="test_schema", identifier="test_identifier", original_status=status, path=path,