| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.
Change-Id: I805f5a4a901e410492c543c1857943ffd744ea35
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, during the ironic shell client construction, if only
os_auth_token and endpoint arguments are passed, custom
HTTPClient class based on requests' sessions is used. This is
unnecessary, as there is admin_token auth type in keystoneauth
that does basically the same, eliminating the need for our
custom implementation. Apart from that, there is a none auth,
which requires only passing the desired endpoint to use, so we
can use it too without having to specify fake token strings
anymore. Let's use these auth methods instead and deprecate
HTTPClient.
Also this patch deprecates a bunch of arguments to client.get_client
function, changing them to the standard keystoneauth naming.
DocImpact
Story: 1696791
Task: 11836
Depends-On: https://review.openstack.org/559116
Change-Id: Ifc7b45d047c8882a41021e1604b74d17eac2e6e8
|
| |
|
|
|
|
|
|
|
|
|
| |
Now the default of OSC is the negotiated maximum version understood
by both the server and the client. The value of "1" is now equivalent
to "latest" as well.
This change also cleans up unit tests for the OSC plugin.
Change-Id: I489fee937a356b523eb35379dce3631195132fe5
Closes-Bug: #1671145
|
| |
|
|
|
|
|
|
|
|
| |
Currently --os-baremetal-api-version=latest results in the latest known API
version being send to the server. This does not work, if the server is older
than the client. This patch enables the version to be downgraded to the latest
server version in this case.
Change-Id: I3c48b3dbfef9ff3ee6001d27c8e1eb04341e98ec
Partial-Bug: #1671145
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Enable the following off-by-default checks:
* [H204] Use assert(Not)Equal to check for equality.
* [H205] Use assert(Greater|Less)(Equal) for comparison.
* [H210] Require ‘autospec’, ‘spec’, or ‘spec_set’ in
mock.patch/mock.patch.object calls
Fix code that failed [H205] and [H210]
Change-Id: I7a553e7d40e328f37757fb504a098776cb9bf97c
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allow OS_BAREMETAL_API_VERSION=latest to work. If
OS_BAREMETAL_API_VERSION=latest then convert to the latest version and
set that as the 'default' value for the os_baremetal_api_version
value.
Remove the LOG.debug() message about setting to latest as the message
never appears in the logfile. As tested with:
$ openstack --debug --log-file log.txt baremetal node list --os-baremetal-api-version latest
Also it was set to always log the message.
Change-Id: Idc3de8ae55e8267342633668a06d18b45c9e5f0a
Closes-Bug: #1712935
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
At the Pike PTG, an issue was brought up regarding the use of an old API
version in the ironic OpenStack CLI plugin. [0]
It was suggested that we begin printing a warning whenever the default
OSC API version is used and later default to using the latest API
version when --os-baremetal-api-version is unspecified.
This patch adds the warning discussed above.
[0] https://etherpad.openstack.org/p/ironic-pike-ptg-operations L30
Co-Authored-By: Dmitry Tantsur <dtantsur@redhat.com>
Partial-Bug: #1671145
Change-Id: I0cf4e737595405b7f9beff76a72ffd26e07e6277
|
| |
|
|
|
|
|
|
|
|
|
| |
For OSC commands, the --os-baremetal-api-version
optional argument does not have the value 'latest'.
Unlike the ironic CLI osc_lib does not support passing
'latest', so this is replaced by latest known API version
which is used in requests to the Bare Metal service.
Change-Id: Id98d1ab4b6dd1fdfb41d3a4fdd384baf75e69d6f
Closes-Bug: #1657502
|
|
|
To achieve this, we pass endpoint argument to the Client constructor,
which is then set as endpoint_override with version stripped from it.
Closes-Bug: #1619229
Change-Id: Idad0e6816ce8a5a0542e624cfe81f56c0ff2461c
|