Merge "build.py: fix pep8 warnings"

This commit is contained in:
Zuul 2019-09-19 08:46:10 +00:00 committed by Gerrit Code Review
commit 40d285e9fb
1 changed files with 6 additions and 6 deletions

View File

@ -316,8 +316,8 @@ class PushTask(DockerTask):
self.logger.exception('Unknown error when pushing')
image.status = STATUS_PUSH_ERROR
finally:
if (image.status not in STATUS_ERRORS
and image.status != STATUS_UNPROCESSED):
if (image.status not in STATUS_ERRORS and
image.status != STATUS_UNPROCESSED):
self.logger.info('Pushed successfully')
self.success = True
else:
@ -748,10 +748,10 @@ class KollaWorker(object):
self.dc = docker.APIClient(version='auto', **docker_kwargs)
except docker.errors.DockerException as e:
self.dc = None
if not (conf.template_only
or conf.save_dependency
or conf.list_images
or conf.list_dependencies):
if not (conf.template_only or
conf.save_dependency or
conf.list_images or
conf.list_dependencies):
LOG.error("Unable to connect to Docker, exiting")
LOG.info("Exception caught: {0}".format(e))
sys.exit(1)