summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSandy Walsh <sandy.walsh@rackspace.com>2011-06-21 12:19:01 -0700
committerSandy Walsh <sandy.walsh@rackspace.com>2011-06-21 12:19:01 -0700
commitd99b17895747959e332e5645aedd0a2ddc0e21da (patch)
tree27d37a80db6814fb4f7daaf25f0b476f9f866cb1
parenta1ee8e591e157a23390b1622b9c313da08ae9130 (diff)
pep8
-rw-r--r--nova/compute/api.py4
-rw-r--r--nova/scheduler/api.py3
-rw-r--r--nova/scheduler/zone_aware_scheduler.py2
-rw-r--r--nova/tests/scheduler/test_zone_aware_scheduler.py2
4 files changed, 6 insertions, 5 deletions
diff --git a/nova/compute/api.py b/nova/compute/api.py
index 0791bab51..1c001a8fc 100644
--- a/nova/compute/api.py
+++ b/nova/compute/api.py
@@ -241,7 +241,7 @@ class API(base.Base):
"""Create an entry in the DB for this new instance,
including any related table updates (such as security group,
MAC address, etc).
-
+
This will called by create() in the majority of situations,
but create_all_at_once() style Schedulers may initiate the call.
If you are changing this method, be sure to update both
@@ -270,7 +270,7 @@ class API(base.Base):
self.db.instance_add_security_group(elevated,
instance_id,
security_group_id)
-
+
block_device_mapping = block_device_mapping or []
# NOTE(yamahata)
# tell vm driver to attach volume at boot time by updating
diff --git a/nova/scheduler/api.py b/nova/scheduler/api.py
index 733cd3dfa..f2ffcbc1f 100644
--- a/nova/scheduler/api.py
+++ b/nova/scheduler/api.py
@@ -114,7 +114,8 @@ def _process(func, zone):
def call_zone_method(context, method_name, errors_to_ignore=None,
- novaclient_collection_name='zones', zones=None, *args, **kwargs):
+ novaclient_collection_name='zones', zones=None,
+ *args, **kwargs):
"""Returns a list of (zone, call_result) objects."""
if not isinstance(errors_to_ignore, (list, tuple)):
# This will also handle the default None
diff --git a/nova/scheduler/zone_aware_scheduler.py b/nova/scheduler/zone_aware_scheduler.py
index c810318db..dcfef6af5 100644
--- a/nova/scheduler/zone_aware_scheduler.py
+++ b/nova/scheduler/zone_aware_scheduler.py
@@ -181,7 +181,7 @@ class ZoneAwareScheduler(driver.Scheduler):
for zone, result in child_results:
if not result:
continue
-
+
for zone_rec in zones:
if zone_rec['api_url'] != zone:
continue
diff --git a/nova/tests/scheduler/test_zone_aware_scheduler.py b/nova/tests/scheduler/test_zone_aware_scheduler.py
index 57fddb041..75c94e477 100644
--- a/nova/tests/scheduler/test_zone_aware_scheduler.py
+++ b/nova/tests/scheduler/test_zone_aware_scheduler.py
@@ -173,7 +173,7 @@ class ZoneAwareSchedulerTestCase(test.TestCase):
def setUp(self):
super(ZoneAwareSchedulerTestCase, self).setUp()
self.stubs = stubout.StubOutForTesting()
-
+
def tearDown(self):
self.stubs.UnsetAll()
super(ZoneAwareSchedulerTestCase, self).tearDown()