summaryrefslogtreecommitdiffstats
path: root/nova/virt
diff options
context:
space:
mode:
authorBrian Waldon <bcwaldon@gmail.com>2012-05-24 06:56:15 -0700
committerBrian Waldon <bcwaldon@gmail.com>2012-05-24 06:59:05 -0700
commit317378f742aafd59d0aaa6c5698bbda57cbfa15a (patch)
tree6903bc2a95296a592a90372d6b0e6122ad5940e4 /nova/virt
parente3d7d3a805355340f27b9626f83eda329f358fda (diff)
Update pep8 dependency to v1.1
The latest release of pep8 adds stricter rules for extraneous whitespace within lines. This patch also addresses these new violations acoss the codebase. Change-Id: Ib7e50281870473df1704ed50868c5c2e26bdb02e
Diffstat (limited to 'nova/virt')
-rw-r--r--nova/virt/baremetal/nodes.py2
-rw-r--r--nova/virt/baremetal/proxy.py6
-rw-r--r--nova/virt/fake.py6
-rw-r--r--nova/virt/libvirt/connection.py8
-rw-r--r--nova/virt/vmwareapi/vmops.py2
-rw-r--r--nova/virt/xenapi/connection.py6
-rw-r--r--nova/virt/xenapi/volume_utils.py2
7 files changed, 16 insertions, 16 deletions
diff --git a/nova/virt/baremetal/nodes.py b/nova/virt/baremetal/nodes.py
index a01bba428..b4f2a50e2 100644
--- a/nova/virt/baremetal/nodes.py
+++ b/nova/virt/baremetal/nodes.py
@@ -34,7 +34,7 @@ FLAGS.register_opts(baremetal_opts)
def get_baremetal_nodes():
d = FLAGS.baremetal_driver
- if d == 'tilera':
+ if d == 'tilera':
return tilera.get_baremetal_nodes()
elif d == 'fake':
return fake.get_baremetal_nodes()
diff --git a/nova/virt/baremetal/proxy.py b/nova/virt/baremetal/proxy.py
index 274c0ba03..90011f28b 100644
--- a/nova/virt/baremetal/proxy.py
+++ b/nova/virt/baremetal/proxy.py
@@ -666,9 +666,9 @@ class ProxyConnection(driver.ComputeDriver):
#TODO(mdragon): console proxy should be implemented for baremetal,
# in case someone wants to use it.
# For now return fake data.
- return {'address': '127.0.0.1',
- 'username': 'fakeuser',
- 'password': 'fakepassword'}
+ return {'address': '127.0.0.1',
+ 'username': 'fakeuser',
+ 'password': 'fakepassword'}
def refresh_security_group_rules(self, security_group_id):
# Bare metal doesn't currently support security groups
diff --git a/nova/virt/fake.py b/nova/virt/fake.py
index 51ea50879..36cfa54d2 100644
--- a/nova/virt/fake.py
+++ b/nova/virt/fake.py
@@ -225,9 +225,9 @@ class FakeConnection(driver.ComputeDriver):
'port': 6969}
def get_console_pool_info(self, console_type):
- return {'address': '127.0.0.1',
- 'username': 'fakeuser',
- 'password': 'fakepassword'}
+ return {'address': '127.0.0.1',
+ 'username': 'fakeuser',
+ 'password': 'fakepassword'}
def refresh_security_group_rules(self, security_group_id):
return True
diff --git a/nova/virt/libvirt/connection.py b/nova/virt/libvirt/connection.py
index 23429e84d..7e012a87c 100644
--- a/nova/virt/libvirt/connection.py
+++ b/nova/virt/libvirt/connection.py
@@ -1900,7 +1900,7 @@ class LibvirtConnection(driver.ComputeDriver):
else:
avail = (int(m[idx1 + 1]) + int(m[idx2 + 1]) + int(m[idx3 + 1]))
# Convert it to MB
- return self.get_memory_mb_total() - avail / 1024
+ return self.get_memory_mb_total() - avail / 1024
def get_local_gb_used(self):
"""Get the free hdd size(GB) of physical computer.
@@ -2021,9 +2021,9 @@ class LibvirtConnection(driver.ComputeDriver):
#TODO(mdragon): console proxy should be implemented for libvirt,
# in case someone wants to use it with kvm or
# such. For now return fake data.
- return {'address': '127.0.0.1',
- 'username': 'fakeuser',
- 'password': 'fakepassword'}
+ return {'address': '127.0.0.1',
+ 'username': 'fakeuser',
+ 'password': 'fakepassword'}
def refresh_security_group_rules(self, security_group_id):
self.firewall_driver.refresh_security_group_rules(security_group_id)
diff --git a/nova/virt/vmwareapi/vmops.py b/nova/virt/vmwareapi/vmops.py
index f236b6ac9..1e35776fa 100644
--- a/nova/virt/vmwareapi/vmops.py
+++ b/nova/virt/vmwareapi/vmops.py
@@ -793,7 +793,7 @@ class VMWareVMOps(object):
task_info = self._session._call_method(vim_util,
"get_dynamic_property",
search_task, "Task", "info")
- if task_info.state in ['queued', 'running']:
+ if task_info.state in ['queued', 'running']:
time.sleep(2)
continue
break
diff --git a/nova/virt/xenapi/connection.py b/nova/virt/xenapi/connection.py
index 35634ac11..184e34aa4 100644
--- a/nova/virt/xenapi/connection.py
+++ b/nova/virt/xenapi/connection.py
@@ -366,9 +366,9 @@ class XenAPIConnection(driver.ComputeDriver):
def get_console_pool_info(self, console_type):
xs_url = urlparse.urlparse(FLAGS.xenapi_connection_url)
- return {'address': xs_url.netloc,
- 'username': FLAGS.xenapi_connection_username,
- 'password': FLAGS.xenapi_connection_password}
+ return {'address': xs_url.netloc,
+ 'username': FLAGS.xenapi_connection_username,
+ 'password': FLAGS.xenapi_connection_password}
def update_available_resource(self, ctxt, host):
"""Updates compute manager resource info on ComputeNode table.
diff --git a/nova/virt/xenapi/volume_utils.py b/nova/virt/xenapi/volume_utils.py
index 9c207a4cd..e93e1b81e 100644
--- a/nova/virt/xenapi/volume_utils.py
+++ b/nova/virt/xenapi/volume_utils.py
@@ -373,7 +373,7 @@ def _get_target_port(iscsi_string):
"""Retrieve target port"""
if iscsi_string:
return iscsi_string[iscsi_string.find(':') + 1:]
- elif iscsi_string is None or FLAGS.target_port:
+ elif iscsi_string is None or FLAGS.target_port:
return FLAGS.target_port