Commit Graph

891 Commits

Author SHA1 Message Date
Stuart McLaren 5b9f21b38b Handle 403 forbidden on download
A download of a deactivated image may result in a 403.
The cli should catch this error rather than stack trace.

We also catch other unexpected http responses.

Change-Id: If33fbc3a56cdb02b3ab32a6479a67fff20b4b1a9
Closes-bug: 1523612
2016-02-24 18:31:38 +00:00
Long Quan Sha 44d0b02c67 Fix the download error when the image locations are blank
When the image locations are blank, glance client will get a http response
with no content, glance client should show user no data could be found,
instead of processing the blank response body that will lead to exception.

Glance client will also get a 204 response when an image is in a queued
state (this is true for 'master' and liberty/kilo/juno based servers).

Closes-Bug: #1472449

Co-Authored-by: Stuart McLaren <stuart.mclaren@hp.com>
Change-Id: I5d3d02d6aa7c8dd054cd2933e15b4a26e91afea1
2015-12-07 16:45:01 +00:00
OpenStack Proposal Bot deff84dadf Updated from global requirements
Change-Id: I506809a71c95694252be7c088b3a537b73b851a8
2015-12-06 10:43:38 +00:00
Jenkins c6ff80ffe2 Merge "Fix Resource.__eq__ mismatch semantics of object equal" 2015-12-04 23:43:32 +00:00
Jenkins e1fa2c4478 Merge "Fix tests for image-create" 2015-12-03 13:34:23 +00:00
Jenkins 618dde4c8e Merge "Fix help for image-create" 2015-12-03 08:24:44 +00:00
Jenkins 577cd21832 Merge "Add ordereddict requirement for py26 tests" 2015-12-01 19:08:27 +00:00
Jenkins b36005fd5c Merge "Update set of wanted commands in read-only test" 2015-12-01 15:59:44 +00:00
Jenkins 56311d6e24 Merge "Change man page examples to correlate default v2" 2015-12-01 15:59:26 +00:00
OpenStack Proposal Bot be22b3923b Updated from global requirements
Change-Id: Ie9846e7e22c8fbcadea16ebc5e1c632d4f45786d
2015-12-01 06:09:44 +00:00
Jake Yip 255b10df28 Fix help for image-create
The help for image-create states that --file 'Must be present if images
are not passed to the client via stdin.'

However, doing image-create without --file is a valid operation - it
queues a file to be created.

Change-Id: I8167c6a891fa2540c84e3b888031d90a34a9b5fc
2015-11-30 16:10:43 +00:00
Jake Yip d6b0a5726e Fix tests for image-create
image-create unit tests still checks for obsolete v1 params --location
and --copy-from

remove checking of these params

Closes-bug: 1521044

Change-Id: I75ae1a200ab319b7fb818b4ccfe784af5ef8ff88
2015-11-30 14:41:24 +11:00
Rui Chen 7651b596a3 Fix Resource.__eq__ mismatch semantics of object equal
The __eq__ of apiclient.base.Resource will return True,
if the two objects have same id, even if they have different
other attributes value. The behavior is weird and don't
match the semantics of object equal. The objects that have
different value should be different objects.
Fix this issue and add some test cases in this patch.

Change-Id: I24ba39bf90d727116f256de46241746520efbfee
Closes-Bug: #1499369
2015-11-28 18:15:52 +08:00
Jenkins c4cb6a42ef Merge "Fix typo in 'help' in python-glanceclient" 2015-11-27 17:09:28 +00:00
Kyrylo Romanenko 698f53d241 Update set of wanted commands in read-only test
Nowadays Glance supports more subcommands.
Closes-Bug: #1520585

Change-Id: Ic95c26df31dc3bfb4436969e728f7a1a7c50ff0c
2015-11-27 15:58:19 +02:00
Darja Shakhray 8b4f07767b Fix typo in 'help' in python-glanceclient
Fix typo `glance --os-image-api-version 1 helpNone` in help
in python-glanceclient.

Change-Id: I21bd7a7a5809e7c5fca4c8df1275321a9014bc6f
Closes-bug: #1506049
2015-11-27 16:20:14 +03:00
Jenkins 101528ee63 Merge "Ensure that identity token in header is not an unicode string" 2015-11-27 13:09:50 +00:00
Stuart McLaren 8438be77d6 Add ordereddict requirement for py26 tests
Tests which required OrderedDict were failing because Python 2.6 doesn't
have a native OrderedDict implementation.

Change-Id: Id3b0a9126279bf628022dba596d58b9e3ddb2b52
Closes-bug: 1520544
2015-11-27 11:07:17 +00:00
Jenkins af91e2cc0c Merge "Remove self from image-create/image-update" 2015-11-23 18:18:18 +00:00
OpenStack Proposal Bot 784f4fe000 Updated from global requirements
Change-Id: Ib423d76792b0d72853972fc7b769003b76ae989e
2015-11-19 15:52:17 +00:00
Jenkins 22e4e0a5db Merge "Fix 'test_help' for shell client." 2015-11-17 20:35:37 +00:00
Vincent Untz f65ba82268 Ensure that identity token in header is not an unicode string
We need all the headers to be safe strings so they can be joined
together and not become an unicode string in doing so.

This fixes a bug when creating an image with non-ascii characters in the
name.

This is required for python 2.6 compatibility.

Change-Id: I66ebc27edf4ccd8f903399da58705711c372536d
Closes-Bug: 1448080
2015-11-17 18:14:20 +01:00
Erno Kuvaja e2384d0012 Change man page examples to correlate default v2
Changing examples to correlate default behavior (v2 API) rather than
old v1 options.

Change-Id: I13a0d6040bfcd246189e0c1aeadf104ff5eff131
2015-11-17 16:33:33 +00:00
Erno Kuvaja d91210c806 Release Notes for version 1.2.0
1f1934e Add versions list function
bff356e Added reactivate/deactivate image using CLI
dfcb468 Fix the missing help descripiton of "image-create"
8a4cd79 Add documentation for running the functional tests
c7c0754 Updated from global requirements
d6a10f2 Remove unused sphinx Makefile
5a24705 Update docs to recommend KSA instead of KSC
84538d8 Use clouds.yaml from devstack for functional tests
4fb3092 Add translation to v2 shell
6b9133c Import i18n functions directly
8cf2bfc Updated from global requirements
b51634a improve readme contents
ca050ed Add support for setting Accept-Language header
3bd28bf Updated from global requirements
36937bb Use the subcomand parsed args instead of the base
afd1810 Stop trying to send image_size to the server
bf02b04 Support image deletion in batches in v2
a8a7c68 print usage when no argument is specified for python3
77012ee Updated from global requirements
603697a Updated from global requirements
df0f664 Do not use openstack.common.i18n in glance client
abf0381 Added unit tests for 'Unicode support shell client'
1f2fefb Use common identity parameters fro keystone client
c31c136 No auth when token and endpoint are passed
557acb1 Use dictionary literal for dictionary creation
c6addc7 Replace exception_to_str with oslo.utils function
586d401 Change ignore-errors to ignore_errors
05cd0c7 Add period in help message
b8a881f Don't get the image before deleting it
3d3d829 Fix human readable when size is None
19480df Add parsing the endpoint URL
22ce845 Fix Typos in comments
b9eee5e Add check Identity validate when get schemas

Change-Id: If2964135d73b45a11faf03b7dfa6b6f756a1abe0
2015-11-16 15:57:13 +00:00
Jenkins ac56244299 Merge "improve readme contents" 2015-11-14 21:07:20 +00:00
Alexey Galkin 0ac91856ca Fix 'test_help' for shell client.
Added new items in 'wanted_commands'.

Related bug: #1508356

Change-Id: I21ca66d51ace18ac58d33d5d542f805150cb8e4f
2015-11-13 13:06:23 +00:00
wangxiyuan 1f1934eb82 Add versions list function
This patch add a function to query the Glance API versions.

DocImpact

Change-Id: I21eeaee3db4ae23f608b68bb319772ac612975b4
Closes-bug: #1511180
2015-11-10 10:28:32 +08:00
Jenkins 4969251288 Merge "Fix the missing help descripiton of "image-create"" 2015-11-09 13:43:04 +00:00
Jenkins fcd9ab5769 Merge "Use common identity parameters fro keystone client" 2015-11-05 14:50:55 +00:00
Jenkins 20c8d674fb Merge "Added reactivate/deactivate image using CLI" 2015-11-03 18:57:22 +00:00
Darja Shakhray bff356ed73 Added reactivate/deactivate image using CLI
Added commands 'glance image-reactivate image_id'
and 'glance image-deactivate image_id' for
reactivate/deactivate image using CLI

DocImpact

Change-Id: I2c370c6bf6ff664d94d756cc76aaa983fbdb8869
Closes-bug: #1508356
2015-11-02 14:00:38 +00:00
Jenkins 785ced37ae Merge "Add documentation for running the functional tests" 2015-11-02 14:00:17 +00:00
wangxiyuan dfcb468c1d Fix the missing help descripiton of "image-create"
Now, when use "glance help" to show the help message, the description
of 'image-create' is missing.

Change-Id: I748209222c540e0024580dccac850ea465d176b4
Closes-bug: #1510340
2015-10-27 09:20:56 +08:00
Jenkins c0975934c0 Merge "Add translation to v2 shell" 2015-10-22 12:14:18 +00:00
Jenkins b82df59208 Merge "Import i18n functions directly" 2015-10-22 12:13:47 +00:00
Jenkins 297474a734 Merge "Updated from global requirements" 2015-10-21 15:55:46 +00:00
Jenkins e171607dd0 Merge "Remove unused sphinx Makefile" 2015-10-21 14:40:33 +00:00
Jenkins aa7ac86a10 Merge "Update docs to recommend KSA instead of KSC" 2015-10-21 14:39:30 +00:00
Stuart McLaren 8a4cd7916b Add documentation for running the functional tests
Change-Id: I824f6cd2aa988ed1e4025765971161b44993f00a
2015-10-21 13:33:41 +00:00
OpenStack Proposal Bot c7c0754bfc Updated from global requirements
Change-Id: Ie73fb93994a5f83e3b2f035aa9bc10125fce7a9d
2015-10-21 13:27:00 +00:00
Monty Taylor d6a10f27af Remove unused sphinx Makefile
The appropriate way to build sphinx docs in OpenStack is:

  tox -evenv -- python setup.py build_sphinx

Change-Id: I95dbab8b72cf40fb399703c01bf1a116fcffd4be
2015-10-21 17:38:54 +09:00
Monty Taylor 5a247055ae Update docs to recommend KSA instead of KSC
For the session workflow (which is really the only workflow a dev should
use), session objects should now come from keystoneauth1 instead of
python-keystoneclient.

Change-Id: Icb5f20ce3dc09ff7790b27d07f7f0cb3b83e1e7e
2015-10-21 17:38:54 +09:00
Monty Taylor 84538d8870 Use clouds.yaml from devstack for functional tests
devstack produces a file called clouds.yaml already with credentials in
it. Rather than producing our own config file to run functional tests,
just consume the clouds.yaml file that's already there.

Closes-Bug: #1507386
Change-Id: I82c071b2cd903b9578d1f2ec515882c815812692
2015-10-21 05:43:26 +09:00
kairat_kushaev 4fb3092cb0 Add translation to v2 shell
Add translation support for v2 shell help messages. It allows
to detect the messages that needs to be translated for translation
team.

Change-Id: Id1fb0355090d4e223d13c15100e6726e15563670
2015-10-16 11:26:15 +03:00
kairat_kushaev 6b9133c9b6 Import i18n functions directly
As stated in i18n guide it is normal to import i18n functions
(_, _LW..)  directly and we can include i18n functions in
hacking exceptions.
Also there is no need to make exceptions for six moves
because pep8 passes correctly without it.

Change-Id: I9c9aa490f1447bb7ae221809df7bc110c27d1336
2015-10-16 11:26:11 +03:00
OpenStack Proposal Bot 8cf2bfce3c Updated from global requirements
Change-Id: I8ecfc3575347c8814247d2a537686f56b3653853
2015-10-16 01:00:34 +00:00
ricolin b51634a609 improve readme contents
Add more information in README.rst

Change-Id: I843b850702606102cbb6a6a6ec47fd90b92704f6
2015-10-15 17:51:11 +08:00
Jenkins 2fcff11b90 Merge "Add support for setting Accept-Language header" 2015-10-14 15:25:03 +00:00
Jenkins ccc7d4e550 Merge "Support image deletion in batches in v2" 2015-10-14 15:04:12 +00:00
Frode Nordahl ca050ed4c1 Add support for setting Accept-Language header
DocImpact

Closes-Bug: 1480529
Change-Id: I35a37d55edb700a5993bd5cc352335a87a15e47a
2015-10-14 12:57:07 +00:00