Skip to content

fix(api): cancel builds on template delete#2377

Open
jakubno wants to merge 6 commits intomainfrom
fix/cancel-active-builds-on-template-delete
Open

fix(api): cancel builds on template delete#2377
jakubno wants to merge 6 commits intomainfrom
fix/cancel-active-builds-on-template-delete

Conversation

@jakubno
Copy link
Copy Markdown
Member

@jakubno jakubno commented Apr 13, 2026

Cancel active template builds when deleting template

@cursor
Copy link
Copy Markdown

cursor bot commented Apr 13, 2026

PR Summary

Medium Risk
Touches template deletion and build-cancellation flow, plus changes the DeleteTemplate query return shape; mistakes could leave builds running or cause partial cleanup/cancellation failures.

Overview
Template deletion now also cancels any in-progress builds for the deleted template by extending DeleteTemplate to return both alias keys and active build metadata (build/node/cluster) and invoking orchestrator build deletion with a timeout. Snapshot cleanup and cache invalidation were updated to handle the new DeleteTemplate return type, and the unused DeleteActiveTemplateBuild SQL/query was removed with tests adjusted accordingly.

Reviewed by Cursor Bugbot for commit c3fbe3a. Bugbot is set up for automated code reviews on this repo. Configure here.

Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

There are 3 total unresolved issues (including 2 from previous reviews).

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 81fa346. Configure here.

@jakubno jakubno marked this pull request as ready for review April 13, 2026 18:11
@jakubno jakubno assigned dobrac and unassigned arkamar Apr 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants