Make sure to raise the exception for WSGI and make the delete method's intent more clear
This commit is contained in:
parent
d16fdde528
commit
bb9502ee77
2 changed files with 5 additions and 3 deletions
|
@ -1235,9 +1235,11 @@ def find_or_create_derived_storage(source, transformation_name, preferred_locati
|
||||||
def delete_derived_storage_by_uuid(storage_uuid):
|
def delete_derived_storage_by_uuid(storage_uuid):
|
||||||
try:
|
try:
|
||||||
image_storage = get_storage_by_uuid(storage_uuid)
|
image_storage = get_storage_by_uuid(storage_uuid)
|
||||||
derived_storage = DerivedImageStorage.get(derivative=image_storage)
|
|
||||||
except InvalidImageException:
|
except InvalidImageException:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
try:
|
||||||
|
DerivedImageStorage.get(derivative=image_storage)
|
||||||
except DerivedImageStorage.DoesNotExist:
|
except DerivedImageStorage.DoesNotExist:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,7 @@ class QueueFile(object):
|
||||||
for handler in self._exception_handlers:
|
for handler in self._exception_handlers:
|
||||||
handler(result)
|
handler(result)
|
||||||
|
|
||||||
return
|
raise result
|
||||||
|
|
||||||
self._buffer += result
|
self._buffer += result
|
||||||
self._total_size += len(result)
|
self._total_size += len(result)
|
||||||
|
|
Reference in a new issue