Commit Graph

1390 Commits

Author SHA1 Message Date
Brian Rosmaita 56186d6d5a Fail gracefully when MD5 is unavailable
The glanceclient currently assumes that MD5 will always be available.
This is not the case, however, in a FIPS-compliant environment.  This
patch enables the glanceclient to fail gracefully in such a case.

Closes-bug: #1871675
Change-Id: Ibd89989e06cc5be7da71f5f21561d73b5abc4104
2020-05-04 08:56:58 -04:00
Zuul cf5434a1b8 Merge "Bump default tox env from py37 to py38" 2020-05-01 13:33:19 +00:00
Sean McGinnis 490f808c4f Bump default tox env from py37 to py38
Python 3.8 is now our highest level supported python runtime.
This updates the default tox target environments to swap out
py37 for py38 to make sure local development testing is
covering this version.

This does not impact zuul jobs in any way, nor prevent local
tests against py37. It just changes the default if none is
explicitly provided.

Change-Id: Id27c5ad8a9d4a00f37d4a3ff7f8a71780df50fb0
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-24 10:25:54 -05:00
Sean McGinnis 2f86299b3d Add py38 package metadata
Now that we are running the Victoria tests that include a
voting py38, we can now add the Python 3.8 metadata to the
package information to reflect that support.

Change-Id: Ifbadd0cab7363e604c11b94df3eb466d5e9dfe95
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-24 08:23:16 -05:00
Sean McGinnis 6a045884cb Use unittest.mock instead of third party mock
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: I446ee142c7a17446372c910f7f2a36d55df18e04
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-18 11:58:08 -05:00
Zuul 53254753c4 Merge "Fix SyntaxWarning with Python 3.8" 2020-04-14 12:03:26 +00:00
Sean McGinnis 1b5c309265 Add Python3 victoria unit tests
This is an automatically generated patch to ensure unit testing
is in place for all the of the tested runtimes for victoria.

See also the PTI in governance [1].

[1]: https://governance.openstack.org/tc/reference/project-testing-interface.html

Change-Id: I644e0dcb7c82f7eb3d112f03c021aff8db904aa5
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2020-04-10 13:30:55 -05:00
Abhishek Kekane dff5c881bd Pass --all-stores, --allow-failure as bool to API
Newly added command line options --all-stores, --allow-failure are boolean
but we are passing it as a string to glance API. This will cause problem if
those parameters are not converted to boolean at API side.

Passing these parameters as boolean instead of string to API.

Change-Id: I8d4eab9241fc9bb24bc40b47bf18d63c86a97d77
Closes-Bug: #1871674
2020-04-08 17:11:55 +00:00
OpenStack Release Bot 00bc25eece Update master for stable/ussuri
Add file to the reno documentation build to show release notes for
stable/ussuri.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/ussuri.

Change-Id: Ic9dab2380f698e30c5cb1327c5f22bdd7489df51
Sem-Ver: feature
2020-04-07 13:19:37 +00:00
Erno Kuvaja 3e91562b02 Rename releasenotes to reflect correct version
As python-glanceclient 3.0.0 was released earlier, this release
will be version 3.1.0

Change-Id: I18f4d4e9d61b235ea7896ea97c1b480249d474e2
2020-04-07 11:26:40 +01:00
Zuul ed0e3a9406 Merge "Add release note for glanceclient 3.0.0" 2020-04-07 10:05:29 +00:00
Abhishek Kekane 7e1460a1d0 Add release note for glanceclient 3.0.0
Change-Id: I4556df86ab501362bdfae2d1457ba14dade52f22
2020-04-06 14:37:07 +00:00
Andreas Jaeger baa89534a3 Cleanup py27 support
Make a few cleanups:
- Remove python 2.7 stanza from setup.py
- Update classifiers
- Update requirements, no need for python_version anymore

Change-Id: I6b6dfb0959973abf0c2e8325006025db2a5d85d0
2020-04-04 16:47:34 +02:00
Andreas Jaeger 82da2378ea Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

Remove hacking and friends from lower-constraints, they are not needed
for installation.

Change-Id: I5ae47a7b11ff29a301e440c15daf30db7738485b
2020-04-02 15:48:09 +02:00
James Page 236a7beb34 Fix SyntaxWarning with Python 3.8
Under Python 3.8, the following SyntaxWarning is logged on every
glanceclient invocation:

 SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if kwargs.get('cacert', None) is not '':

Make use of '!=' rather than 'is not' to avoid this warning.

Change-Id: I11ed568932ec5ea0ffee629d6fd434433f262b67
2020-03-31 16:21:52 +01:00
Zuul 6b5a163022 Merge "update doc url to new" 2020-03-26 16:32:58 +00:00
Zuul cab47f3e9b Merge "Replace git.openstack.org URLs with opendev.org URLs" 2020-03-26 15:44:06 +00:00
Zuul 62f76f2532 Merge "Move py35 jobs to latest python3" 2020-03-26 06:39:11 +00:00
Zuul 5ea10250a0 Merge "Delete image from specific store" 2020-03-20 16:14:48 +00:00
Erno Kuvaja d91bcae8a5 Delete image from specific store
Add support to delete image from specific store.

bp: delete-from-store
Change-Id: Ie57d7de5822264a5ea8a5f4587ab8cfb4afb79de
2020-03-20 07:21:59 +00:00
Cyril Roelandt b03b29d8b2 Remove .zuul.yaml from the list of irrelevant files
Change-Id: Ibf038748df6e037df876c0e65d49aa79031275af
2020-03-17 21:04:33 +01:00
Zuul 6d506c3a36 Merge "Remove v1 tests" 2020-03-05 15:55:02 +00:00
Zuul b1181cf789 Merge "setup.cfg: Use better Python 3 hinting" 2020-03-05 15:48:54 +00:00
Abhishek Kekane 2e0396c0c9 Add support for copy-image import method
This change adds support for copy-image import method which will
copy existing images into multiple stores.

Change-Id: I748a8fb3dbaf9c2e4d887a2ecd4325e27a8429c4
bp: copy-image-multiple-stores
2020-02-27 06:49:11 +00:00
Erno Kuvaja c23d86738f Add support for multi-store import
This change adds support for providing multiple target
stores where image can be imported.

Co-authored-by: Erno Kuvaja <jokke@usr.fi>
Co-authored-by: Abhishek Kekane <akekane@redhat.com>

bp: import-multi-stores
Change-Id: I8730364263f1afd5d11fd56939851bda73a892bb
2020-02-27 05:52:49 +00:00
Stephen Finucane 3ebc72f7af setup.cfg: Use better Python 3 hinting
Make sure people are not using an incorrect version of Python and don't
say we support universal wheels when we clearly do not.

A bit of pbr configuration that hasn't been required since pre-1.0 is
also dropped.

Change-Id: I313df5b36ad908d55ae69421dfc527a67847c970
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2020-02-22 00:10:17 +00:00
Erno Kuvaja 993406d57d Remove v1 tests
Change-Id: Ic6cb15670a42d0cea424f58d6a1d85d5471e162e
2020-02-19 09:34:42 +00:00
Abhishek Kekane 23fb691dfb Drop support for tempest-full
Even after dropping support for py2, tempest-full job is still running
using python2.

Removed this job from the set of templates.

Change-Id: If37a91a4a362f37f396c161b980a2db20838fe3b
2020-02-19 05:26:42 +00:00
Ghanshyam 583194fc85 Move py35 jobs to latest python3
glanceclient-tox-py35-keystone-tips and glanceclient-tox-py35-oslo-tips
jobs run on py35 which should be moved the newer python3 version.

Moving them to py3 env so that they can pickup the available
python version on running node.

Change-Id: I5fadbadf9eee2163ef6d17af2ceb49883151038c
2020-01-22 10:47:46 -06:00
Ghanshyam Mann a4465dfc22 Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

python-glanceclient is ready with python 3 and ok to drop the
python 2.7 support.

Complete discussion & schedule can be found in
- http://lists.openstack.org/pipermail/openstack-discuss/2019-October/010142.html
- https://etherpad.openstack.org/p/drop-python2-support

Ussuri Communtiy-wide goal - https://review.opendev.org/#/c/691178/

Change-Id: I029d10a2860c5ba371ff9c5df9b7e2c645a7dfbb
2020-01-22 02:38:42 +00:00
Zuul e8c08e0c4d Merge "Cleanup session object" 2019-12-11 08:16:27 +00:00
Daniel Bengtsson 1f9fe0319b Stop configuring install_command in tox.
Currently, we are overriding 'install_command' to use 'pip'. This is
considered poor behavior and 'python -m pip' should be used instead:

https://snarky.ca/why-you-should-use-python-m-pip/

It turns out that this is the the default value provided by tox:

https://tox.readthedocs.io/en/latest/config.html#conf-install_command

So we can remove the line and simply use the default value.

Change-Id: Idd3d92657a7c17370afc0d0c35cc4666025ab9d6
2019-11-15 10:19:00 +01:00
OpenStack Release Bot 4767d9de22 Update master for stable/train
Add file to the reno documentation build to show release notes for
stable/train.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/train.

Change-Id: I21107acca89fe8666e0981e1d7a6de62331b55f6
Sem-Ver: feature
2019-09-13 14:59:30 +00:00
Zuul 40c19aa443 Merge "Rename --backend to --store" 2019-09-13 01:31:30 +00:00
Brian Rosmaita baddc063a1 Add release note for glanceclient 2.17.0
Change-Id: Ib5cc95d4faad4847297c62ed6943dbc357a64234
2019-09-12 12:34:17 -04:00
jacky06 e8d554fde7 Replace git.openstack.org URLs with opendev.org URLs
Change-Id: Id02ac765028673ecabcb76d3f3014bbb383bc098
2019-08-24 10:47:42 +08:00
Zuul 7547179351 Merge "Add upper-constraints.txt to releasenotes tox environment" 2019-08-21 16:32:08 +00:00
Alex Schultz 436f797e8d Cleanup session object
If a session object is not provided to the get_http_client function (as
is done via osc), the glance client uses it's own HTTPClient class. This
class creates a session but does not properly close it when it is done.
This can lead to resource warnings about unclosed sockets. This change
adds a __del__() to the HTTPClient class to close out the session
correctly.

Change-Id: Idccff338fa84c46ca0e429bb533a2a5217205eef
Closes-Bug: #1838694
2019-08-01 14:41:29 -06:00
Zuul 31f2fdae94 Merge "Modify the url of upper_constraints_file" 2019-07-31 08:12:49 +00:00
Zuul 2b5090f049 Merge "Trivial: fix image format typo" 2019-07-31 08:10:10 +00:00
Lucian Petrut a56106092e Trivial: fix image format typo
The Glance V1 image format list contains "VDHX", which is a typo.
This change fixes it, using the correct format name, which is "VHDX".

Luckily, this seems to be used only as part of a help string.

Change-Id: I392f25b3ee0ee9ac6024e1670053191e4bba937a
2019-07-30 13:42:18 +03:00
root c246598789 Correcting typo in shell.py - enviroment to environment.
There is a typographical error in glanceclient/v2/shell.py. Correcting
spelling from enviroment to environment.

Change-Id: Ia19a4417cd05d228adc26f9d7c82f4aa3c24488c
2019-07-30 01:11:09 +05:30
Zuul 68cb66b5d0 Merge "Bump openstackdocstheme to 1.20.0" 2019-07-17 14:52:26 +00:00
翟小君 b79429aec6 Bump openstackdocstheme to 1.20.0
Some options are now automatically configured by the version 1.20:
- project
- html_last_updated_fmt
- latex_engine
- latex_elements
- version
- release.

Change-Id: I2577ca452a014402f1377474457095176d422b42
2019-07-02 09:45:33 +08:00
Corey Bryant fec518a6a3 Add Python 3 Train unit tests
This is a mechanically generated patch to ensure unit testing is in place
for all of the Tested Runtimes for Train.

See the Train python3-updates goal document for details:
https://governance.openstack.org/tc/goals/train/python3-updates.html

Change-Id: I4f689ee8b9534952ca30db944e547cb7ca74a17f
Story: #2005924
Task: #34208
2019-06-25 13:32:16 +00:00
Zuul 155e540ebf Merge "Update hacking version" 2019-06-24 08:23:35 +00:00
pengyuesheng 69ef9d81ce Modify the url of upper_constraints_file
Depends-On: http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: I63be5a18a8221f0ca2b1f2a96367288833e4a096
2019-06-19 12:22:51 +08:00
pengyuesheng 039fa4c045 Blacklist sphinx 2.1.0 (autodoc bug)
See https://github.com/sphinx-doc/sphinx/issues/6440 for upstream details
Depend-On: https://review.opendev.org/#/c/663060/

Change-Id: I8a96eea9d3d8f6d8beae9d86f307f0edd075392c
2019-06-10 11:12:44 +08:00
pengyuesheng 43e6338748 Update sphinx dependency
Sphinx 2.0 no longer works on python 2.7, so we need to start capping
it there as well
depend on https://review.opendev.org/#/c/657890/

Change-Id: Ic77e0db24ab7d7f068faf3e237beefa8856a710a
2019-05-28 15:17:25 +08:00
Zuul 83a2dac21c Merge "HTTPClient: actually set a timeout for requests" 2019-05-15 13:07:20 +00:00