-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
feat(issues): Add GroupActionLog instrumentation for issue mutations #116347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
483d127
fe724a4
33847a7
e3e6df1
131c628
09c707a
1b2710b
ca12eb5
5afd16b
2f23cc3
a114751
8dd06ad
ab0f6b4
d475d46
fca57b6
1fba4f0
90f205f
e1aecec
b2c43ce
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -19,6 +19,7 @@ | |
| from sentry.integrations.services.assignment_source import AssignmentSource | ||
| from sentry.integrations.tasks.sync_assignee_outbound import sync_assignee_outbound | ||
| from sentry.integrations.types import EXTERNAL_PROVIDERS_REVERSE, ExternalProviderEnum | ||
| from sentry.issues.action_log import action_context_scope | ||
| from sentry.models.group import Group | ||
| from sentry.models.groupassignee import GroupAssignee | ||
| from sentry.models.organization import Organization | ||
|
|
@@ -82,10 +83,11 @@ def _handle_deassign( | |
| if not should_sync_assignee_inbound(group.organization, integration.provider): | ||
| continue | ||
|
|
||
| GroupAssignee.objects.deassign( | ||
| group, | ||
| assignment_source=AssignmentSource.from_integration(integration), | ||
| ) | ||
| with action_context_scope(source=integration.provider, actor_id=None): | ||
| GroupAssignee.objects.deassign( | ||
|
sentry[bot] marked this conversation as resolved.
|
||
| group, | ||
| assignment_source=AssignmentSource.from_integration(integration), | ||
| ) | ||
| groups_deassigned.append(group) | ||
| return groups_deassigned | ||
|
|
||
|
|
@@ -116,11 +118,12 @@ def _handle_assign( | |
| "user_id": user.id, | ||
| }, | ||
| ) | ||
| GroupAssignee.objects.assign( | ||
| group, | ||
| user, | ||
| assignment_source=AssignmentSource.from_integration(integration), | ||
| ) | ||
| with action_context_scope(source=integration.provider, actor_id=None): | ||
| GroupAssignee.objects.assign( | ||
| group, | ||
| user, | ||
| assignment_source=AssignmentSource.from_integration(integration), | ||
| ) | ||
|
Comment on lines
+121
to
+126
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: The Suggested FixIn Prompt for AI Agent
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. deferring to follow up |
||
| groups_assigned.append(group) | ||
| else: | ||
| logger.info( | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.