2916 Commits

Author SHA1 Message Date
Jenkins
f5647e35c3 Merge "Make "policy" a mandatory argument for server-group-create" 2016-10-19 10:22:33 +00:00
Jenkins
bd636c8698 Merge "Update docs for instructions on deprecating commands" 2016-10-19 10:22:26 +00:00
Jenkins
00cd7d2a6c Merge "Remove unused helper volume methods in v2 shell" 2016-10-19 10:22:20 +00:00
OpenStack Proposal Bot
0a16d41652 Updated from global requirements
Change-Id: I34f668657bd92584432a34797c2e119718070a21
2016-10-19 03:58:30 +00:00
OpenStack Proposal Bot
33d8a6702a Updated from global requirements
Change-Id: I37cc22c7500883ef44e027aa46dc7a7e4270c597
2016-10-15 00:12:23 +00:00
Jenkins
bef5870783 Merge "Updated from global requirements" 2016-10-14 16:03:23 +00:00
OpenStack Proposal Bot
d161152a23 Updated from global requirements
Change-Id: Iffa460b6af104991dfc218e09bfa02beda9f43cb
2016-10-14 05:44:00 +00:00
Nicolas Simonds
74222a6ddc Make "policy" a mandatory argument for server-group-create
Commit 6f8667990cdb3cd662d51be2403cca5859559f04 removed the deprecated
"--policy" switch, which caused the check for the missing parameter
to quietly stop working correctly.

Make "policy" a mandatory positional parameter and let argparse
figure it out; it has a much better/more helpful error message
anyways.

Closes-Bug: 1632866
Change-Id: I3234c08b1bc8ba263537bb6232280c471457f069
2016-10-13 10:41:45 -07:00
Matt Riedemann
2a622fff47 Update docs for instructions on deprecating commands
The instructions for deprecating commands predated reno
so this change updates them a bit to be current with our
processes now. Also adds a reminder to update the help
text/description of a command to mark it deprecated.

Change-Id: I530399ba9cf6c50bd0dbb06f231aee61466eebd6
2016-10-12 19:12:51 -04:00
Matt Riedemann
199fc67b46 Remove unused helper volume methods in v2 shell
These were probably missed when we removed the volume
proxy code in Newton.

Change-Id: I5b1413ad61404b31d8d3ffb392a314f52381164a
2016-10-12 19:12:51 -04:00
Matt Riedemann
fdc5aa5d5c Remove deprecated commands
There are several commands and options which have been
deprecated, it's now time to clean those up.

flavor-access-list and aggregate-update had options
deprecated in newton, but that's still too new to
remove those yet.

Here is the table of affected commands and the deprecation
commit and initial release with the deprecation.

Command                 Commit          Release
-------                 ------          -------
rename                  1d1e43957       3.3.0
root-password           3bf6f8fe9       2.27.0
add-floating-ip         4f92f7ba0       2.16.0
remove-floating-ip      4f92f7ba0       2.16.0
absolute-limits         bf6fbdb8d       2.25.0
rate-limits             bf6fbdb8d       2.25.0
aggregate-details       bf68a0cf1       3.4.0
endpoints               1f11840dd       3.1.0
credentials             1f11840dd       3.1.0

Note that network resource quota deprecations are not
part of this change as those are impacted by the 2.36
microversion and will be cleaned up later separately.

Change-Id: Id649d16ec2cdeb04bbaf2239a5e813abcca9c65d
2016-10-12 19:12:46 -04:00
jeremyfreudberg
ef3856804d Add timezone disclaimer to docstring
Novice users may be tempted to pass in values such as
datetime.datetime.now() as a parameter when querying for
usage. Adding a disclaimer to the type hints that inputs
are interpreted as UTC may help avoid this mistake.

Change-Id: Iad34c15f98538fd12215397cb2d9391189f99f79
2016-10-10 11:41:56 -04:00
Andreas Jaeger
4c1dab99e3 Enable release notes translation
Releasenote translation publishing is being prepared. 'locale_dirs'
needs to be defined in conf.py to generate translated version of the
release notes.

Note that this repository might not get translated release notes - or
no translations at all - but we add the entry here nevertheless to
prepare for it.

Change-Id: Ic73a5d161244396297c9d4f72ae4c586e7f81cf8
2016-10-06 20:51:41 +02:00
Jamie Lennox
e88afc046b Clean up requests-mock usage
In line with other clients testing we've found that having the
requests-mock fixture at self.requests can be misleading for new people
as it looks like you're calling requests itself.

Also make use of some of the new features of requests-mock like query
parsing, json handling, method names.

Change-Id: Id61b88c53478d49f91c3f880ed5b90d638051ba0
2016-10-05 06:53:05 +11:00
Jamie Lennox
749fee3346 Replace requests mocking with requests-mock
The novaclient tests are broken with the master (unreleased) branch of
requests. This is because most of the mocking that novaclient does with
requests in insufficient.

Requests-mock is for exactly this purpose and is already widely used in
novaclient so replace using mock with requests-mock where appropriate.

Closes-Bug: #1630157
Change-Id: Ie91daeb5f0c241eb83b77c04ac1b12e431d6671c
2016-10-05 06:53:05 +11:00
OpenStack Proposal Bot
cad8f803bf Updated from global requirements
Change-Id: I124d355c4c98369ecdc75b825f7ef72d7cd249c7
2016-09-30 20:06:05 +00:00
OpenStack Proposal Bot
8e28309859 Updated from global requirements
Change-Id: I895c335fecaae34cda7cbb105a4a6907a0d7de47
2016-09-28 17:00:49 +00:00
Jenkins
e6897224f9 Merge "Fix incorrect output of "nova show" for long user data" 2016-09-27 22:27:14 +00:00
OpenStack Proposal Bot
c26f0f5861 Updated from global requirements
Change-Id: Iec0c4fbf6e2be419dc52fbd9144555050e0a25df
2016-09-27 10:07:32 +00:00
OpenStack Proposal Bot
7592a6e4d1 Updated from global requirements
Change-Id: Ieeafa78a52caf6d91ade096853a430761488ebb5
2016-09-26 04:27:06 +00:00
OpenStack Proposal Bot
c0e7785427 Updated from global requirements
Change-Id: Ia1790ce87fec388aa594394e0867c82e62af3e4e
2016-09-21 06:15:23 +00:00
Jenkins
707105db8a Merge "Fix 'UnicodeEncodeError' for unicode values" 2016-09-15 13:54:33 +00:00
Jenkins
97435a62fe Merge "Update reno for stable/newton" 2016-09-07 23:42:12 +00:00
Doug Hellmann
e02c08dd4f Update reno for stable/newton
In order to support automatically updating the release notes when we
create stable branches, we want the pages to be in a standard order.
This patch updates the order to be reverse chronological, so the most
recent notes appear at the top.

Change-Id: I9a79d95953acdb94b676020a91627b8da4964608
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2016-09-07 17:12:36 -04:00
vnathan
42f2170424 Fix incorrect output of "nova show" for long user data
New argument "--wrap" is added for "nova show" command to wrap
the output. The default wrap length is set to 0 i.e. no wrap.
Usage: nova show --wrap 80 <server-id>

closes-bug: 1616415

Change-Id: I7f4869d743f7bf9ff653183a5767134c796c440a
2016-09-04 12:37:33 +05:30
Bin Zhou
f3fbebdba6 Modify use of assertTrue(A in B)
Developers should use assertIn(A, B) instead of assertTrue(A in B ).

TrivialFix

Change-Id: Iae5f990574a4198178de238138731df90d27063b
2016-09-02 12:50:28 +08:00
OpenStack Proposal Bot
f628849d38 Updated from global requirements
Change-Id: Idb0290aa6bee28e258966824da0e8751c5b09318
2016-08-31 03:09:56 +00:00
Jenkins
25117fa866 Merge "Add support for v2.37 and auto-allocated networking" 2016-08-30 22:28:26 +00:00
Matt Riedemann
c915a0267d Fix test_trigger_crash_dump_in_locked_state_nonadmin test
Patch 2a70e9688151588347664badbac5d0a59ef0f95c in the server
changed the error message that comes back in the case of a locked
server which breaks this test. The test is unnecessarily rigid in
it's assertion, we should just be checking that we get a 409
back, not what the actual error message is, which is prone to change.

Change-Id: I1fd64953e671c6c7fe1068a9c30f5a077712a9fb
Closes-Bug: #1618561
2016-08-30 13:33:02 -04:00
bhagyashris
d8c07006dd Fix 'UnicodeEncodeError' for unicode values
Used '%' instead of format() because "%" formatting operation
returns a unicode string for both unicode and non-unicode
format strings.

Encoded the exception error message in novaclient.shell.main and
novaclient.utils.do_action_on_many method to avoid
"UnicodeEncodeError" and print valid message.

NOTE:
Not used u'{0}.format(<str>) because in python 3 everything
is unicode so no need to add explicit 'u' to format string.

Closes-Bug: #1403379
Change-Id: I13f1ef2e1b41299b417cad3759a5cda241890df7
2016-08-30 15:30:16 +05:30
Thiago Paiva
f7dc91dc11 Fixes TypeError on Client instantiation
When instantiating novaclient with kwargs or named attributes, the 'password'
field is duplicated due to an overwrite on the __init__ method of Client v2.
This patch pops out the password field when it's passed and no api_key is
provided.

Co-Authored-By: Pavel Kholkin <pkholkin@mirantis.com>

Closes-bug: #1511417

Change-Id: Id8310eccef5f0f9a2983e25dd35541d1eb0efe86
2016-08-26 11:41:12 +03:00
Jenkins
ef5dc3211d Merge "[functional] Do not discover same resources for every test" 2016-08-25 12:00:49 +00:00
OpenStack Proposal Bot
8ebf85922f Updated from global requirements
Change-Id: Iac1df9df01d8ad6a60facf5a4bde2fb040b3ba0d
2016-08-25 05:05:16 +00:00
Jenkins
a46c7fdc1b Merge "Replace functions 'Dict.get' and 'del' with 'Dict.pop'" 2016-08-24 20:30:47 +00:00
Jenkins
e283d415e2 Merge "Updated from global requirements" 2016-08-24 17:47:13 +00:00
OpenStack Proposal Bot
7d72ed2d23 Updated from global requirements
Change-Id: I999506490e98f447503340a383c7ee73da6083f1
2016-08-24 13:35:52 +00:00
bhagyashris
744c9b6ada Replace functions 'Dict.get' and 'del' with 'Dict.pop'
Refactoring code: Making 'kwargs' dict to use single instruction: pop()
rather than two instructions: get() and del, giving the codes a format
that carries through.

TrivialFix

Change-Id: Icaf4a57314a8fe48f51993d7b32a1671fec40f31
2016-08-24 11:56:56 +05:30
bhagyashris
8751475a25 Removed unused 'install_venv' module
TrivialFix

Change-Id: I022ca5831e9e4d66b1cc2d6f895a1ad709fedefb
2016-08-24 11:40:31 +05:30
Andrey Kurilin
a14e30e0ec [functional] Do not discover same resources for every test
Let's discover images, flavors and networks once per test process and store
it in global variable

Change-Id: Ife5133e541a4355f308a21658c7fcf4266f78091
2016-08-22 17:39:26 +03:00
Ukesh Kumar Vasudevan
3b834f25c1 functional tests fail if cirros image not exist
The functional tests are looking for a cirros-*uec image and
if that isn't found they fail:

In the function novaclient/tests/functional/base.py:pick_image,
images variable is a generator object which doesn't have
'__getitem__' attribute and so the functional test is failing.

Change-Id: I32b05ff6f2c7501eff04fa9f180eecf3099389ab
Closes-Bug: 1615594
2016-08-22 17:13:00 +05:30
Jenkins
e71b5369e9 Merge "[functional] Skip tests if API doesn't support microversion" 2016-08-22 01:08:44 +00:00
Jenkins
1b6cc4a6bc Merge "Cap image API deprecated methods at 2.35" 2016-08-21 22:14:21 +00:00
Jenkins
a03d163850 Merge "Cap baremetal python APIs at 2.35" 2016-08-21 22:07:41 +00:00
Jenkins
34482bb0e4 Merge "Updated from global requirements" 2016-08-21 22:07:36 +00:00
Jenkins
95bf36c0c0 Merge "Pick first image if can't find the specific image" 2016-08-21 22:07:20 +00:00
OpenStack Proposal Bot
7a2c412dd3 Updated from global requirements
Change-Id: Iee9ace66d3e1c0199c0746d68b2d16c8d102361c
2016-08-21 00:10:05 +00:00
Ukesh Kumar Vasudevan
01de5a9f68 Pick first image if can't find the specific image
In pick_image method to just pick the first image it finds
if it can't find the specific cirros-*uec image.

Also look for the -disk.img since devstack is changing
the default image in:

Id65ebae73b28da7185cb349b714b659af51ef77f

Change-Id: I0e4c38a9e0ae25a922f6b0e09f3f2531f49c88c9
Closes-Bug: 1614118
2016-08-20 08:38:35 -04:00
Matt Riedemann
030ce53d4e Add support for v2.37 and auto-allocated networking
This adds support for the v2.37 microversion. The networks
part of the server create request is required in this
microversion so if nothing is specified for --nic arguments
on the command line we default to 'auto' for backward
compatibility in the CLI.

Part of blueprint get-me-a-network

Change-Id: I6636ddcd3be7bf393d2d69cc6c1ba5c7d65ff674
2016-08-19 21:32:52 -04:00
Jenkins
84d86d3f3c Merge "Deprecate all the nova-network functions in the python API" 2016-08-19 22:49:49 +00:00
Jenkins
296a3c0519 Merge "Deprecate network-* commands and clamp to microversion 2.35" 2016-08-19 22:49:31 +00:00