Automate sprint completion [BB-6197]
Story
"As a SprintCraft admin, I don't want to stay awake until midnight to press a single button."
Full description
As the sprint completion has been stable in the past months (except for situations when the sprint is closed before the deadline), we should finally automate it.
Completion criteria
- Check if we could perform all calculations for each item of the pipeline before sending any data. This way, if a part of the pipeline fails, then we will not need to deal with resolving missing partial dependencies.
- This step will require some investigation. If a part of the pipeline is not crucial for ending the sprint (e.g. "Create role tickets", "Trigger the
new sprint
webhooks"), could we send errors to Sentry, but let the pipeline pass gracefully? Should we separate some computations from the main pipeline to be able to run the failed command with the management command? This does not need to be implemented as a part of this issue. - Add a note about running
schedule_sprint_tasks_task
to thecomplete_sprint_task
's docstring. - Move
sprintcraft.dashboard.tasks.unflag_tickets_task
to the beginning of the sprint completion pipeline. - Automate completing sprints either for each cell. Determine if it should be a serial or parallel process (for cells) - check things like e.g. "Can we run into race conditions in Google Sheets/Jira?".
Documentation updates & improvements criteria
- Update docs.
Edited by Piotr Surowiec