7a4114512cbbb70dd656d025813df8868e32f30e
90 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
likui
|
80c3f568bd |
tox: Remove basepython
Python 2 is EOL. No environment should be defaulting to it. Our CI environments certainly aren't. Change-Id: Ib2e4304fc6c95c853570f48690a2d2a4aeeabdbe |
||
|
Jay Faulkner
|
d7234c2be0 |
Upgrade to latest hacking - v6
No code changes needed to comply with newest flake. Change-Id: I256397efe0fbb3e307d808b0eda2e4d72d83f9b0 |
||
|
Riccardo Pittau
|
f2b4ac8751 |
Readd usedevelop true to tox.ini
This avoid using sdist, which is the wanted behavior Change-Id: Ibfb867ee0ff8274130a19538aa7ff9b9296dc4e1 |
||
|
Riccardo Pittau
|
39b6553161 |
Fix for tox4 and setuptools
- Disable auto discovery in setuptools This is to avoid issues with latest setuptools after version 61.0 For more info see [1] - add bash script to allowlist in tox.ini - use default size for vm memory [1] https://github.com/pypa/setuptools/issues/3197 Change-Id: Iae24917add1aae6b1ed46dba0d2c270b39c5698c |
||
|
Jay Faulkner
|
3ded705e56 |
Fixes for tox 4.0
- passenv needed better structure - usedevelop no longer allowed alongside skipsdist Change-Id: I22dae3b1e4cca2dc328c21e889acf7fe98a80e0b |
||
|
Riccardo Pittau
|
f1d45a60e7 |
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: I16ea0a61c018d03d6c23e0b0736295a36b6dd367 |
||
|
Zuul
|
71f54b7f98 | Merge "Increase version of hacking and pycodestyle" | ||
|
Riccardo Pittau
|
22b538d61c |
Add lower-constraints job to current development branch
The lower-constraints test was removed because of an issue where pip could not correctly determine the required packages versions to install, ending in an almost infinite loop that would end up in timeout, failure, and general mayhem. Recently the issue has been fixed and, if properly configured, the lower-constraints test can provide good indication of which minimum versions are required to support the current code. This patch adds the test back to the current development branch, and it runs only on master. The lower-constraints file will stay in the future stable branches. Change-Id: Ic9cef3e56266c6e9de0936b5f113e8b38d705a9b |
||
|
Riccardo Pittau
|
efbbc86f53 |
Increase version of hacking and pycodestyle
Fix H904 "Delay string interpolations at logging calls" errors Change-Id: I331808d0132094faf739998a6984440787d3ebf8 |
||
|
likui
|
5473700f9c |
Remove lower-constraints job
As discussed during the upstream ironic community meeting on Monday Dec 14 2020, the lower-constraints job is being removed. Change-Id: I9392117ccdef8fc6ff3d95d667107d752459cb24 |
||
|
likui
|
e27cdb3673 |
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: I434a6330defbc5cc65788f4d64b7f2d4d2b37db7 |
||
|
Zane Bitter
|
b510d2d4d0 |
unit tests: Capture log output
Debugging unit test failures is very challenging because all of the log output is mixed together. Capture the log messages and store them as part of the test, so that only log messages associated with failures are output, interleaved correctly with the results. This does not capture logs sent to stdout by _early_log(), although that would be a nice further improvement. Change-Id: I01e409ea73ff444e16caae0078e81585c703d5a5 |
||
|
Riccardo Pittau
|
c72e58b2fa |
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: Ice30f3c900dd87c07f29a96cdbeef9899ead6777 |
||
|
Zuul
|
923bded572 | Merge "Avoid a full install in tox environments that do not need it" | ||
|
Dmitry Tantsur
|
88621e1886 |
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. Add missing constraints to the bandit environment. Change-Id: I037dc04ffc4f426c828667df010ebe4e357e7fda |
||
|
Riccardo Pittau
|
67ee66785c |
Upgrade version of doc8
The doc8 module explicitl supports Python 3.6 starting from version 0.8.1 Also remove it from test-requirements as we already have it in tox.ini Change-Id: Idc66758dc350d9a7a09b4295b08f4423cec288dc |
||
|
Iury Gregory Melo Ferreira
|
c327735b39 |
Fix lower-constraints with the new pip resolver
* Remove pep8 dependencies from test-requirements, they're not needed there and are hard to constraint properly. * Add cliff to l-c (same version we have on ironic) Change-Id: I8e7582492276db2308217460af37f691fb99c0ce |
||
|
likui
|
60900d4f22 |
Reuse the docs deps to benefit from constraints
Tox trying to install latest versions for building docs, which may not be supported by stable and lower branches, so should be restricted by respective version's upper-constraints.txt Change-Id: I1e134bb72b6fef3fba8f20d3b3d65520c66bbbf1 |
||
|
likui
|
24a4b13a28 |
Use 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 uppper-constraints file as more readable way instead of UPPER_CONSTRAINTS_FILE=<lower-constraints file>. [1] https://review.opendev.org/#/c/722814/ Change-Id: Ibd7895fe3856a179b9f90104015057a38a062aa9 |
||
|
Dmitry Tantsur
|
7fb098aa0b |
Import example hardware managers from ipa-example-hardware-managers
They're not easily discoverable there, let's keep them in tree. The examples have been restructured to have two different projects ready to be copied and adjusted. PEP8 failures have been fixed. Change-Id: I2af04f4b7f9a2109fe83ec517e716159331a48bb Co-Authored-By: Jay Faulkner <jay@jvf.cc> |
||
|
Riccardo Pittau
|
c66bec0f43 |
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: I6c91e84366dcec7290456eea535a0b2bd3eda4d1 |
||
|
Julia Kreger
|
cf870ae510 |
Fix apidoc build
Change-Id: Id7c5686cdbdc79812e06eb4a5f87eddc75005cc3 |
||
|
Iury Gregory Melo Ferreira
|
2039a5d65b |
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: Idda0a78f63d5bc3e8c9e56e042630c8d28db2162 |
||
|
Andreas Jaeger
|
3e7d44746e |
Cleanup py27 support
Make a few cleanups: - Remove python 2.7 stanza from setup.py - Add requires on python >= 3.6 to setup.cfg so that pypi and pip know about the requirement - Remove obsolete sections from setup.cfg: * Wheel is not needed for python 3 only repo * Some other sections are obsolete - Update classifiers - Update requirements, no need for python_version anymore - Use sphinx-build Change-Id: I8abd764d97a6711d3e6347ec3a7b8967f1512006 |
||
|
Riccardo Pittau
|
96d46aa5bf |
Enforce running tox with correct python version based on env
Since removing support for Python 2, we changed the basepython value to 3. This means that 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: I96758527bbba9d8ec298867390b25be493f57789 |
||
|
Dmitry Tantsur
|
82084730cd |
Remove the configuration sample file
It's horribly outdated and can be easily regenerated locally. A similar change has been done to ironic long ago. Change-Id: I5b7a0079bc90320adc2b4710cdee714d278e543c |
||
|
Madhuri Kumari
|
18862bb5fa |
Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle. ironic-python-agent 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: Ifd0e0b99bb82a7d7e82d6c14309468196f5734fc |
||
|
Dmitry Tantsur
|
fc068f2b0f |
tox.ini: remove the devenv environment
This is what 'venv' is for. Change-Id: I0e2190a9bf7b11537d0931c4e1e970836eb11c01 |
||
|
Dmitry Tantsur
|
91ed55678e |
Fix tox.ini to correctly test lower-constraints
Due to the way we currently define install_command, all test targets are using upper-constraints, including the lower-constraints one. This patch fixes it and adds standard things like passing proxy settings. Change-Id: I61c3b45ae591ea44688f29598cb8b802bb094423 |
||
|
Kaifeng Wang
|
cef3bac3dc |
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: If5446ce4ceee7e38a0052503aa8fc2b6c5d7de66 |
||
|
Kaifeng Wang
|
6f634c358b |
Adds bandit template and exclude some of tests
Adds bandit configuration template and exclude some of tests that we don't want to fix for the moment. Keeping job unvoted so that we can keep an eye on possible issues while not breaking gate. Change-Id: I092d686ba38723d7951e8f06415f28cc809ad365 Story: 2005791 Task: 33563 |
||
|
Kaifeng Wang
|
3352d40907 |
Incorporate bandit support in CI
Change-Id: I2144c284ffcfa696412fca30f59a66c54c3d1965 Story: 2005791 Task: 33564 |
||
|
Pavlo Shchelokovskyy
|
93dae93d52 |
Fetch upper constraints from opendev.org
the imagebuild/common/generate_upper_constraints.sh is currently failing as the curl command in this file does not handle redirects. Instead of allowing redirects, use the proper current link to the upper constraints file. Change-Id: I92c5bfa65ba149687f61172c2a89ff38660a58cf |
||
|
taoguo
|
d4919dc068 |
Update min tox version to 2.0
The commands used by constraints need at least tox 2.0. Change-Id: I4813ed34b22895d59db26d15ee5158de8840628a |
||
|
Chuck Short
|
1036384f74 |
Switch to using stestr
According to Openstack summit session [1] stestr is maintained project to which all Openstack projects should migrate. Let's switch it then. [1] https://etherpad.openstack.org/p/YVR-python-pti Also adjust requiremenst to past the gate checks. Change-Id: If7a0ebd9cca26cb67eb2ec9036d0aa2693fdffbf Signed-off-by: Chuck Short <chucks@redhat.com> |
||
|
huang.zhiping
|
0a668b16da |
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: I3c8e5c663a3fd881430f84fc502e46192de77fc7 |
||
|
John L. Villalovos
|
c09634ad80 |
flake8: Add W503 to ignore list as invalid
W503 according to the [1] pycodestyle docs is not supposed to be enabled. But it is. W503 is something we will likely never enable as it is a personal style decision and can change depending on the code. There is no one right answer. Interestingly there is also a W504 which is the opposite check. [1] http://pycodestyle.pycqa.org/en/latest/intro.html#error-codes Change-Id: I1025f21a57837e97280f82baba50fdd823a190cc |
||
|
Doug Hellmann
|
dc5d6590e2 |
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: I8d773d4ee3d0835fb2a9183fe2154e82db085bd5 Depends-On: https://review.openstack.org/555034 Signed-off-by: Doug Hellmann <doug@doughellmann.com> |
||
|
melissaml
|
c51b34e41e |
Replace curly quotes with straight quotes
Curly quotes usually input from Chinese input method. When read from english context, it makes some confusion. Change-Id: Ife984be980a4235d9b14152143e2b3540e414751 |
||
|
Zuul
|
20a36e1695 | Merge "Use 'functional' tox environment" | ||
|
Ruby Loo
|
64b663719a |
Use 'functional' tox environment
Rename 'func' to 'functional' tox environment and replace custom legacy func job with cross-project 'openstack-tox-functional' job. Change-Id: I2a774a0a9870163457d1e7bc9c2976a9680ace01 |
||
|
John L. Villalovos
|
1128a26cb4 |
tox: Don't create *.pyc files during unit/functional tests
Don't create *.pyc files during unit/functional tests as they just add cruft during tox runs. This is similar to what we already do in openstack/ironic Change-Id: Id4364519903db20308f78f2aaeca3ad2d37b298a |
||
|
John L. Villalovos
|
4d1272b171 |
tox: Use the default version of Python 3 for tox tests
When running the tox tests, use the default version of Python 3. Instead of having to update the Python 3 version as we move from py34 -> py35 -> py36 -> py37 -> py38 Just use the default version of Python 3 on the system. This will not affect what gets run in the gate, as the version is explicitly specified when it runs there. This is for developers who run the tests locally. Change-Id: I005d85b7d8f84f5471db3c3da279c5cf9cf13d4e |
||
|
John L. Villalovos
|
e082559046 |
Fix for broken zuul v3 job and releasenotes
The Zuul v3 job is looking for the log files from the release notes in: .tox/releasenotes/log/ but we had then in .tox/venv/log/ Fix it to where the Zuul v3 job expects it to be. Also updated the 'docs' job, even though job isn't failing. If the job did fail, with current setup, no log files would be copied which would make debugging more difficult. This change will make it so the log files are copied. Change-Id: I5c036db1a9e94ca28e26fd7b45475d52223f5f0e |
||
|
John L. Villalovos
|
0ef540fc20 |
Migrate to stestr as unit tests runner
Recent update brought os-testr 1.0.0 that already uses stestr test runner instead of testrepository. This patch migrates those places using testrepository to using stestr. Inspired by the patch of the same name in openstack/ironic Change-Id: I2c1b271550629437627f3f62b6f33e2beb2b3c4b |
||
|
John L. Villalovos
|
b67f9c1298 |
flake8: Enable some off-by-default checks
Enable the following off-by-default checks: * [H204] Use assert(Not)Equal to check for equality. * [H205] Use assert(Greater|Less)(Equal) for comparison. * [H210] Require ‘autospec’, ‘spec’, or ‘spec_set’ in mock.patch/mock.patch.object calls Increase the version of hacking in test-requirements so that can use new off-by-default checks. No changes to code were required. Change-Id: I98aa484dc5414ee49c281dfd40e44b3c613d53e0 |
||
|
Mateusz Kowalski
|
8891018897 |
Use standard quote character
On some platforms using ’ instead of ' causes problems for tox to be run. This patch fixes this at the same time not causing any readability issues. Change-Id: Icf8e4a9aa42dce64afb0d15ca7ff005478dbbfa7 |
||
|
Julian Edwards
|
393d686638 |
Add a debug tox environment
Uses oslo_debug_helper to run up the tests in single-threaded mode so that pdb works. Examples: # Run all tests. tox -e debug # Run a specific test or set of tests. tox -e debug module.to.my.test Change-Id: I272f6aa34bafcd7ac2d2828cbd6dd48e0e615b79 |
||
|
John L. Villalovos
|
e9344077fc |
flake8: Specify 'ironic_python_agent' as name of app
Specify 'ironic_python_agent' as the name of the application for the flake8-import-order plugin. That way it knows that imports of ironic_python_agent should come after external libraries. Change-Id: Id39d558a51aeb97d96633afea28676634547d0d7 |
||
|
Annie Lezil
|
a07c855498 |
Python 3.4 (py34) is removed from tox envlist
Python 3.4 is not a supported python version. So removing it from tox envlist Change-Id: If4adb371dc5af023399f806ac6678f114a3f6a2f Related-Bug:1667312 |