Merge "Fix message format for VolumeAttachmentNotFound exception"

This commit is contained in:
Jenkins
2017-08-07 23:58:32 +00:00
committed by Gerrit Code Review
2 changed files with 3 additions and 3 deletions

View File

@@ -1859,8 +1859,8 @@ def _attachment_get(context, attachment_id, session=None, read_deleted=False,
.first())
if not result:
msg = _("Unable to find attachment with id: %s"), attachment_id
raise exception.VolumeAttachmentNotFound(msg)
raise exception.VolumeAttachmentNotFound(filter='attachment_id = %s' %
attachment_id)
return result

View File

@@ -339,7 +339,7 @@ class MessageNotFound(NotFound):
class VolumeAttachmentNotFound(NotFound):
message = _("Volume attachment could not be found with "
"filter: %(filter)s .")
"filter: %(filter)s.")
class VolumeMetadataNotFound(NotFound):