Commit Graph

61 Commits

Author SHA1 Message Date
Sharpz7 f1d47a9f48 [codespell] Adding Tox Target for Codespell
Second in a series of commits to add Codespell to Ironic Repos. This one adds the command that was used to fix the spelling errors.

Future Commits will add CI support and potentially a git-blame-ignore-revs file if their are lots of spelling mistakes that could clutter git blame.

Change-Id: I2db37013bdfa85055be9f1a620424ea50e993da0
2024-01-25 21:31:43 +00:00
Riccardo Pittau c64f6ba5c1 Uplift default Ansible version to 8.x
Change-Id: Iabb9f55b8dacc7ef9965ac60d67e70b60dd723c5
2024-01-09 09:35:18 +01:00
Riccardo Pittau 2f2e55d643 Update ansible linters to current version used
Change-Id: I49a30f3547e32e8ef90d65b46e5393957b8946b2
2023-12-19 11:53:00 +00:00
Jay Faulkner 15b3a970e3 Upgrade pep8 deps - including hacking v6
Updating deps for pep8
- hacking to 6.0.0
- pycodestyle upper limit bumped to 2.0.0

Change-Id: Id9e86477c20b9fe059cc867cbf5f4f566b6097fe
2023-04-23 21:19:25 +00:00
Zuul e83e4d8631 Merge "Use ansible 6.x" 2023-01-18 15:06:36 +00:00
Riccardo Pittau b2505df501 Fix CI
- Increase size of ESP partition to allow bigger esp images in debian
bullseye
- Restore correct selinux context for configdrive iso
- Remove skipsdist from tox.ini for compatibility with tox 4

Depends-On: I550dac9d055ec30ec11530f18a675cf9e16063b5

Change-Id: I3871d90aac23704cf95d6bdccd1e213ed97fa149
2023-01-09 09:14:39 +00:00
Jay Faulkner f06b8a7580 Fixes for tox 4.0
- Fixed passenv syntax
- Removed usedevelop (not allowed with skipsdist)

Change-Id: I2279b81c8d9975300be9d0bd8c035963021ce6df
2022-12-15 10:03:40 -08:00
Riccardo Pittau 786f891749 Use ansible 6.x
Use tags instead of numerical ids for better compatibility
with latest ansible-lint versions.

Change-Id: I87431617eacf380aada94c5c3ed534476ddfb1ce
2022-11-29 14:32:56 +01:00
Zuul 5a2f223ea5 Merge "Use Ansible 5.x" 2022-07-05 14:32:01 +00:00
leiyashuai a5ceb4060c Drop lower-constraints.txt and its testing
As discussed in TC PTG[1] and TC resolution[2], we are
dropping the lower-constraints.txt file and its testing.
We will keep lower bounds in the requirements.txt file but
with a note that these are not tested lower bounds and we
try our best to keep them updated.

[1] https://etherpad.opendev.org/p/tc-zed-ptg#L326
[2] https://governance.openstack.org/tc/resolutions/20220414-drop-lower-constraints.html#proposal

Change-Id: Idaba23e5308bb91915370f36a085ed26c03d7cfd
2022-06-04 12:05:35 +08:00
Riccardo Pittau 969a5e623f Use Ansible 5.x
Support most recent version of Ansible up to 5.x as default.

Change-Id: Ia2e9c78c56f6d0314471973e71de0b45e3309d71
2022-06-01 11:27:21 +02:00
Riccardo Pittau 208135359d Bump ansible lint to latest version
Keep the version to 5.x for the time being

Change-Id: Ifcf33e79ced1ec6e679847cb1c4130d8b5ba224b
2021-10-25 14:34:49 +02:00
Michal Nasiadka 72ad77f914 Bump up Ansible to 4.x
As per [1] and [2] - Ansible versions prior to 4 are not maintained.

[1]: https://docs.ansible.com/ansible/devel/reference_appendices/release_and_maintenance.html#ansible-community-package-release-cycle
[2]: https://docs.ansible.com/ansible/devel/reference_appendices/release_and_maintenance.html#ansible-core-release-cycle

Change-Id: I06cf6723361010e0a7c6eb07f2d9e570192cd9a4
2021-10-22 08:05:07 +00:00
Dmitry Tantsur 6cf3c7beb6 os_ironic_node_info: fix TLS and potentially other issues
The current implementation does not respect ca_cert and potentially
other parameters that are commonly used in OpenStack modules.
This change makes it use the existing utilities from the collection.

Change-Id: I865142d1679bbc9459a460e0d7351e5c6158e5b8
2021-08-25 15:56:24 +02:00
wu.shiming 89e5af8d92 Changed minversion in tox to 3.18.0
The patch bumps min version of tox to 3.18.0 in order to
replace tox's whitelist_externals by allowlist_externals option:
https://github.com/tox-dev/tox/blob/master/docs/changelog.rst#v3180-2020-07-23

Change-Id: I3f89ab28b73e04da1ccde6c3acb2eebb25f36396
2021-05-31 09:31:17 +08:00
Dmitry Tantsur 5a76f5429b More compact README.rst
This file is included from the main documentation, so make it
smaller. Remove a separate MISSION.rst, nobody is going to read it.

Update the links to look more uniform.

Change-Id: I9b88faaad5ad0ccc85a7660d8cd7e8d20f3ed120
2021-02-17 12:45:38 +01:00
Zuul ea0015c86e Merge "Update version of doc8" 2021-02-08 19:09:22 +00:00
Riccardo Pittau c9c1762755 Update minversion of tox
The minimum version since when tox accepts having inline comments
in deps is 3.9.0

https://tox.readthedocs.io/en/latest/changelog.html#v3-9-0-2019-04-17

Change-Id: Ibe03e0aeac8bab767e9897b9c34d9a954a0d678e
2021-01-23 18:26:53 +01:00
wu.shiming 57a4f1bf2f Update version of doc8
The doc8 lib supports Py36 starting from version 0.8.1

Change-Id: I764f2b44de62d79fddc0a1d139b9b3f9ee270e5c
2021-01-18 16:48:10 +08:00
Dmitry Tantsur 75f528fded Avoid a full install in tox environments that do not need it
Usage of usedevelop=True results in all requirements.txt dependencies
always installed (without constraints) even when requirements.txt
is not explicitly added. Override usedevelop for these environments.

Change-Id: I71ec737454fa42775168a0df948ba9bbb1379dcc
2020-12-14 14:09:35 +01:00
Dmitry Tantsur 95b69e2bbc Fix two CI issues
* Fix lower-constraints with the new pip resolver

  First, remove pep8 dependencies from test-requirements, they're not
  needed there and are hard to constraint properly.

  Second, bump keystoneauth to the version required by openstacksdk.

* Force updating libgcrypt to work around CentOS/RHEL 8.3 bug
  https://bugzilla.redhat.com/show_bug.cgi?id=1840485

Change-Id: I65379a3d1b42e3607118bd785f580604bef7d10d
2020-12-08 17:09:05 +01:00
Zuul c73715210e Merge "Update TOX_CONSTRAINTS_FILE" 2020-11-04 13:45:58 +00:00
Dmitry Tantsur fd530ac5aa Support Ansible 2.10
No code changes required, but the linters job needed fixing since now
it tries to automagically load the collections in playbooks/collections
and fails with "relative resource paths not supported".

Change-Id: Ifa99a4bccc52f095c057a082fbe3d15a1633de9f
2020-11-03 11:31:14 +01:00
wu.shiming 810370b54c Update TOX_CONSTRAINTS_FILE
UPPER_CONSTRAINTS_FILE is old name and deprecated
-https://zuul-ci.org/docs/zuul-jobs/python-roles.html#rolevar-tox.tox_constraints_file
This allows to use lower-constraints file as more
readable way instead of UPPER_CONSTRAINTS_FILE=<lower-constraints file>.

[1] https://review.opendev.org/#/c/722814/

Change-Id: I78da82383bb9de31fa39c59e87efd655e40b3e58
2020-11-02 16:04:33 +08:00
wu.shiming 8cce676a64 Remove install unnecessary packages
Change-Id: I037ae51fc376809872b63f29c4803e043b7d1efd
2020-09-11 16:45:03 +08:00
Dmitry Tantsur 6f825b0241 Add a CI job with ansible-lint
The implementation is copy-pasted with some tweaks from project-config
CI jobs. A list of exclusions is currently huge and should be reduced.

Change-Id: I7811884caa5d6c46e42bc4d1638ccaa4d17910b7
2020-08-24 13:15:34 +02:00
Riccardo Pittau df9c0d4460 Set min version of tox to 3.2.1
As recommended, since version 3.2.0 tox switches pip invocations
to use the module -m pip instead of direct invocation.
We set min version to 3.2.1 [1] to also fix the behavior of
--parallel--safe-build

[1] https://tox.readthedocs.io/en/latest/changelog.html#v3-2-1-2018-08-10

Change-Id: I8ff1d620d5ab7608847fd4ac03a06168e3d1db2d
2020-07-15 15:36:30 +02:00
Riccardo Pittau 556ce37df6 Upgrade flake8-import-order version to 0.17.1
Full py3 compatible version.
Add all Python3 modules to stdlib list.
Also includes fix to an enum34 dependency bug.

Change-Id: Ie260ace9bc1d8d5bc89e346c5eb4007fbbed2d14
2020-04-21 16:20:29 +02:00
Iury Gregory Melo Ferreira 2e5715ec34 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.

openstack-discuss thread
http://lists.openstack.org/pipermail/openstack-discuss/2020-April/014237.html

Change-Id: I22eb2dc7935b529301c3608ac81d6b60998014fb
2020-04-17 21:20:32 +02:00
Andreas Jaeger fdcbfb8365 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Fix problems found.

Change-Id: I2707a1f2047f89d9f12ea282cec98411454e1f79
2020-03-30 10:18:15 +00:00
Riccardo Pittau db3d46a7d3 Switch to stestr
Use stestr for tests.

Also clean tox.ini and add check for flake8 H106:
Don't put vim configuration in source files.

Change-Id: Ia76961a091688372c6df363d5e1dcb29ff0f39bf
2020-03-17 07:48:42 +01:00
Madhuri Kumari 76c915aca2 Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

Bifrost 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: Ia175fc588f283e33efe2961f006c35c4ecc255b1
2020-02-02 11:10:11 +01:00
Riccardo Pittau d2718f45e3 Enforce running tox with correct python version based on env
All the tox tests run with the default python
version available in the system.
This is not quite correct when running on environment such as
py36, py37 or py38, since they imply running with different
Python versions based on the environment.
To enforce the correct version we need to add the option
ignore_basepython_conflict available since tox 3.1.0 [0].

[0] https://tox.readthedocs.io/en/latest/config.html#conf-ignore_basepython_conflict

Change-Id: I113c66802523de3ef64bdc08c61e7b2f36633dc3
2020-01-09 10:28:59 +01:00
pengyuesheng 1073947e10 Update the constraints url
For more detail, see http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: Iad98ec58cc6c425a32d9bb7f4d10d4497968491c
2019-09-25 14:44:08 +08:00
Kaifeng Wang 0bc77a53c0 Build pdf doc
The is one of community goals that each project could produce a
single PDF file. The pdf should be in the output of openstack-tox-docs
job.

TeX packages are required to build PDF locally, following is recommended:

* inkscape
* texlive-latex-base
* texlive-latex-extra
* texlive-fonts-recommended

More about the goal:
https://governance.openstack.org/tc/goals/train/pdf-doc-generation.html
https://etherpad.openstack.org/p/train-pdf-support-goal
https://etherpad.openstack.org/p/pdf-goal-train-common-problems

Change-Id: Iebca5c4cc8dfdecf7c561b3612691b62ca4ac0c8
2019-09-06 10:13:32 +08:00
Kaifeng Wang 5f31be7e7e Add proxy envvar for tox
Spotted when generating pdf, due to no internet connection, the svg
image is not downloaded, and the pdf is generated. But unlucky for
Riccardo because he is lucky for not behind a proxy :)

Change-Id: I702d96baa41dce74a1bc5c065146adadec979623
2019-06-19 10:29:44 +08:00
Kaifeng Wang 563dab994c Update Python 3 test runtimes for Train
One of train goals to have consistent python3 jobs.

https://governance.openstack.org/tc/goals/train/python3-updates.html

Change-Id: Id4575d1c06dc2e638d40a3364fa30c47edfe1cf9
2019-06-13 14:18:33 +08:00
Monty Taylor ec852a3fad Update links for opendev
The most important bits are updating shade references to remove
the openstack-infra. The other git urls will work through the
redirect, but cleaning them up is just nicer.

This removes two comments that reference files that no longer
exist due to config generation.

Also, fix some random use of github for cloning openstack repos,
since the github mirror is best-effort only.

Change-Id: I55a1d9db940cf5fa2c35421db7add015ae334563
Needed-By: https://review.opendev.org/654056
2019-04-22 17:16:46 +02:00
Riccardo Pittau 2c5e6af70c Removing python3.5 tests in favor of 3.6
This patch changes the tox env from python 3.5 to python 3.6

Change-Id: I5cdda8d2af7f7a96a748a89113f4b6bb042f630b
2019-02-25 14:43:45 +01:00
Jim Rollenhagen b2e9584421 Add doc/requirements.txt to releasenotes tox environment
Without these dependencies, the releasenotes build does not actually
work.

Change-Id: I0d10a6318045c9d9293a45a86799b5e85dbcc5b3
2018-08-13 11:12:24 -04:00
Nguyen Van Trung 460a8f6be3 Follow the new PTI for document build
For compliance with the Project Testing Interface as described in:
https://governance.openstack.org/tc/reference/project-testing-interface.html

For more detials information, please refer to:
http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html

Change-Id: I3eb92c968ece3c15eeae59bb6ef9492f3d03eeed
2018-07-10 16:33:42 +00:00
huang.zhiping c4ce1cee87 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: I4fedeea783be39c04ee628e8f53b6cecde9a9054
2018-06-19 08:22:35 +00:00
Nguyen Van Trung ac079bfa37 Allow to check pep8 along with D000
This commit going to remove --ignore D000 which had raised
following issues:

"D000 Cannot analyze code. Pygments package not found."

And they also fixed in https://review.openstack.org/#/c/568729/
Depends-On: https://review.openstack.org/#/c/570236/

Change-Id: I3f35c65d385dc65ccefbac608498ad85ff4a4d71
2018-05-24 01:31:51 +00:00
Doug Hellmann edb9ee31bf 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: I45e5002c7edd44b828bfe057762ff98bd2fcec4e
Depends-On: https://review.openstack.org/555034
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-03-22 09:41:46 -04:00
Nguyen Van Trung 7047a329b5 Add doc8 into pep8 check to scan rst files
This change will help fix pep8 issues of all *.rst files
in the project and checking for new files.

Change-Id: Ib06aeb7fa76bd387d76c23bc3f8ecca89332d989
Co-authored-By: Hoang Trung Hieu <hieuht@vn.fujitsu.com>
2017-11-29 13:13:15 +07:00
bhavani.cr 5eeed0b262 Added the py35 env
The gating on python 3.4 is restricted to <= Mitaka.
This is due to the change from Ubuntu Trusty to Xenial,
where only python3.5 is available.
There is no need to continue to keep these settings.

Change-Id: Ide64ca514ec779074926fe527a8eaa70ec1bfcb9
2017-06-26 10:22:17 +05:30
iswarya_vakati dfb4f0b78d Pass located tests directory in oslo debug
According to [1], we can passing a "-t" argument to
oslo_debug_helper to indicate the directory where tests
are located. This will solves ImportError exception.

[1] https://docs.openstack.org/developer/oslotest/features.html

Closes-Bug: #1666560

Change-Id: Ia85c2b5ac21ebfdb098c1c0d8f6ac984cb2d6e4d
2017-03-13 11:01:49 +00:00
Pavlo Shchelokovskyy c158a837c5 Ignore upstream Ansible modules in pep8 tests
The 4 modules that bifrost will download from github if needed for older
Ansible versions are maintained by Ansible community and do not confirm
to OpenStack code style guides.

Add them to flake8 ignore list to not spam pep8 test results when running
tests on a live bifrost installation with those modules already downloaded.

This will not affect the gate pep8 job as those modules are missing from
the bifrost code tree anyway.

Change-Id: Ibf5ad902b65195bcc73755112a05332fe8615d9d
2017-02-16 10:20:38 +00:00
Julia Kreger 92c996d471 Add py35 to tox env list
py35 was never added prior to py34 being removed.

Change-Id: I972e090804aa28487c1f13b73a110f238cfd8688
2017-02-10 19:50:17 +00:00
Jenkins 7df248570b Merge "Remove support for py34" 2017-02-08 12:52:23 +00:00