Skip to content

feat(issue-platform): Allow assignee to be passed with the occurrence #69031

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

Merged
merged 2 commits into from
Apr 16, 2024

Conversation

wedamija
Copy link
Member

We want to allow issue platform customers to specify who should be assigned to the issues created from their occurrences. This assignee will only be used when creating a new issue, it won't change the assignee of an existing issue.

Assignees can be team or user. We already have a format for passing this via the API, so I'm using this here too. The Actor format (separate from the Actor model which is being removed) allows us to specify the assignee in a structured way. The format is defined here:

Forms `actor_identifier` can take:
1231 -> look up User by id
"1231" -> look up User by id
"user:1231" -> look up User by id
"team:1231" -> look up Team by id
"maiseythedog" -> look up User by username
"maisey@dogsrule.com" -> look up User by primary email

We want to allow issue platform customers to specify who should be assigned to the issues created from their occurrences. This assignee will only be used when creating a new issue, it won't change the assignee of an existing issue.

Assignees can be team or user. We already have a format for passing this via the API, so I'm using this here too. The Actor format (separate from the `Actor` model which is being removed) allows us to specify the assignee in a structured way. The format is defined here: https://github.com/getsentry/sentry/blob/ef66c637e6a69de97552a1fd6b200e16939afa94/src/sentry/utils/actor.py#L41-L47
@wedamija wedamija requested a review from a team as a code owner April 16, 2024 20:05
@wedamija wedamija requested a review from a team April 16, 2024 20:05
@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Apr 16, 2024
Copy link
Member

@JoshFerge JoshFerge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm. is there a way to add a more e2e test that confirms behavior that the issue created by the issue platform then has a correct assignee?

@JoshFerge
Copy link
Member

lgtm. is there a way to add a more e2e test that confirms behavior that the issue created by the issue platform then has a correct assignee?

ah i see your slack messsage, it is just passing in assignee, not doing anything with it.

@wedamija
Copy link
Member Author

lgtm. is there a way to add a more e2e test that confirms behavior that the issue created by the issue platform then has a correct assignee?

ah i see your slack messsage, it is just passing in assignee, not doing anything with it.

Yeah, I'll add a comprehensive test to IssueOccurrenceProcessMessageTest once I make the behaviour work

Co-authored-by: Evan Purkhiser <evanpurkhiser@gmail.com>
@wedamija wedamija enabled auto-merge (squash) April 16, 2024 20:27
@wedamija wedamija merged commit bf7faa7 into master Apr 16, 2024
48 checks passed
@wedamija wedamija deleted the danf/issue-platform-pass-assignee branch April 16, 2024 20:57
@github-actions github-actions bot locked and limited conversation to collaborators May 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Scope: Backend Automatically applied to PRs that change backend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants