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

Speeds up case resolution #5384

Merged
merged 2 commits into from
Oct 23, 2024
Merged

Conversation

mvilanova
Copy link
Contributor

Code Changes Summary

Pre-commit Configuration Updates

  • Updated the version of the ruff-pre-commit hook from v0.6.4 to v0.7.0.
  • Updated the version of the typos hook from v1.24.5 to v1.26.1.

Imports Reordering

  • Reordered imports in src/dispatch/case/flows.py for better readability and organization.

Conditional Logic Enhancements

  • In case_update_flow, added checks to ensure that the reporter or assignee email has changed before running the case_assign_role_flow and updating the tactical group. This prevents unnecessary operations if the emails haven't changed.

Refactoring in Slack Interactive Case Handling

  • In handle_resolve_submission_event within src/dispatch/plugins/dispatch_slack/case/interactive.py:
    • Renamed case to current_case for clarity.
    • Simplified the logic by directly using current_case for updates and notifications.
    • Ensured that the case update flow and message updates use the updated case information.
    • Added handling for resolution_reason in the case update process.

These changes improve code clarity, efficiency, and maintainability by reducing redundant operations and enhancing the logical flow.

@mvilanova mvilanova added the enhancement New feature or request label Oct 23, 2024
Copy link
Contributor

@wssheldon wssheldon left a comment

Choose a reason for hiding this comment

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

looks good, thanks for making the case variables more clear

@mvilanova mvilanova merged commit 0ddfb61 into master Oct 23, 2024
8 of 9 checks passed
@mvilanova mvilanova deleted the enhancement/speeds-up-case-resolution branch October 23, 2024 19:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants