summaryrefslogtreecommitdiff
path: root/openstackclient/image/v2/image.py
diff options
context:
space:
mode:
authorStephen Finucane <sfinucan@redhat.com>2023-05-08 11:34:37 +0100
committerStephen Finucane <sfinucan@redhat.com>2023-05-10 10:51:30 +0100
commit7ca43885c26d9dd7903e7015c0a31f3486730eea (patch)
treefe4bb785229fe2d904d523a147559a83e6e32411 /openstackclient/image/v2/image.py
parent329296cedd0a64e9f65b080cef749b65256db85b (diff)
downloadpython-openstackclient-7ca43885c26d9dd7903e7015c0a31f3486730eea.tar.gz
Blacken openstackclient.image
Black used with the '-l 79 -S' flags. A future change will ignore this commit in git-blame history by adding a 'git-blame-ignore-revs' file. Change-Id: I6420ec6fd550903b03083b9b1f8391511913c86f Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
Diffstat (limited to 'openstackclient/image/v2/image.py')
-rw-r--r--openstackclient/image/v2/image.py12
1 files changed, 4 insertions, 8 deletions
diff --git a/openstackclient/image/v2/image.py b/openstackclient/image/v2/image.py
index da26e918..8a0066ca 100644
--- a/openstackclient/image/v2/image.py
+++ b/openstackclient/image/v2/image.py
@@ -506,8 +506,8 @@ class CreateImage(command.ShowOne):
raise exceptions.CommandError(msg)
if (
- len(parsed_args.sign_key_path) < 1 or
- len(parsed_args.sign_cert_id) < 1
+ len(parsed_args.sign_key_path) < 1
+ or len(parsed_args.sign_cert_id) < 1
):
msg = _(
"'sign-key-path' and 'sign-cert-id' must both be "
@@ -596,10 +596,7 @@ class CreateImage(command.ShowOne):
)
kwargs = {}
if volume_client.api_version < api_versions.APIVersion('3.1'):
- if (
- parsed_args.visibility or
- parsed_args.is_protected is not None
- ):
+ if parsed_args.visibility or parsed_args.is_protected is not None:
msg = _(
'--os-volume-api-version 3.1 or greater is required '
'to support the --public, --private, --community, '
@@ -618,7 +615,7 @@ class CreateImage(command.ShowOne):
parsed_args.name,
parsed_args.container_format,
parsed_args.disk_format,
- **kwargs
+ **kwargs,
)
info = body['os-volume_upload_image']
try:
@@ -659,7 +656,6 @@ class DeleteImage(command.Command):
return parser
def take_action(self, parsed_args):
-
del_result = 0
image_client = self.app.client_manager.image
for image in parsed_args.images: