fix pep8 errors under python 3
Under python 3 'print' is a function, and the linter does not like having a space between the function name and the paren indicating the call. Remove the space. The builtin 'file' is removed under python 3. Replace its use with 'open', which is available on both python 2 and 3. Change-Id: Ib8522d8ab1974a4ba3e407ffbe449e2f5fc9471a Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This commit is contained in:
parent
f40833754c
commit
2ee0583763
|
@ -175,7 +175,7 @@ def run_job(conf, storage):
|
|||
pp.field_names = response[0]
|
||||
for i in response[1]:
|
||||
pp.add_row(i)
|
||||
print (pp)
|
||||
print(pp)
|
||||
else:
|
||||
return
|
||||
|
||||
|
|
|
@ -153,7 +153,7 @@ class RestoreOs(object):
|
|||
msg = "Failed to open image file {}".format(image_file)
|
||||
LOG.error(msg)
|
||||
raise BaseException(msg)
|
||||
info = json.load(file(metadata_file))
|
||||
info = json.load(open(metadata_file, 'r'))
|
||||
image = self.client_manager.create_image(
|
||||
name="restore_{}".format(path),
|
||||
container_format="bare",
|
||||
|
|
Loading…
Reference in New Issue