diff --git a/src/sentry/monitors/models.py b/src/sentry/monitors/models.py index 62ddc00ecd4da7..d63f189bf96348 100644 --- a/src/sentry/monitors/models.py +++ b/src/sentry/monitors/models.py @@ -533,9 +533,9 @@ def mark_failed(self, last_checkin=None, reason=MonitorFailure.UNKNOWN): resource_id=None, project_id=self.monitor.project_id, event_id=uuid.uuid4().hex, - fingerprint=hash_from_values( - ["monitor", str(self.monitor.guid), occurrence_data["reason"]] - ), + fingerprint=[ + hash_from_values(["monitor", str(self.monitor.guid), occurrence_data["reason"]]) + ], type=occurrence_data["group_type"], issue_title=f"Monitor failure: {self.monitor.name}", subtitle="", diff --git a/tests/sentry/monitors/test_models.py b/tests/sentry/monitors/test_models.py index f78213e7571407..f440a8a0e92eb7 100644 --- a/tests/sentry/monitors/test_models.py +++ b/tests/sentry/monitors/test_models.py @@ -324,7 +324,7 @@ def test_mark_failed_default_params_issue_platform(self, mock_produce_occurrence occurrence, **{ "project_id": self.project.id, - "fingerprint": hash_from_values(["monitor", str(monitor.guid), "error"]), + "fingerprint": [hash_from_values(["monitor", str(monitor.guid), "error"])], "issue_title": f"Monitor failure: {monitor.name}", "subtitle": "", "resource_id": None, @@ -393,7 +393,7 @@ def test_mark_failed_with_reason_issue_platform(self, mock_produce_occurrence_to occurrence, **{ "project_id": self.project.id, - "fingerprint": hash_from_values(["monitor", str(monitor.guid), "duration"]), + "fingerprint": [hash_from_values(["monitor", str(monitor.guid), "duration"])], "issue_title": f"Monitor failure: {monitor.name}", "subtitle": "", "resource_id": None, @@ -466,7 +466,7 @@ def test_mark_failed_with_missed_reason_issue_platform(self, mock_produce_occurr occurrence, **{ "project_id": self.project.id, - "fingerprint": hash_from_values(["monitor", str(monitor.guid), "missed_checkin"]), + "fingerprint": [hash_from_values(["monitor", str(monitor.guid), "missed_checkin"])], "issue_title": f"Monitor failure: {monitor.name}", "subtitle": "", "resource_id": None,