Current hacking version is incompatible with the one in the
global requirements. Match the hacking module version and made the
necessary changes to pass the tests.
Change-Id: Ie6b13a4ea112084d4c50dc27f97329dfad5777a1
This commit adds support for getting a list of ports, chassis, ports
associated with a node and nodes associated with a chassis with all
attributes, to both the client and the shell CLI.
Closes-Bug: #1366866
Change-Id: If1941de66d70cdbcc3f31cefdbcd4f634e6ce24e
These arguments are using for sorting the result on the server.
Small refactoring was conducted to seperate processing of
common arguments for all lists into the utility function.
Change-Id: I33be1fcecc665c8f2207e53b24ff47954d80dc60
Closes-Bug: #1339731
This patch removes aliases in `ironicclient.common.utils` and starts
to use directly `arg` and `env` functions from common code.
Change-Id: Ied396b767e623fbcbf0c7a32326be7b64132b3e1
While not strictly necessary for files containing only ASCII
characters, adding a line with "coding: utf-8" can guard against
future SyntaxError's in case someone inserts a Unicode literal.
This commit adds such lines to all .py files. The syntax used by this
commit works with Python (of course). It also works with Emacs, which
will recognize the special "-*-" marker and use the "coding" variable
to correctly decode the file, even in an environment where UTF-8 is
not the default file encoding.
Existing coding lines were normalized to match the new lines added.
Partial-bug: #1325193
Change-Id: I58bf93fea711fd25890356a397e594bd820c99e3
This patch:
- removes unused method `common.utils:pretty_choice_list`;
- removes unused method `common.utils:find_resource`;
- removes unused method `common.utils:exit`;
- adds alias to `cliutils:args` in `common.utils`;
- adds alias to `cliutils:env` in `common.utils`;
- reuses method `print_list` from `cliutils`;
- reuses method `print_dict` from `cliutils`.
Related to blueprint common-client-library-2
Change-Id: I42318c6947509d4338309d03e722d822182bbc5d
Module `ironicclient.exc` contains exceptions which equal to exceptions
from oslo common code.
This patch:
- sync latest code of `apiclient.exceptions`(hash of last commit in oslo
related to apiclient.exceptions: 3570f44d5ccf52c59cc586bed1446b874fc3c07c)
- reuses exceptions from common code
- removes needless exceptions from `ironicclient.exc`
Related to bp common-client-library-2
Change-Id: I784007f36dd6a63fc4c77e0d0f0f000e05eb792f
The method 'string_to_bool' in utils is not used.
Furthermore, if we need this method in the future,
we should use 'bool_from_string' from oslo cliutils
to replace it.
partially implements blueprint common-client-library-2
Change-Id: I82af6e358d7082222fe7a09c8f27351189a82fbc
There are some exception messages in common/utils.py and shell.py that
does not support i18n, this patch update the code to support it.
Change-Id: I836b892075333d48e4d1591986fec1362c84fc61
Partial-bug: #1240402
The ironic client was trying to convert unicode strings received from the
API to ascii causing it to fail, this patch will correct it.
Change-Id: I8765abb188f758f982807a38f5d291fbc2be0da9
Closes-Bug: #1247156
In order to make the code more flexible and cleaner when testing (and
debugging) the print_*() functions can now redirect the output to a
different output file.
Change-Id: I34779220d80e037bdfe9e528ffad5187ff109ceb
In Python 3.3, hash randomization is enabled by default. It causes the
iteration order of dicts and sets to be unpredictable and differ
across Python runs.
Partial implement: blueprint py33-support
Change-Id: I739bd9ee1cc10dc01d28efb9a4d2b840bc374d63
Splitting v1/shell.py into one file per resource makes the code more
organized and in the long run helps to improve code readability.
Change-Id: Ia57019548158ffe33a1eca444405107caa327936