summaryrefslogtreecommitdiffstats
path: root/nova/api
diff options
context:
space:
mode:
authorjaypipes@gmail.com <>2011-01-19 22:46:31 +0000
committerTarmac <>2011-01-19 22:46:31 +0000
commit97d9b426f80544dd6cc82f5753783d2bf8f3957f (patch)
tree20e8c2a5930106bbbda88ce02733120a54eb29e5 /nova/api
parentc25a105ead4cd571a1089d2dabf9f338afdd4784 (diff)
parent2f4e7b732d5cafd09a5a73cbc01583503b8ba105 (diff)
downloadnova-97d9b426f80544dd6cc82f5753783d2bf8f3957f.tar.gz
nova-97d9b426f80544dd6cc82f5753783d2bf8f3957f.tar.xz
nova-97d9b426f80544dd6cc82f5753783d2bf8f3957f.zip
Fixes for bugs:
* Bug #704422: nova-direct-api: AttributeError: 'module' object has no attribute 'ComputeAPI' * Bug #704424: bin/stack: AttributeError: port * Bug #704447: bin/stack: urllib2.HTTPError when issuing reflection request
Diffstat (limited to 'nova/api')
-rw-r--r--nova/api/direct.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/nova/api/direct.py b/nova/api/direct.py
index 509ab3ae0..208b6d086 100644
--- a/nova/api/direct.py
+++ b/nova/api/direct.py
@@ -142,9 +142,15 @@ class Reflection(object):
if argspec[2]:
args_out.insert(0, ('**%s' % argspec[2],))
+ if f.__doc__:
+ short_doc = f.__doc__.split('\n')[0]
+ doc = f.__doc__
+ else:
+ short_doc = doc = _('not available')
+
methods['/%s/%s' % (route, k)] = {
- 'short_doc': f.__doc__.split('\n')[0],
- 'doc': f.__doc__,
+ 'short_doc': short_doc,
+ 'doc': doc,
'name': k,
'args': list(reversed(args_out))}