Merge "Fix wrong behavior of parsing plugin service name"
This commit is contained in:
commit
e35c97a4fc
@ -76,7 +76,9 @@ class OpenStackShell(shell.OpenStackShell):
|
|||||||
# Loop through extensions to get API versions
|
# Loop through extensions to get API versions
|
||||||
for mod in clientmanager.PLUGIN_MODULES:
|
for mod in clientmanager.PLUGIN_MODULES:
|
||||||
default_version = getattr(mod, 'DEFAULT_API_VERSION', None)
|
default_version = getattr(mod, 'DEFAULT_API_VERSION', None)
|
||||||
option = mod.API_VERSION_OPTION.replace('os_', '')
|
# Only replace the first instance of "os", some service names will
|
||||||
|
# have "os" in their name, like: "antiddos"
|
||||||
|
option = mod.API_VERSION_OPTION.replace('os_', '', 1)
|
||||||
version_opt = str(self.cloud.config.get(option, default_version))
|
version_opt = str(self.cloud.config.get(option, default_version))
|
||||||
if version_opt:
|
if version_opt:
|
||||||
api = mod.API_NAME
|
api = mod.API_NAME
|
||||||
|
7
releasenotes/notes/bug-1658614-f84a8cece6f2ef8c.yaml
Normal file
7
releasenotes/notes/bug-1658614-f84a8cece6f2ef8c.yaml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- |
|
||||||
|
Fix wrong behavior of parsing plugin service name when the service name end
|
||||||
|
with keyword ``os``, like: antiddos. That cause the service api version
|
||||||
|
specified by users don't work.
|
||||||
|
[Bug `1658614 <https://bugs.launchpad.net/python-openstackclient/+bug/1658614>`_]
|
Loading…
Reference in New Issue
Block a user