Commit Graph

58 Commits

Author SHA1 Message Date
Takashi Kajinami 569296d389 Require pytz only in Python < 3.9
ptyz is no longer required in Python >= 3.9 in favor of zoneinfo.

Also tzdata was added to requirements as a runtime dependency of
zoneinfo, which is only available in Python >= 3.9 and is not required
in Python 3.8.

Depends-on: https://review.opendev.org/c/openstack/requirements/+/901119
Change-Id: I9ab39a8d394c7063a33c699d277c7f4ed2151767
2023-11-16 08:41:24 +00:00
Takashi Kajinami d6b9e846e4 Fix missing PyYAML dependency
PyYAML is required by oslo_utils.fileutils, but has been missing from
requirements.

Closes-Bug: #1977850
Change-Id: I80afbf26c92e20f64904e0e431360dd269b96f23
2023-10-07 11:12:53 +09:00
Takashi Kajinami 2c8668c4e5 Fix compatibility with Python 3.8
We removed compatibility with Python 3.8 once but it was added back to
tested runtimes for 2023.2. Thus we have to make sure the code works
with Python 3.8, which was broken by [1].

Note that ptyz is added back to requirmenets.txt and is now required
regardless of the python version. This is a short term solution until
we figure out the way to fix the requirement-check job (or we again
remove python 3.8 support).

[1] 7d9fda625f

Change-Id: Ica344021a4e922bcfd20d20cffcce585a5742c8f
2023-05-15 17:29:46 +09:00
Hervé Beraud 7d9fda625f Implement zoneinfo support to drop dependency to pytz
Zoneinfo was introduced within python 3.9.

The support of pytz will be removed within RHEL 10 [1].

2023.2 (bobcat) will move our testing runtime to py3.9 and py3.10
so we want to see pytz removed within this series.

tzdata is required at runtime in our gates, because, by default,
zoneinfo uses the system’s time zone data if available; if no system
time zone data is available, the library will fall back to using the
first-party tzdata package available on PyPI. Apparently our gates have no
time zone data available nor tzdata installed by default because we get the
following error without tzdata installed [3]:
`ModuleNotFoundError: No module named 'tzdata'

So I prefer to add tzdata in our requirements to avoid runtime failure
related to time zone and ensure that time zone are always available.

[1] https://issues.redhat.com/browse/RHEL-219
[2] https://review.opendev.org/c/openstack/governance/+/872232
[3] https://zuul.opendev.org/t/openstack/build/0a1576775e894b09bc31269fea00ba03/log/job-output.txt#1445`

Depends-on: https://review.opendev.org/c/openstack/requirements/+/875854
Change-Id: I1f88bdadc68bfa726eac1da1c5824c1ed352ad98
2023-03-23 17:13:44 +01:00
Stephen Finucane 17db918055 requirements: Remove explicit pbr dependency
We don't use this at runtime. No need to install it.

Change-Id: I5d7d526beebc39de2fa0ff8c6b1d2458c6a3d0bb
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2022-05-18 12:55:06 +01:00
haixin cfe9881e6b Remove all usage of six library
Replace six with Python 3 style code.

Change-Id: I52aa4a0f679b56ffa57cdd2199933e36cf076992
2020-10-09 19:20:51 +08:00
Doug Hellmann c804ba7da6 versionutils: switch from pkg_resources to packaging
Importing pkg_resources has a side-effect of scanning the metadata of
every installed python package. That is excessive overhead for a
function that needs to compare two version strings.

This change replaces pkg_resources with the packaging library, which
is also used as the implementation for version parsing within
setuptools and pkg_resources.

Change-Id: Ic9bda0783d3664e1f518d513d81b3271028335fd
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2020-07-05 14:17:47 -04:00
Hervé Beraud 1868508341 [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in Ussuri cycle.

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://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

Change-Id: If437786eb8dbba9386dd473b45dab0933812c649
2020-02-03 18:30:47 +01:00
Zane Bitter d7e70b11c6 Don't use monotonic on Python >=3.3
A change to the global-requirements[1] has limited use of the monotonic
library to Python versions earlier than 3.3 (later versions have
built-in support for a monotonic clock), so no requirements changes can
be merged until we similarly limit it in requirements.txt.

[1] https://review.openstack.org/615441

Change-Id: Ib53d89ea820d21114d10280c9f4ab1b0c2c4a4bc
2018-12-05 16:28:41 +13:00
OpenStack Proposal Bot 805f4a7c9e Updated from global requirements
Change-Id: Iec6b77a93b4651695affbe570b2c50f19798c225
2017-11-16 11:22:07 +00:00
OpenStack Proposal Bot 08e52a1101 Updated from global requirements
Change-Id: I6a497f6c3038717eea89f2c9e997f142f7a9657b
2017-09-11 21:47:29 +00:00
OpenStack Proposal Bot 1e73a62c2c Updated from global requirements
Change-Id: I6ae50d73178aab40946108e2a2e27fa191e842fa
2017-05-23 11:58:19 +00:00
OpenStack Proposal Bot f69aa3c386 Updated from global requirements
Change-Id: Ia1879d0ef8c8979d903ad71f18b85f8894195870
2017-04-12 04:20:25 +00:00
OpenStack Proposal Bot 0d7f387574 Updated from global requirements
Change-Id: I16ce7840503273a0a1c545123930e2c65ab04276
2017-03-03 00:03:24 +00:00
OpenStack Proposal Bot 3047415e90 Updated from global requirements
Change-Id: Iec0c73d4e04db26942632649d7bd98769d663c01
2017-01-26 04:22:23 +00:00
OpenStack Proposal Bot 50d91e3abc Updated from global requirements
Change-Id: I1c5feff363af5715e8b905ff7667865e20342013
2016-11-09 04:23:07 +00:00
OpenStack Proposal Bot a6585b5ef1 Updated from global requirements
Change-Id: Iac0d856b42f6289fd7d4aa9d332a54e865270e3b
2016-11-02 15:39:30 +00:00
OpenStack Proposal Bot 32cc400608 Updated from global requirements
Change-Id: Id4a7c043a841cfcfb4927573298213b14cffa0b0
2016-09-15 20:25:16 +00:00
Jenkins 9e9f30da57 Merge "Use an actual well defined parser for spec matching" 2016-07-13 11:43:39 +00:00
Joshua Harlow 7699788d59 Use an actual well defined parser for spec matching
Instead of a custom build parser and evaluator for
specs use an actual formal parser and evaluation of
that parse result instead, making that custom parser
now be one that follows a more normal way of creating
and evaluating a DSL.

Also removes <all-in> operator, since it is buggy. (It
will be added later when the issue has been resolved.)

Co-authored-by: Alexis Lee <lxsli@hpe.com>
Change-Id: I10f7dff8c83e5b6983515677e80cefa55881a92c
2016-07-11 22:25:07 +00:00
OpenStack Proposal Bot 006286a6c9 Updated from global requirements
Change-Id: Ib32c3a895d4c23b4603c516f82d092623948c6a6
2016-04-30 18:07:55 +00:00
OpenStack Proposal Bot b13a6e6a3d Updated from global requirements
Change-Id: Ia408f1e02c26bbb5d5dd48a0a913e6e233a9d3ae
2016-02-07 00:17:51 +00:00
OpenStack Proposal Bot af60212ec2 Updated from global requirements
Change-Id: Iac94294cf8d8c41fea31e8e62b2b290d532db729
2016-01-23 10:52:57 +00:00
OpenStack Proposal Bot 3334f2c6b6 Updated from global requirements
Change-Id: Ie4e04746501a3d9af523ed33295492f448be0e74
2016-01-16 03:31:30 +00:00
Jenkins d423b3b74c Merge "Expose function signature fetching function" 2015-12-09 15:37:26 +00:00
Joshua Harlow 479587c6d9 Revert "Move netifaces to extras"
For now revert this, at a later date we can reapply
this but we need to order this a little differently to
make it work out.

This reverts commit 2abbe1c3b1.

Change-Id: I20f3c5804caf1af698aa0f6397a9953eb9aba829
2015-12-07 12:44:17 -08:00
Julien Danjou 5bd2d0b947 Remove Babel from requirements
There's no need to install Babel to use this library.

Change-Id: I023a8e8e4db8cfadb1a85210ab943310827b0ab8
2015-12-03 13:13:20 +01:00
Davanum Srinivas 2abbe1c3b1 Move netifaces to extras
netifaces is a very heavy requirement especially for
python clients, the code that uses netifaces is called
only in exception paths at least now. So let us move
this requirement to extras to reduce the time taken
to install oslo.utils.

Closes-Bug: #1517069
Change-Id: If3430364e49c1c0b1d9f4937bb67900380662728
2015-11-21 13:16:51 -05:00
Joshua Harlow 43451e5cc7 Expose function signature fetching function
This function is the recommended way to get information
about functions going forward, so all the variations of
getargspec can just use this instead (including the variations
of this used in openstack).

This exposes a 'get_signature' function that correctly aliases
the exposed function in python3.x and the backwards compat
library (funcsigs) that exposes this same information in python2.x

Internally in the other reflection functions we now switch
away from using getargspec as well, and replace it with using
this new signature object/function instead.

Depends-On: I1aa0054089ca57fc2d68779f4ee133a9750fec2a

Change-Id: I910b353f5db290832ef87bf7c5e5bb2e9788e3ec
2015-10-16 11:00:46 -07:00
OpenStack Proposal Bot 84595a0e9a Updated from global requirements
Change-Id: I376a8b8f2148254b7a3c828644b6e5bfbd910f9f
2015-09-17 16:42:28 +00:00
OpenStack Proposal Bot 5f6e724eb1 Updated from global requirements
Change-Id: I7d30e54d6268b104060563005e63cd1cddeff215
2015-08-31 15:35:39 +00:00
OpenStack Proposal Bot 6a397f03d9 Updated from global requirements
Change-Id: Ia26864f6e81771d2867a12b95e271ea2a4dea12d
2015-08-26 14:07:36 +00:00
OpenStack Proposal Bot d8305c2e34 Updated from global requirements
Change-Id: I771d6e143643ee6cd267b752a7e9d7aa4cecc8ad
2015-08-10 02:13:34 +00:00
OpenStack Proposal Bot 6c4509587a Updated from global requirements
Change-Id: I73a4bd75e4fee956cc16cd48763f0ce7764a8a78
2015-07-15 01:36:48 +00:00
Joshua Harlow a9ad4412f1 Use monotonic library to avoid finding monotonic time function
That library already does this same/equivalent search and
ensures that a monotonically increasing time is made available
so we can just avoid looking around for it ourselves.

Depends-On: I0f07858e96ea3baf46f8a453e253b9ed29c7f7e2

Depends-On: I33bd2d9dff9cb7dc1a50177db7286b7317966784

Change-Id: Idd2109c8947d10cdbd62c53998ab2e31382e8633
2015-07-06 18:11:57 -07:00
OpenStack Proposal Bot 667d4ed88b Updated from global requirements
Change-Id: I8a112859b8359a7d0d2f1cfaa4a42ebbcf2e3d48
2015-06-22 08:27:20 +00:00
Steve Martinelli e5349b9df7 Add pytz to requirements
pytz is used by timeutils, but it's not listed as a requirement.

Change-Id: I701960b4df399e5aed66ff12ed9bf82ee037de6d
2015-06-01 12:57:28 -04:00
Julien Danjou 5cad113739 timeutils: deprecate isotime()
As Victor Stinner suggested, there is a superior alternative that is
bug-free concerning timezone aware and unaware datetime, and that's the
native datetime.datetime.isoformat() function.

Let's deprecate our local isotime version.

Change-Id: I35ef3205657481f2a49a060ccb199babe582ff7e
2015-05-13 17:13:26 +02:00
OpenStack Proposal Bot a5624b0374 Updated from global requirements
Change-Id: I1323ff1cabec6d2af7296b77cef4f86e6c0c1233
2015-05-07 23:36:49 +00:00
Doug Hellmann 33715509fc Uncap library requirements for liberty
Change-Id: I430f638d35ea1c8f8e1bcdf024cd7efe7532dd9b
Depends-On: Ib948b756b8e6ca47a4c9c44c48031e54b7386a06
2015-04-16 18:09:46 +00:00
Jenkins 61be45f9a0 Merge "add dependency warning to requirements.txt" 2015-04-10 21:05:30 +00:00
OpenStack Proposal Bot a649d55fe6 Updated from global requirements
Change-Id: Id8e1761be8c1beec1f653cf93059451a235ceca7
2015-03-28 02:34:31 +00:00
OpenStack Proposal Bot db5a0c6284 Updated from global requirements
Change-Id: I44625894bb50404c2f38726111da0b0e4ad6c8b6
2015-02-20 13:59:02 +00:00
Doug Hellmann e1bc333fbd add dependency warning to requirements.txt
Change-Id: I873cf64c4ea3bf8fd16bfce7da54f153a52b02d1
2015-01-28 13:44:59 -05:00
OpenStack Proposal Bot ff05ecc7ea Updated from global requirements
Change-Id: Idf7ff1d21b0ccf22a16859ec53409c0250c39ee2
2015-01-23 04:37:45 +00:00
Jenkins 11a588787c Merge "Add pbr to installation requirements" 2014-11-19 23:07:58 +00:00
Oleksii Chuprykov ed9a695564 Add get_my_ip()
At the moment function _get_my_ip() exists (at least) in Cinder,
Ironic, Neutron, Nova and Tuskar, so there is a sense to keep
it in common code.

Change-Id: I3c37d6ea3e8bef7b8a5e21baedd1b2b94369515f
2014-11-18 17:40:50 +02:00
Doug Hellmann 3b9df7198e Add pbr to installation requirements
Add pbr to the list of installation requirements so that it is installed
via pip before this library is installed, instead of with easy_install.
This avoids issues like Bug #1384919, and ensures that projects that use
this library as a dependency are properly installed.

Change-Id: I6c155370dbd01fe4748d5137bdf288e8d3e1a67e
2014-10-24 09:29:38 -04:00
Oleksii Chuprykov baacebcd46 Add ip address validation
There are many projects on OpenStack that use
ip validation. It would be nice to have function
for validation in common module.

Change-Id: Ia723490a02b1816fe96c3a02e069d57f4d97d940
2014-09-25 16:59:15 +03:00
OpenStack Proposal Bot dba9f9ae8c Updated from global requirements
Change-Id: I76122c5b62519e90bcd1a39fb0961cb9c3de94d9
2014-09-19 08:51:07 +00:00