Bug 10289

Summary: Deleting a project while a build is in progress causes the "all builds" page to error
Product: [Build System, Metadata & Runtime] Toaster Reporter: Belen Barros Pena <belen.barros.pena>
Component: toasterAssignee: Michael Wood <michael.g.wood>
Status: RESOLVED FIXED QA Contact: Libertad <libertad.gonzalez.de.la.cruz>
Severity: normal    
Priority: Medium CC: belen.barros.pena, jessica.zhang, stanciux.mihail
Version: unspecified   
Target Milestone: 2.2 M4   
Hardware: x86   
OS: Multiple   
Whiteboard: GUI design pending
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)
Bug Depends on:    
Bug Blocks: 10286    

Description Belen Barros Pena 2016-09-16 11:18:54 UTC
Steps to reproduce:

1. Create a Toaster project
2. Start a build
3. Go back to the project configuration page and click the "delete project" link
4. Confirm that you want to delete the project
5. When the deletion is done, click on the "All builds" link in the global navigation

The page shows this error:

'InvalidString' object has no attribute 'is_default'

If a user tries to delete a project that has a build in progress, we should:

1. Tell users about it in the delete confirmation dialog, and warn them that the build in progress will be cancelled

2. Cancel the build in progress before deleting the project

The project deletion should also be a modal process, which is convered in bug 10286
Comment 1 Michael Wood 2016-10-06 14:17:28 UTC
http://git.yoctoproject.org/cgit/cgit.cgi/poky/atom/fffce32ebd8712e29cc6f9c4a7a97ce40f9916ee
Before we finally delete any project make sure we send the cancel command to
any in-progress builds. This ensures that an inaccessible build doesn't block
up the system and that we don't get errors after deletion.

[YOCTO #10289]

(Bitbake rev: 263762a01a6460332ef0cfea5df1e5b81c086df4)