Skip to content
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

✨ feat(notifications): open_period_start_for_group util for threads #83689

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

iamrajjoshi
Copy link
Member

This PR introduces a function that returns the latest "open period" for a particular group. It will be used as a key in future threads refactor PR to create 1 thread per open group.

One example use case is to return the latest open period for an Uptime Issue.

spec: notion.so/sentry/Slack-Threads-Refactor-1618b10e4b5d807db67ae6d4d85247b9
contributes to: getsentry.atlassian.net/browse/ACI-89

@iamrajjoshi iamrajjoshi requested review from wedamija, snigdhas and a team January 17, 2025 23:48
@iamrajjoshi iamrajjoshi self-assigned this Jan 17, 2025
@iamrajjoshi iamrajjoshi requested a review from a team as a code owner January 17, 2025 23:48
@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Jan 17, 2025
from sentry.models.group import Group


def open_period_start_for_group(group: Group) -> datetime | None:
Copy link
Member Author

Choose a reason for hiding this comment

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

open to moving this somewhere else, i think we should have a single place where we store these types of utils to work with Open Periods for notifications/issue platform.

as we figure out what types of methods exist, we can start bringing them together, open to leaving this as a todo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Scope: Backend Automatically applied to PRs that change backend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant