Skip to content

Commit 806095a

Browse files
authored
🔧 chore: fix fetch event in OrganizationTestFireAction Endpoint (#95301)
1 parent 5cf2fc4 commit 806095a

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

‎src/sentry/notifications/notification_action/grouptype.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
from sentry.models.organization import Organization
1414
from sentry.ratelimits.sliding_windows import Quota
1515
from sentry.utils.samples import load_data
16+
from sentry.workflow_engine.tasks.utils import fetch_event
1617

1718

1819
@dataclass(frozen=True)
@@ -73,6 +74,10 @@ def get_test_notification_event_data(project) -> GroupEvent | None:
7374
return None
7475

7576
generic_group = group_info.group
76-
group_event = generic_group.get_latest_event()
7777

78-
return group_event
78+
event = fetch_event(occurrence.event_id, occurrence.project_id)
79+
80+
if event is None:
81+
return None
82+
83+
return GroupEvent.from_event(event, generic_group)

0 commit comments

Comments
 (0)