There are 2 ways we could approach this, both will require back-end work.
Option 1. If a user attempts to delete an image that is currently being imported, the UI can first make a request to `bootresource.stop_import` before calling `bootresource.delete_image`.
However, bootresource.stop_import currently stops all imports and doesn't allow to specify particular images. We would need to modify this endpoint to accept image id.
Option 2. When bootresource.delete_image is called on an image being downloaded, the back-end could make sure that download operation is paused before proceeding with the deletion.
There are 2 ways we could approach this, both will require back-end work.
Option 1. If a user attempts to delete an image that is currently being imported, the UI can first make a request to `bootresource. stop_import` before calling `bootresource. delete_ image`. stop_import currently stops all imports and doesn't allow to specify particular images. We would need to modify this endpoint to accept image id.
However, bootresource.
Option 2. When bootresource. delete_ image is called on an image being downloaded, the back-end could make sure that download operation is paused before proceeding with the deletion.