Problem: Unexpected error when a user attempts to delete some images
Problem/Opportunity Statement
To reproduce:
- Create an instance (called Instance-A)
- Shelve Instance-A
- Manually launch a new instance - Instance-B - from the image of the shelved instance (manually - meaning don't unshelve it - yet)
- Unshelve Instance-A
- Notice that the 'shelved' image from Instance-A is still in the list of images
- Try to delete the 'shelved' image from Instance-A
- You should see:
409 Conflict: The image cannot be deleted because it has snapshot(s).
- Delete Instance-B
- Try to delete the 'shelved' image from Instance-A again
- This delete operation should now succeed
What would success / a fix look like?
Possible solution: Don't allow deleting an image if it was created in this weird way
Possible solution: Allow deleting such images, but give a better hint to the user about what the problem is