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(escalating-issues): Add ARCHIVE_UNTIL_ESCALATING to GroupHistory #47437

Merged
merged 24 commits into from
Apr 18, 2023

Conversation

snigdhas
Copy link
Member

  • Adds ARCHIVE_UNTIL_ESCALATING and ESCALATING to GroupHistoryStatus
  • Sets the GroupHistory per the GroupSubStatus

WOR-2835, WOR-2964

@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Apr 15, 2023
@codecov
Copy link

codecov bot commented Apr 15, 2023

Codecov Report

Merging #47437 (03e78aa) into master (9a8b435) will decrease coverage by 2.52%.
The diff coverage is 100.00%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #47437      +/-   ##
==========================================
- Coverage   80.75%   78.23%   -2.52%     
==========================================
  Files        4762     4762              
  Lines      201425   201421       -4     
  Branches    11618    11618              
==========================================
- Hits       162654   157575    -5079     
- Misses      38515    43590    +5075     
  Partials      256      256              
Impacted Files Coverage Δ
src/sentry/api/endpoints/team_issue_breakdown.py 98.14% <100.00%> (ø)
src/sentry/api/helpers/group_index/update.py 94.01% <100.00%> (+0.02%) ⬆️
...sentry/api/helpers/group_index/validators/group.py 95.23% <100.00%> (+0.11%) ⬆️
src/sentry/issues/status_change.py 100.00% <100.00%> (ø)
src/sentry/models/group.py 93.38% <100.00%> (-0.11%) ⬇️
src/sentry/models/grouphistory.py 97.40% <100.00%> (+0.18%) ⬆️
src/sentry/receivers/releases.py 75.89% <100.00%> (-17.75%) ⬇️
src/sentry/tasks/clear_expired_snoozes.py 100.00% <100.00%> (ø)
...c/sentry/tasks/integrations/sync_status_inbound.py 96.29% <100.00%> (ø)
src/sentry/tasks/weekly_escalating_forecast.py 97.82% <100.00%> (ø)
... and 1 more

... and 310 files with indirect coverage changes

@snigdhas snigdhas requested a review from a team April 17, 2023 17:25
Comment on lines -152 to -169
class GroupSubStatus:
# GroupStatus.IGNORED
UNTIL_ESCALATING = 1

# GroupStatus.UNRESOLVED
ESCALATING = 2
ONGOING = 3


UNRESOLVED_SUBSTATUS_CHOICES = {
GroupSubStatus.ONGOING,
GroupSubStatus.ESCALATING,
}

IGNORED_SUBSTATUS_CHOICES = {
GroupSubStatus.UNTIL_ESCALATING,
}

Copy link
Member Author

Choose a reason for hiding this comment

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

Moving the GroupSubStatus types to sentry/types

@snigdhas snigdhas marked this pull request as ready for review April 17, 2023 23:44
@snigdhas snigdhas requested a review from a team April 17, 2023 23:44
@snigdhas snigdhas requested a review from a team as a code owner April 17, 2023 23:44
@snigdhas snigdhas requested a review from a team April 17, 2023 23:44
@snigdhas snigdhas added this to the Escalating Issues V1 milestone Apr 17, 2023
Comment on lines +7 to +8
from sentry.models.group import STATUS_UPDATE_CHOICES
from sentry.types.group import SUBSTATUS_UPDATE_CHOICES
Copy link
Member

Choose a reason for hiding this comment

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

I don't know our conventions, but is it weird that one of these lives in the model and one lives in the types module?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, I don't like that split either - I can look at rehoming the GroupStatus + related types in a followup PR. Had to move the GroupSubStatus because of a circular dependency

src/sentry/models/grouphistory.py Outdated Show resolved Hide resolved
src/sentry/types/group.py Outdated Show resolved Hide resolved
Base automatically changed from snigdha/substatus-presave to master April 18, 2023 16:35
@snigdhas snigdhas requested review from a team April 18, 2023 16:35
src/sentry/types/group.py Outdated Show resolved Hide resolved
snigdhas and others added 2 commits April 18, 2023 15:04
Co-authored-by: Katie Byers <katie.byers@sentry.io>
@snigdhas snigdhas merged commit a98feb8 into master Apr 18, 2023
@snigdhas snigdhas deleted the snigdha/add-arch-gh branch April 18, 2023 23:01
@github-actions github-actions bot locked and limited conversation to collaborators May 4, 2023
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.

2 participants