From 8779b070ae19d8813e8fc14f17183c9ccf47a04e Mon Sep 17 00:00:00 2001 From: ckji Date: Thu, 23 Mar 2017 10:37:23 +0800 Subject: [PATCH] Fix some docstring syntax error TrivialFix Ref: http://www.sphinx-doc.org/en/stable/domains.html#info-field-lists Change-Id: Ibb83aa478a4e9b6d488105728a8dc15a557339f4 --- tacker/api/extensions.py | 2 +- tacker/api/v1/attributes.py | 4 ++-- tacker/common/config.py | 4 ++-- tacker/common/utils.py | 4 ++-- tacker/manager.py | 4 ++-- tacker/nfvo/nfvo_plugin.py | 2 +- tacker/wsgi.py | 2 +- 7 files changed, 11 insertions(+), 11 deletions(-) diff --git a/tacker/api/extensions.py b/tacker/api/extensions.py index 1e3230ebd..6deca73c7 100644 --- a/tacker/api/extensions.py +++ b/tacker/api/extensions.py @@ -452,7 +452,7 @@ class ExtensionManager(object): def extend_resources(self, version, attr_map): """Extend resources with additional resources or attributes. - :param: attr_map, the existing mapping from resource name to + :param attr_map: the existing mapping from resource name to attrs definition. After this function, we will extend the attr_map if an extension diff --git a/tacker/api/v1/attributes.py b/tacker/api/v1/attributes.py index 419174f81..65ba181f9 100644 --- a/tacker/api/v1/attributes.py +++ b/tacker/api/v1/attributes.py @@ -493,7 +493,7 @@ def convert_to_int(data): def convert_kvp_str_to_list(data): """Convert a value of the form 'key=value' to ['key', 'value']. - :raises: n_exc.InvalidInput if any of the strings are malformed + :raises n_exc.InvalidInput: if any of the strings are malformed (e.g. do not contain a key). """ kvp = [x.strip() for x in data.split('=', 1)] @@ -506,7 +506,7 @@ def convert_kvp_str_to_list(data): def convert_kvp_list_to_dict(kvp_list): """Convert a list of 'key=value' strings to a dict. - :raises: n_exc.InvalidInput if any of the strings are malformed + :raises n_exc.InvalidInput: if any of the strings are malformed (e.g. do not contain a key) or if any of the keys appear more than once. """ diff --git a/tacker/common/config.py b/tacker/common/config.py index ecb277d89..2430d8bbd 100644 --- a/tacker/common/config.py +++ b/tacker/common/config.py @@ -117,8 +117,8 @@ def load_paste_app(app_name): """Builds and returns a WSGI app from a paste config file. :param app_name: Name of the application to load - :raises ConfigFilesNotFoundError when config file cannot be located - :raises RuntimeError when application cannot be loaded from config file + :raises ConfigFilesNotFoundError: when config file cannot be located + :raises RuntimeError: when application cannot be loaded from config file """ config_path = cfg.CONF.find_file(cfg.CONF.api_paste_config) diff --git a/tacker/common/utils.py b/tacker/common/utils.py index ddf61f200..f7e7e7ece 100644 --- a/tacker/common/utils.py +++ b/tacker/common/utils.py @@ -178,8 +178,8 @@ def load_class_by_alias_or_classname(namespace, name): Load class using the stevedore driver manager :param namespace: namespace where the alias is defined :param name: alias or class name of the class to be loaded - :returns class if calls can be loaded - :raises ImportError if class cannot be loaded + :returns: class if calls can be loaded + :raises ImportError: if class cannot be loaded """ if not name: diff --git a/tacker/manager.py b/tacker/manager.py index 3f627ea8a..f11ffcdce 100644 --- a/tacker/manager.py +++ b/tacker/manager.py @@ -108,8 +108,8 @@ class TackerManager(object): Load class using stevedore alias or the class name :param namespace: namespace where alias is defined :param plugin_provider: plugin alias or class name - :returns plugin that is loaded - :raises ImportError if fails to load plugin + :returns: plugin that is loaded + :raises ImportError: if fails to load plugin """ try: diff --git a/tacker/nfvo/nfvo_plugin.py b/tacker/nfvo/nfvo_plugin.py index 5c2741ab0..faefb1ada 100644 --- a/tacker/nfvo/nfvo_plugin.py +++ b/tacker/nfvo/nfvo_plugin.py @@ -517,7 +517,7 @@ class NfvoPlugin(nfvo_db.NfvoPluginDb, vnffg_db.VnffgPluginDbMixin, def create_ns(self, context, ns): """Create NS and corresponding VNFs. - :param ns ns dict which contains nsd_id and attributes + :param ns: ns dict which contains nsd_id and attributes This method has 3 steps: step-1: substitute all get_input params to its corresponding values step-2: Build params dict for substitution mappings case through which diff --git a/tacker/wsgi.py b/tacker/wsgi.py index d8c5cd6b1..35b0d489d 100644 --- a/tacker/wsgi.py +++ b/tacker/wsgi.py @@ -511,7 +511,7 @@ class RequestDeserializer(object): """Extract necessary pieces of the request. :param request: Request object - :returns tuple of expected controller action name, dictionary of + :returns: tuple of expected controller action name, dictionary of keyword arguments to pass to the controller, the expected content type of the response