summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Washenberger <mark.washenberger@rackspace.com>2011-03-06 10:41:24 -0500
committerMark Washenberger <mark.washenberger@rackspace.com>2011-03-06 10:41:24 -0500
commit7af17cbef6f3e1c5b052133e40e0edbd8ca9ffb3 (patch)
tree0cc8fd497fb0d61a736ff43c30465a459d0790ec
parent10668b87f46a1fb5d039f6e7d7a7a55b89d7602a (diff)
downloadnova-7af17cbef6f3e1c5b052133e40e0edbd8ca9ffb3.tar.gz
nova-7af17cbef6f3e1c5b052133e40e0edbd8ca9ffb3.tar.xz
nova-7af17cbef6f3e1c5b052133e40e0edbd8ca9ffb3.zip
select cleanups
-rw-r--r--nova/api/openstack/servers.py2
-rw-r--r--nova/quota.py14
-rw-r--r--nova/virt/xenapi/vmops.py2
3 files changed, 8 insertions, 10 deletions
diff --git a/nova/api/openstack/servers.py b/nova/api/openstack/servers.py
index 7c620dbc6..93f504f91 100644
--- a/nova/api/openstack/servers.py
+++ b/nova/api/openstack/servers.py
@@ -153,7 +153,7 @@ class Controller(wsgi.Controller):
try:
path = item['path']
contents = item['contents']
- except KeyError, key:
+ except KeyError as key:
expl = 'Bad personality format: missing %s' % key
raise exc.HTTPBadRequest(explanation=expl)
except TypeError:
diff --git a/nova/quota.py b/nova/quota.py
index 4b777624c..1d79f9ef2 100644
--- a/nova/quota.py
+++ b/nova/quota.py
@@ -46,14 +46,12 @@ flags.DEFINE_integer('quota_personality_max_path_bytes', 255,
def get_quota(context, project_id):
- rval = {
- 'instances': FLAGS.quota_instances,
- 'cores': FLAGS.quota_cores,
- 'volumes': FLAGS.quota_volumes,
- 'gigabytes': FLAGS.quota_gigabytes,
- 'floating_ips': FLAGS.quota_floating_ips,
- 'metadata_items': FLAGS.quota_metadata_items,
- }
+ rval = {'instances': FLAGS.quota_instances,
+ 'cores': FLAGS.quota_cores,
+ 'volumes': FLAGS.quota_volumes,
+ 'gigabytes': FLAGS.quota_gigabytes,
+ 'floating_ips': FLAGS.quota_floating_ips,
+ 'metadata_items': FLAGS.quota_metadata_items}
try:
quota = db.quota_get(context, project_id)
diff --git a/nova/virt/xenapi/vmops.py b/nova/virt/xenapi/vmops.py
index 89d58a664..cf4bedaa9 100644
--- a/nova/virt/xenapi/vmops.py
+++ b/nova/virt/xenapi/vmops.py
@@ -316,7 +316,7 @@ class VMOps(object):
def inject_file(self, instance, path, contents):
"""Write a file to the VM instance. The path to which it is to be
- written and the contents of the file need to be supplied; both should
+ written and the contents of the file need to be supplied; both will
be base64-encoded to prevent errors with non-ASCII characters being
transmitted. If the agent does not support file injection, or the user
has disabled it, a NotImplementedError will be raised.