summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2015-07-24 19:51:30 +0000
committerGerrit Code Review <review@openstack.org>2015-07-24 19:51:30 +0000
commit55d9eba0937944119e6209c85005980c7297d123 (patch)
treecabac6840cde898651a0393deb60b6b36e370e82 /doc
parent46cc7d12ad202184917822dfa16dc66d066c8538 (diff)
parentb3335b3474e559d8afb0b7f86796fbb68a0687a8 (diff)
downloadpython-openstackclient-55d9eba0937944119e6209c85005980c7297d123.tar.gz
Merge "Do not set default versions in parsed args"
Diffstat (limited to 'doc')
-rw-r--r--doc/source/backwards-incompatible.rst15
-rw-r--r--doc/source/plugins.rst7
2 files changed, 17 insertions, 5 deletions
diff --git a/doc/source/backwards-incompatible.rst b/doc/source/backwards-incompatible.rst
index c511852f..e89cc3a6 100644
--- a/doc/source/backwards-incompatible.rst
+++ b/doc/source/backwards-incompatible.rst
@@ -75,6 +75,21 @@ List of Backwards Incompatible Changes
* Bug: https://bugs.launchpad.net/python-openstackclient/+bug/472613
* Commit: https://review.openstack.org/#/c/194654/
+6. Plugin interface change for default API versions
+
+ Previously, the default version was set in the parsed arguments,
+ but this makes it impossible to tell what has been passed in at the
+ command line, set in an environment variable or is just the default.
+ Now, the module should have a DEFAULT_API_VERSION that contains the
+ value and it will be set after command line argument, environment
+ and OCC file processing.
+
+ * In favor of: DEFAULT_API_VERSION
+ * As of: 1.2.1
+ * Removed in: NA
+ * Bug: https://bugs.launchpad.net/python-openstackclient/+bug/1453229
+ * Commit: https://review.openstack.org/#/c/181514/
+
For Developers
==============
diff --git a/doc/source/plugins.rst b/doc/source/plugins.rst
index d603e102..17a508fe 100644
--- a/doc/source/plugins.rst
+++ b/doc/source/plugins.rst
@@ -83,7 +83,7 @@ so the version should not contain the leading 'v' character.
.. code-block:: python
- DEFAULT_OSCPLUGIN_API_VERSION = '1'
+ DEFAULT_API_VERSION = '1'
# Required by the OSC plugin interface
API_NAME = 'oscplugin'
@@ -123,10 +123,7 @@ so the version should not contain the leading 'v' character.
parser.add_argument(
'--os-oscplugin-api-version',
metavar='<oscplugin-api-version>',
- default=utils.env(
- 'OS_OSCPLUGIN_API_VERSION',
- default=DEFAULT_OSCPLUGIN_API_VERSION),
help='OSC Plugin API version, default=' +
- DEFAULT_OSCPLUGIN_API_VERSION +
+ DEFAULT_API_VERSION +
' (Env: OS_OSCPLUGIN_API_VERSION)')
return parser