File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed
src/sentry/workflow_engine Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 44
55from sentry .models .organization import Organization
66from sentry .models .project import Project
7+ from sentry .notifications .models .notificationaction import ActionTarget
78from sentry .notifications .types import FallthroughChoiceType
89from sentry .workflow_engine .defaults .detectors import _ensure_detector
910from sentry .workflow_engine .models import (
@@ -84,8 +85,10 @@ def create_priority_workflow(org: Organization) -> Workflow:
8485 action = Action .objects .create (
8586 type = Action .Type .EMAIL ,
8687 config = {
87- "target_type" : "IssueOwners" ,
88+ "target_type" : ActionTarget . ISSUE_OWNERS ,
8889 "target_identifier" : None ,
90+ },
91+ data = {
8992 "fallthrough_type" : FallthroughChoiceType .ACTIVE_MEMBERS .value ,
9093 },
9194 )
Original file line number Diff line number Diff line change 11import logging
2+ from typing import Any
23
34from django .db import router , transaction
45
3536PLATFORMS_WITH_PRIORITY_ALERTS = ["python" , "javascript" ]
3637
3738
38- def create_default_rules (project : Project ) -> None :
39+ def create_default_rules (project : Project , ** kwargs : Any ) -> None :
3940 rule_data = DEFAULT_RULE_DATA
4041
4142 with transaction .atomic (router .db_for_write (Rule )):
You can’t perform that action at this time.
0 commit comments