Commit Graph

27 Commits

Author SHA1 Message Date
Dirk Müller 520ee43dab
add suse_py311 flavor to explicitly render templates for py311
This is needed when py 3.11 is not the primary python version
(e.g. SLE15).

Change-Id: I362ec318a0c63f54469eb3267b5b8d868856bbdf
2024-01-07 14:48:17 +01:00
Tony Breeds b861f9d3c6 [tox] Update constraints, flake8 settings and default envlist
In validating the change after this I found that:
1. The pypy tox env defaults to pypy2 which obviously is a problem
2. The constraints URL, while functional, follows an older more complex form
3. The pep8 tox env would descend into .tox which fails as packages
   outside of out control may have pep8 issues
4. I often have a .venv directory which fails for the same reason as
   point 3

This change addresses those issues suck that a `tox` run completes as
expected.

Change-Id: Ia64b5f7b69744ede12604bfd204ae0cbdb6aeea2
2022-08-19 11:48:45 -05:00
Dirk Müller 8f07a592c8 update to zed level jobs
Raise flake8 level as well. no changes required to pass

Change-Id: I1ae8e98df2cd27a09cbd93017f893f90199cd547
2022-05-13 10:13:51 +02:00
zhangboye 6466ee2cad 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: Iba3c9b38260ad757c2e055d13da8ff740c014aa0
2021-04-20 16:36:54 +08:00
Hervé Beraud d14d9ddfc7 Add doc/requirements
We need to specify doc requirements in doc/requirements.txt
to avoid problems with the pip resolver [1] for the release team [2][3].
Removing specific doc requirements from test-requirements.txt.

The problem here is that this repos haven't doc/requirements.txt file
and by default in this case zuul will use the test-requirements.txt file
to pull requirements [4].

This requirements file contains extra requirements like flake8 that
collided with those allowed in our job environment and so the new pip
resolver fails to install these requirements and the job exits in error.

This project meet the conditions leading to the bug.

Notice that pymod2pkg isn't released by the openstack/release team due
to the recent SIG move, however standardization can't hurt.

[1] http://lists.openstack.org/pipermail/release-job-failures/2021-January/001500.html
[2] http://lists.openstack.org/pipermail/openstack-discuss/2021-January/019611.html
[3] http://lists.openstack.org/pipermail/openstack-discuss/2021-January/019612.html
[4] https://opendev.org/zuul/zuul-jobs/src/branch/master/roles/ensure-sphinx/tasks/main.yaml#L36

Change-Id: Iba51416b8c4544db3983ac0ea1e6ea53d266be7c
2021-01-07 16:34:24 +01:00
maaoyu 5138e3e1b4 bump py37 to py38 in tox.ini
in 'victoria' cycle, we should test py38 by default.

ref:
  https://governance.openstack.org/tc/reference/runtimes/victoria.html

Change-Id: I37ddbac65128ad3df123440fccbf63958c60d6ba
2020-10-12 15:16:59 +08:00
Dirk Mueller 037724dd88 Switch away from deprecated distribution lookup
Python 3.8 removed the linux_distribution support, we need
to switch to the distro package.

To pass testing, we need to update to a newer flake8 version.
Also update setuptools annotation since Python 2.x support
has been dropped.

Change-Id: I40768af80ff376866b1070026a93fd3f4bb1c2e4
2020-03-23 12:37:13 +01:00
Ghanshyam Mann 5012af2f47 [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

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

Change-Id: I7cf441a76a209287eb935e2d360022d957b56954
2020-02-15 17:14:08 -06:00
liuwei f96a62395c update git.openstack.org to opendev
Change-Id: Ie6c59622873cb70f159915eb8e77d900d63e487f
2019-08-21 12:39:26 +00:00
Thomas Bechtold b632f6ca55 Use sphinx-build for building the documentation
Follow the project testing interface[1].

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

Change-Id: Ifafbbae82d6c7e91df86624df85482689de02478
2019-08-20 06:06:32 +02:00
Corey Bryant 4229765d71 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

Depends-On: https://review.opendev.org/669542

Change-Id: I7add04a3f3d02c5e771088986920b6743234dfee
Story: #2005924
Task: #34235
2019-07-05 16:28:44 -07:00
Dirk Mueller 5d3baa87e0 flake8: update to 3.6.x
Use a reasonably new flake8.

Change-Id: Ifeb33d41a6384083f2d5ce9e6da77852ed1614d2
2019-01-02 22:16:16 +01:00
Doug Hellmann 1905e8bc93 fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I4e87085c6cbb24367d8a7f839b4811d049ba7bf1
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-11-11 06:16:18 +00:00
Zuul 92b676f05a Merge "Switch to stestr and remove flake8 from the list of dependencies" 2018-08-30 19:34:06 +00:00
Dirk Mueller 2674bb7230 Switch to stestr and remove flake8 from the list of dependencies
Change-Id: I4db520e650f72407ebd8100f689af01fcf61cc5d
2018-08-28 14:01:32 +02:00
Doug Hellmann 8c8e861bc8 add lower-constraints job
Create a tox environment for running the unit tests against the lower
bounds of the dependencies.

Create a lower-constraints.txt to be used to enforce the lower bounds
in those tests.

Add openstack-tox-lower-constraints job to the zuul configuration.

See http://lists.openstack.org/pipermail/openstack-dev/2018-March/128352.html
for more details.

Change-Id: I538e86c3fe10d09bc3b0f259d33a49aeb4ffd2e2
Depends-On: https://review.openstack.org/555034
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-04-03 09:32:23 -04:00
Andreas Jaeger a354cba8d5 Avoid tox_install.sh for constraints support
We do not need tox_install.sh, pip can handle constraints itself
and install the project correctly. Thus update tox.ini and remove
the now obsolete tools/tox_install.sh file.

This follows https://review.openstack.org/#/c/508061 to remove
tools/tox_install.sh.

Change-Id: Iab3227728e597f553c3b7f3195919095e858c40c
2017-12-02 16:50:36 +00:00
Dirk Mueller 3b8274b8f3 Switch to newer flake8 / python 3.x version
the python 3.x version of flake8 finds more python 3.x
portability issues than the 2.x, as more checks are
enabled/active there.

Change-Id: Ie702ec7ce85e47b2ab6905f548be0b974077525e
2017-10-24 13:40:52 +02:00
loooosy 770f2303f1 Drop py34 and add py35 in setup.cfg tox.ini
Python 3.5 is supported now. We do not have Python 3.4 in
setup.cfg which declares the explicit supported versions.
For more information, see:
https://review.openstack.org/#/c/349069/

Change-Id: I2e1235b2f9c340bc46ddb0c79bdf1e0cc3627b15
2017-04-25 00:45:54 +00:00
Dirk Mueller 8faf0c4571 Add Constraints support
Adding constraints support to clients is slightly more complex than
services as the clients themselves are listed in upper-constraints.txt
which leads to errors that you can't install a specific version and a
constrained version.

This change adds constraints support by also adding a helper script to
edit the constraints to remove pymod2pkg.

Change-Id: I05a2bcca4a240df1995de0627c8acd7ffbeb1893
2016-12-03 13:09:26 +01:00
Thomas Bechtold 722956693a Switch to pbr for building pymod2pkg
This is in line with other OpenStack projects.

Change-Id: I22d5d19df2261c9f9b48c495b52a78f2eee58206
2016-06-06 15:12:16 +02:00
Jenkins 544b8b4ed2 Merge "Deprecated tox -downloadcache option removed" 2016-01-15 10:48:46 +00:00
Jenkins 4c0708a1ab Merge "Fix py34 DB issue" 2016-01-15 10:46:53 +00:00
Ondřej Nový 5da6695135 Deprecated tox -downloadcache option removed
Caching is enabled by default from pip version 6.0

More info:
https://testrun.org/tox/latest/config.html#confval-downloadcache=path
https://pip.pypa.io/en/stable/reference/pip_install/#caching

Change-Id: I5b2e08672f2354605052dfaab5b108948175c2ab
2016-01-15 10:43:12 +00:00
Thomas Bechtold 788c70ab26 Restructure documentation
- Convert README from markdown to restructured text
- Add documentation template for Sphinx
- Add setup.cfg file so that sphinx build is done in
  doc/build/html as expected by infra scripts.

This is the way OpenStack projects usually do documentation.

Change-Id: I7e40a2e6fe14e63bd33f9b1ea1f31db23c7501b8
2016-01-07 19:09:50 +01:00
Janonymous dd1984d898 Fix py34 DB issue
To solve the problem of "db type could
not be determined" on py34 we have to run first the py34 env to, then,
run py27. This patch puts py34 first on the tox.ini list of envs to
avoid this problem to happen.


Closes-bug: #1489059
Change-Id: I37b866389b4342a9d0b603d09fa2c69d775cfe1e
2016-01-07 02:55:01 +00:00
Thomas Bechtold 479ef07c9a Add tox.ini to be able to run tests
In addition to the tox.ini, there are some more changes
to enable testing:

- require flake8 in test-requirements.txt
- fix current pep8 errors
- add .gitignore including the .tox dir

Change-Id: I4cf9d8fc1c9a2eb4929fddb4a18a7db87481017c
2015-11-10 14:56:15 +01:00