Commit Graph

69 Commits

Author SHA1 Message Date
Dr. Jens Harbott 43fba3aaab Add python3.11 to generate-constraints
This prepares to run the proposal bot to generate constraints on
python3.11 instead of python3.10. The actual job to run this will need
to be added in the project-config repo.

Change-Id: I8fe5f8fe335cccf9c9ce166e931c4a42d9d79457
2023-09-23 11:00:58 +02:00
Stephen Finucane e75a249fbd tox: Drop python3.6, python3.7 from generate env
These are no longer officially supported.

Change-Id: I46348e7a081628c1298d8bb5e82233f65339df9c
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
2023-08-31 16:19:11 +00:00
Elod Illes b3ccca8516 Fix gate by bumping tox version and removing ryu
Gating jobs started to fail with latest pyproject-api (1.6.1) release.
This release would need latest tox (4.11.0) to not fail, but we are
pinning tox via pinning virtualenv in tox.ini.
To resolve this we have to remove the virtualenv pinning, which was a
"temporary" hack to avoid py3*-check-uc jobs to break. This job is
failing because of ryu package, which is unmaintained and projects
started to use os_ken instead, which "is a fork of the Ryu library
tailored for OpenStack Neutron" [1]. Hence, this patch removes ryu
from requirements files to eliminate the need of pinning virtualenv.

[1] https://opendev.org/openstack/os-ken

Change-Id: I23ba892e6dd7f2566e5af6626c072c2dcc5a4382
2023-08-31 17:12:02 +02:00
Dr. Jens Harbott 32744d9704 Add requirements-tox-py311-check-uc job
Start checking requirements on python3.11 to get early warnings about
upcoming issues. Non-voting for now.

Change-Id: I7713029b95beb69d87f5cba66997fd4ba422c6b0
2023-04-19 19:05:21 +00:00
Dr. Jens Harbott d545261775 Add requirements-tox-py310-check-uc job
We produce requirements for python3.10 now, check upper-constraints for
that python version, too.

Change-Id: Ifa381e099cb5c202815eb09e582e2fdb92075370
2023-03-26 20:15:14 +02:00
Elod Illes 7c3cb29757 Cap virtualenv (<20.18.0) to unblock gate
With latest virtualenv (and setuptools bundled in it) py3*-check-uc
jobs started to fail as pkg_resources' __getattr__ breaks on multiple
packages' metadata.

Release is very close and library release upper constraints bumping
patches are piling up. This patch is a workaround only to unblock the
gate and need to be reverted as soon as the py3*-check-uc jobs works
well with the latest virtualenv and setuptools releases.

Change-Id: I36ae32a401844bf5a5df0d20d3f88f24b2a0cf8e
2023-02-14 20:46:02 +01:00
Ghanshyam Mann c393eb75a4 Fix tox4 error
tox.ini started failing with Tox4 which had some
incompatible changes. One of them is to allow
external command to run by adding them into allowlist_externals

Fixing tox.ini for tox4 changes.

Change-Id: I7bc7c98954395765f16cc943e5c826983db5dba0
2022-12-29 05:33:08 +00:00
niuke 38f5ef6074 Use TOX_CONSTRAINTS_FILE
UPPER_CONSTRAINTS_FILE is old name and deprecated
This allows to use upper-constraints file as more
readable way instead of UPPER_CONSTRAINTS_FILE=<lower-constraints file>.

Change-Id: I8614a6a6d4db1c4994c7dea1fe4f4cb31bdfe25e
2022-07-26 11:06:56 +08:00
Matthew Thode 53f1cd32d2
switch from py36/38 to py38/39
Change-Id: Idd24975afb969a9b182be9034bee4d4b019ac32b
Signed-off-by: Matthew Thode <mthode@mthode.org>
2022-04-13 20:05:09 -05:00
Sorin Sbarnea ecf18825ab Make tox -e generate easier to use
- auto detect python paths (which)
- make it possible to call `tox -e generate` w/o extra args
- update list of pythons to include currently supported versions

Change-Id: Ib727242c1aba8597389259d8dbacba7194f9f0d6
2021-06-24 10:29:44 +01:00
zhangboye bd6bfd668c Use py3 as the default runtime for tox
Moving on py3 as the default runtime for tox to avoid to update
this at each new cycle.

Change-Id: Ic7da4eb020f001959c8060c433922a23ff29eba7
2021-04-20 14:53:34 +08:00
Matthew Thode d0b389d840
update requirements and constraints for py3 only Victoria
generate-constraints -b blacklist.txt -p /usr/bin/python3.6 -p /usr/bin/python3.8 -r global-requirements.txt

Change-Id: I2d58d1b524764ea1d46d6ab3a382783f6a002b34
Signed-off-by: Matthew Thode <mthode@mthode.org>
2020-05-15 23:17:51 -05:00
Zuul d482f46963 Merge "Update the minversion parameter." 2020-02-11 20:52:37 +00:00
Daniel Bengtsson a17a484002 Update the minversion parameter.
Update the minversion parameter to use the python -m pip to install
python packages:

https://tox.readthedocs.io/en/latest/changelog.html#id185

It's recommend to use this.

Change-Id: I8c3e3c34a05928d9c001074b9513d577c8541c58
2020-02-11 14:03:46 +01:00
Daniel Bengtsson 1d10bd9d46 Stop testing python 2 in tox.
Remove python 2 from envlist parameter. Check the link:

https://etherpad.openstack.org/p/drop-python2-support
https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

The plan is drop the python 2 support from OpenStack in Ussuri release.
Move the basepython parameter.

Change-Id: I6787026195c8852386f7186fe697b724051a9684
2020-02-11 12:43:27 +01:00
Daniel Bengtsson 11f05d4904 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: I9130a9202515ac7b88e7b6a99dbb6a756ac65895
2019-11-15 12:21:31 +01:00
Corey Bryant 7e0eec0790 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: Iab77d920bc5c46a7d7d21c05def60ba278b56983
Story: #2005924
Task: #34243
2019-07-05 15:58:26 -04:00
Tony Breeds f43647b3ed Fix where we use constraints
in I2598503c2d4397d7efbb03a76df9a4e91dd0c1cf we mistakenly added
constraints to install_command in out based testenv.  This is incorrect
as it means the generate env will be run in a constrained environment.

We don't use UPPER_CONSTRAINT_FILE as *right now* it's the same thing
and this leaves us internally consistent (even if technically incorrect)

Change-Id: Ia61d944dbfdf494598e41e5fbefd0e32a91814ed
2019-05-16 18:31:56 +10:00
Zuul e91609fdbe Merge "Add safety check output to the linters output" 2019-05-14 16:47:38 +00:00
Zuul 4619e65da7 Merge "Add upper-constraints enforcement for local reqs" 2019-05-12 21:28:49 +00:00
Sean McGinnis 8bad9fe19d Add upper-constraints enforcement for local reqs
This adds the use of upper constraints in our tox environments. Jobs
like openstack-tox-py27 have started failing due to trying to install
lib versions that only support Python 3.

The 'generate' target keeps the unconstrained deps since we actually do
need the latest installed for that.

Updates the requirements-integration job to run using py36 since that
now fails with running under py27. This should get the job to pass until
we are able to rewrite it to not be a legacy job.

NOTE(dmllr): updated install_command to include local constraints file

Change-Id: I2598503c2d4397d7efbb03a76df9a4e91dd0c1cf
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2019-05-12 15:31:10 +02:00
Sean McGinnis 5e75d5d0b4
Fix docs environment
Change-Id: Iac612b8bf8d02f58f4677f3e1104d99cacce5b23
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
2019-05-11 13:46:51 -05:00
Dirk Mueller b628986912 Add safety check output to the linters output
Currently a safety check failure is ignored, the output
is just for informational purposes. it reports known
security issues with the versions in upper-constraints.txt
so that we can determine a corrective action.

Change-Id: Ib8191602f47641eb047ebe5972ffa92bcfd08de4
2019-05-08 23:04:25 +02:00
Ghanshyam Mann 3dd1bb02b6 Dropping the py35 testing
All the integration testing has been moved to
Bionic now[1] and py3.5 is not tested runtime for
Train or stable/stein[2].

As per below ML thread, we are good to drop the py35
testing now:
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/005097.html

This commit makes requirements-tox-py36-check-uc job
voting and run on gate pipeline also.

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004647.html
[2]
https://governance.openstack.org/tc/reference/runtimes/stein.html
https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: I62b5d59ef0694ff5dd040c5cfda1b7d6e54e3b11
2019-04-22 03:14:51 +00:00
98k f279df2801 Add python 3.6 unit test job
This is a mechanically generated patch to add a unit test job running
under Python 3.6 as part of the python3-first goal.

See the python3-first goal document for details:
https://governance.openstack.org/tc/goals/stein/python3-first.html

Change-Id: I6b493911d950182a9da1e13f01ef22e7bb0516b8
2018-11-09 04:19:26 +00:00
Tony Breeds 3a6ef20dab Leverage ignore_basepython_conflict to get the right python version
Currently as we have basepython set in the testenv we always get the
same python3 binary even when specifying a specific env (eg py37).

This change uses ignore_basepython_conflict to tell tox when creating
the py3X envoronments to use the major/minr from the env rather than
basepython.

Before:
 [tony@thor requirements]$ tox -re py37,py35,py36,py27 --notest
 [tony@thor requirements]$ for py in .tox/py*/bin/python ; do echo $py ; $py --version ; done
 .tox/py27/bin/python
 Python 3.6.6
 .tox/py35/bin/python
 Python 3.5.6
 .tox/py36/bin/python
 Python 3.6.6
 .tox/py37/bin/python
 Python 3.6.6

After:
 [tony@thor requirements]$ tox -re py37,py35,py36,py27 --notest
 [tony@thor requirements]$ for py in .tox/py*/bin/python ; do echo $py ; $py --version ; done
 .tox/py27/bin/python
 Python 2.7.15
 .tox/py35/bin/python
 Python 3.5.6
 .tox/py36/bin/python
 Python 3.6.6
 .tox/py37/bin/python
 Python 3.7.0

Change-Id: Ie16bfa0a96d41cc3d1712b0d3c7a6ce2378b5478
2018-10-18 13:04:09 +11:00
Doug Hellmann 0ae1c7fd19 add tox env for running requirements-check
Set up a tox environment for running project-requirements-change.py,
the script used in the requirements-check job.

Change-Id: I5336222949acfd947f2ef54ed120e3632b28ccb7
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-07-11 07:34:10 -04:00
Vu Cong Tuan aeee67d09d Add py36 testenv
Python 3.6 is installed by default in Ubuntu 18.04 LTS.
According to Python2 Deprecation Timeline [1] and Python3-first Goal [2],
we should have py36 testenv ready for it.

This change adds a non-voting job for checking the 3.6
upper-constraints, and a voting job for py36.

Once we're confident we have all the bits in place for 36-uc checking we
can promote that job to voting.

[1] https://governance.openstack.org/tc/resolutions/20180529-python2-deprecation-timeline.html
[2] https://review.openstack.org/#/c/575933

Change-Id: Ia06c1ab217e80902adb607a3bc6063aae66f48bf
2018-07-10 04:11:09 +00:00
Doug Hellmann 8d106be517 remove the global lower-constraints.txt file
Rely on our ability to compute a good lower constraints set for
multiple projects using the build-lower-constraints command instead of
maintaining a single list in this repository.

Change-Id: I0a4be42efdbfd73228d043c1aa21feb7829650f3
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-07-05 09:38:09 -04:00
Doug Hellmann 79b3f297f0 change tox default to python3
Update tox to use python3 for most jobs instead of python2. Leave
python2 in place where the job name clearly means for it to be used.

Change-Id: I7ecbae445de9641de0622af97f7ca9dff35b8066
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-06-28 13:28:36 -04:00
Tony Breeds 9efda7ea25 Move requirements to the PTI
When the TC merged I2637dd714cbb6d38ef8b8dc1083e359207118284 we're
supposed to invoke stestr rather than testr so lets do that

Change-Id: Ic5b984949462e9d96d0ba122531d7f0a3d733891
2018-05-21 14:58:48 -07:00
Dirk Mueller fdea9970c5 Add a global coinstallable lower-requirements set
This is generated from the lower bounds of g-r.txt
and to be maintained manually. There is a variant
of check-uc called check-lc added that will verify
those dependencies to be coinstallable and passing
consistency checks.

Change-Id: I99ad9f0b1d6c150bee6d6d35f84a74e99ab849b8
2018-03-03 19:48:11 +01:00
Zuul 33a110d840 Merge "run bashate as part of the linters gate" 2017-11-24 01:16:23 +00:00
Dirk Mueller 0efc104e26 run bashate as part of the linters gate
Also keep pep8 as a compat wrapper around it, to be remove
once zuul config has been adjusted to run linters instead.

Change-Id: I1e1be5bd2cd5a3f6b1c0f68ccf29e536b1743311
2017-11-20 12:15:10 +01:00
Paul Belanger 950c6cd74a
Clean up bindep.txt file
With zuulv3, we are now using bindep.txt more to manage
build-wheel-jobs.  As such, give an update to start supporting
centos-7. I've also cleaned up a few depedencies we no longer need.

This also add support to test wheel-mirror builds.

Change-Id: Ia6c1113d119b01e7189e4ada41e10865c4ec0066
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-11-19 21:19:55 -05:00
Dirk Mueller 32d058382d Use a recent hacking version
Listing hacking in test-requirements is deprecated, as
it is a blacklisted linter and the global requirements update
bot wouldn't update it anyway. Instead use it just as a
dep on the pep8 tox env.

Change-Id: Idb4bcd8e4ffe1738a7306f9e1e5530b7e1e8dc8f
2017-10-26 13:57:25 +02:00
Dirk Mueller 7d964b69c3 Remove temporary zuulv3 transition helper
Change-Id: I2ecb112e148dd1858684ef6b6a3f62141857dfec
2017-10-24 09:41:56 +02:00
Dirk Mueller 1514d3fb7f Add copy project-config's legacy-requirements-cross-* jobs
These are going to be rewritten to native zuulv3 jobs
in the next commit.

Needed-By: I3b0dbdcc02a0a8cff0c52701fadf7632648afb97
Change-Id: I3b9a86528350242c4d785d0f49c318de6c29ec75
2017-10-19 22:56:10 +02:00
Tony Breeds d827e71b22 Add a bashate tox environment and address errors
Add a bashate environment for checking shell code quality.
Exclude bashate warnings:
 E006: Line too long:
 E010: The "do" should be on same line as for

In my opinion the places that trip these do not impact code readability

Change-Id: Iab0a34542c3938f127515291eca8f027f3accaa0
2017-09-28 12:09:04 +10:00
Dirk Mueller 8f689cf7f4 Add python35 check-uc job
Change-Id: Ie5d0cf462d7144c25564257d25303d56b810ac24
2017-09-11 14:50:32 -06:00
Doug Hellmann c12c13350f use the constraints list when installing the constraints list
Some of the dependencies may not be constrained on their own (pbr) so
use the constraints list to enforce the constraints.

Change-Id: I3ae5835d1b1b8f75608d7bb110732f9be233b13f
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-03-17 16:22:13 +01:00
YAMAMOTO Takashi fab2c3b527 tox: Install packages from requirements.txt as well
Change-Id: I75e3086862b83c8eeba79e984d3ac5b7335cd832
2016-12-26 13:51:55 +09:00
Jenkins 3cc50f2a57 Merge "Fixes for check-uc jenkins job" 2016-10-04 04:59:10 +00:00
Dirk Mueller d59c8ece29 Fixes for check-uc jenkins job
Implement XFAIL handling for ignoring known problems so that
we can make the job voting until the remaining issues are sorted
out.

Change-Id: Ia2cf2c440a72e6365a9ff08086704dc535bbc072
2016-09-29 20:33:34 +02:00
Dirk Mueller c50e549107 Remove now unused py27-with-upper-constraints env
Change-Id: I28e157e633fe306a5939b79e38dd656b9a9ccf0b
Depends-On: I7b46f15d12b8f78b34534d2646179db295dea7b3
2016-09-28 17:53:34 +02:00
Dirk Mueller ab97a43a5e Add a copy of the check-with-upper-constraints as a shorter name
Due to the rename of the job adding the -ubuntu-xenial suffix,
we have exceeded the path limit and can no longer run inside the
tox environment. shortening to a shorter check name (and renaming
the job) should fix this.

Change-Id: I0927ae81148d15256bd4dfe2a5e48b1819bbe2af
2016-09-28 17:47:27 +02:00
Tony Breeds 9a428f3ddb Check for missing run-time requirements
This change creates a new tox environment that *only* installs
openstack_requirements and then verifies that each of the console
scripts has all of the modules that it imports.

This will need to be added to our gate RSN

Change-Id: Ibc37593afcc4d9f820cb88168e1aa15e773b2087
2016-07-26 19:46:49 -05:00
Davanum Srinivas 9e0ff3a550 Check conflicts script
Use pkg_resources.require to report conflicts to ensure
co-installability.

Co-Authored-By: Igor Yozhikov <iyozhikov@mirantis.com>
Change-Id: I7443496b6a06d02bb9cc9457b729dea71451f44a
2016-06-02 16:24:00 -04:00
Jenkins 3fc9230f4f Merge "Clean up removed hacking rule from [flake8] ignore lists" 2016-05-26 15:10:03 +00:00
Jenkins 2e7df9c0ac Merge "add a validation command to ensure projects use check-requirements" 2016-05-17 10:24:01 +00:00