This updates the version of hacking we are using for our linting and
addresses various issues that the latest version flags.
Change-Id: I95ed73411e96451bc447e1b5858b0466fb8f10a9
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
During validation we need to build a bdist_wheel which is only available
as an extension when wheel is present in the environment. This adds
wheel and makes sure all requirements are installed for the validation
job.
Change-Id: Ied3b1ff4accf66e358cec4b209f4d3a65ae88d26
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
Update docs building:
* Remove unneeded doc sections from setup.cfg
* Change constraints to use published document, use
new variable
* Import mock from unittest, remove imports from future
Change-Id: I8f33d4c0bf5fcba203d410cd021c548219a757ec
This makes sphinx-build use the number of cores available to make the
docs build parallel. On my 16 core system, this cut the time by ~50%. We
don't have as many cores available in the gate, but it should provide a
slight improvement in overall job time.
Change-Id: I7ad4d87a3dba10475a0fcf797a9aa2d4b1ad0eb5
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
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. Remove the useless install_command
parameter.
Change-Id: I25a43f463dbfac59a193774d6f90b0ddb73f5268
I am not sure we really need to care about a line length that's 90
chars instead of 79. We have so many ugly things here, I am not
sure this will impact positively the readability to force line breaks.
Without this patch, all the shell scripts changes will fail with
a bashate failure, due to the fact that the
recently introduced changes in tools/make_missing_releases.sh
have lines of length above 79.
The alternative would be to fix those lines. There are only 3 of them.
Change-Id: I5fc7bde3c60c50ae78e3c7f297f715a7591e486c
This is the first step into automating PTL/liaison approval.
This tool will check that PTL/liaisons either authored the change or
approved it.
Change-Id: I1bbb371997e9e92f39eff47adb4d3d176af35de7
We use release-types as a way to verify that versions are compatible and
if needed reflected accurately in the code (puppet, xstatic). If one
isn't set explicitly then we assume python-service.
In certain circumstances (anything other than the first release in a
series) we also perform python specific requirements checking on all
'python' types.
Add a new 'generic' type that uses the same rules to validate version
numbers but wont run any python specific checks.
We need this a projects (like monasca-thresh) will fail the requirements
check for 2nd or greater releases[1].
An alternate would be to have the requirements code check if setup.py
exists before calling it but that seems like the wrong layer to me.
[1] http://logs.openstack.org/54/652854/1/check/openstack-tox-validate/80df01c/job-output.txt.gz#_2019-04-16_06_08_00_636538
Change-Id: I3fcde5eb266f954fddb6871ce8690b93b8fd7a8d
As we add more branches and tags we don't want to manually add tests for
them (and we'd need to or the docs build will fail with an 'Untested
Rule'.
Use the redirections data that we use to generate the htaccess file to
also generate the tests.
Also I removed the debug output as it it's assertion is incorrect we can
actually get the .htaccess file from the docs job \o/
Change-Id: Ib5d35169e68cd92b666a35705d8e36942bd28b89
Instead of statically listing the redirections move to a dynamic model.
We move the existing _extras/.htaccess to _templates/htaccess so we have
some control and safety of what goes in there. Connect 'build-finished'
from _exts.deliverables.py to trigger generating the redirects. Doing
so here avoids re-reading the data as deliverables.py ahas already done
that for us.
Change-Id: If6bd59fd478593a84ebcedc3a50af3720d620d3c
This script will compute a list of deliverables present in
governance but unknown to release management, for manual
processing.
Change-Id: Ibebf777911416d978ecea5ba8d7b25b211e7ae52
Quotes around {posargs} cause the entire string to be combined into one
arg that gets passed to stestr. This prevents passing multiple args
(e.g. '--concurrency=16 some-regex')
Change-Id: Ia7e151422b69f8dc8b0bd0f05eb72343f1221520
Use the sphinx wrapper around logging instead of app.info().
Add a -v option to sphinx-build to see the output.
Change-Id: Ia698929c252a2a19da812e399011341a41976540
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Capture stdout, stderr, and log output so that when a test fails we
have all of the info we need to debug it.
Change-Id: If3cc9e800dc4a166af96a5fd07903b918e5d3499
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
According to Openstack summit session [1],
stestr is maintained project to which all Openstack projects should migrate.
Let's switch to stestr as other projects have already moved to it.
[1] https://etherpad.openstack.org/p/YVR-python-pti
Change-Id: Ifbcb65237598b99224768a47c18b30473c2eaa3e
We've run into problems because we weren't maintaining older
deliverable files as we extended the schema. This change moves schema
validation out of the main validation command so it runs as a separate
step and processes all deliverable files by default. The more complex
validation rules are still only checked for files being modified in a
given commit.
Change-Id: I4b69ca3c59da6606cf2b27d05c8846223d52998a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Since the shade team is renamed, redirect the old team page location.
Change-Id: I7cc485365ef370ebc724c51557dd2c77b9e8c75e
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
We had previously installed our docs dependencies as extras in
setup.cfg. Doc jobs are now changed to not install the project,
so these dependencies are no longer being installed.
With recent changes to the doc jobs, we need to specificy that python3
is used. Update the zuul config file for this.
Change-Id: Ie925efefb1126dbe7fa0a9f0f1727da01f48c512
Depends-on: Ib882a4d09898ff206b36ac8aef840bee0748368e
Adjust the tox log wrapper so it works with the full path to the
script for running yamllint, then add it to the step for running
yamllint so the results are logged to a separate file.
Change-Id: I98561e17e4fa76aeee9adfd57d9e71a7f229e536
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Make the validate job log to a separate file like list-changes does so
we can find the output more easily instead of reading through all of
the zuul output.
Change-Id: Ib5286384aca2b126b9cad93084aaef873883d20a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Having the rather complex output of list-changes mixed in with the
main job log can make it difficult to read. Continue to include the
data in the main log file but also write it to a separate file that is
easier to consume.
Change-Id: If4d3b56c76b2bf513b2d44ffedf5825f562f4bfb
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
list-changes now needs to be able to add a temporary tag to build the
release notes. Adding the tag requires identity information not previously
required for other git commands, and git needs to know where HOME is to
find that info.
Change-Id: Ia9a506bdfa30cf72b48d53a7ec05b0bc939f34a6
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
A lot of the commands in this repo use zuul-cloner in a
subprocess. Using unbuffered I/O causes the stderr from zuul-cloner to
appear interleaved properly with the stdout from the main command.
Change-Id: I87c2a6f49e9c9f307ebe42d23ee79cd6344573bf
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
We don't need to run the linter over every single old deliverable file
every time. Just check the "modern" series that are most likely to
be open, and the _independent projects.
Change-Id: I5207600838c37b241d0ab178080be75a8f31a725
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Use python3 by default, allowing tox to find the best fit (instead of
specifying 3.5).
Needed-By: I8b93b88bb4123d2913554b08c2284a7972e291f2
Change-Id: I8b93b88bb4123d2913554b08c2284a7972e291f2
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Build the docs when the user runs "tox" without args.
Change-Id: I16b683cf82715f0351c7f2ca5c0655b36f5fe4f1
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
The only reason we have a dependency on launchpadlib and
lazr.restfulclient is for the old tool that imported project history
from launchpad. We no longer need the tool, so we can remove it and the
dependency as part of our python 3 port.
Change-Id: Ie87e6172c953df10cb70d34c9bc23ad30e97ce4d
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This configuration makes it easier to work on changes to the tools.
Change-Id: Ic4afe2a811d6eb2163a2590a865b0f56d1474eb8
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Set up commands to run to execute new unit tests.
Ignore output from testr and coverage.
Rename the dist to match the package name so that the testr/coverage
integration works properly.
Add test-requirements.txt with some common testing dependencies.
Change-Id: Ic6f34df893f3981a9af6122456b9feb9c80b31dd
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
There is no this directory openstack/common which was used to keep codes from
oslo-incubator, we have retired oslo-incubator. Removing openstack/commonfrom
all OpenStack code in favor of the Oslo libraries is a project wide goal
for the Ocata release. So don't use this directory any more. We should drop it
for improving searching efficiency.
Change-Id: I38429dd29767afdbf395cbb3777879636ea0ad55
A new update of yamllint introduced new rules that we're failing. Treat
this linter like we do others and pin it, so we can update it and fix
any issues from the new version at the same time.
Change-Id: I51800955a5d25b52910e9a6a9de8578be8519028
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
When running commands using "tox -e venv -- $name" while working on the
missing-releases command, I noticed that changes to the program were not
being installed into the tox environment as I made them and re-ran
tox. These changes fix that issue by having tox always re-install.
Change-Id: Iea132f5fecfc47a0cd4bbb3c7777568da841bf53
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Add an other-requirements.txt file containing a cross-platform list
of dependencies needed for running included tox-based tests. Also
include a tox environment for convenience calling the bindep[*]
utility to list any missing system requirements.
This change is self-testing.
For other-requirements.txt see also
http://docs.openstack.org/infra/manual/drivers.html#package-requirements
[*] http://docs.openstack.org/infra/bindep/
Change-Id: Ib29d02d5ea751f09df26030dcfb9e153ba82661b
The pbr feature for invoking sphinx doesn't let us treat warnings as
errors because of a bug in pbr. Switch to invoking sphinx directly,
including removing the setup.cfg instructions for sphinx, so we can use
the flag to treat warnings as errors. Doing this also requires fixing a
few existing warnings, so those changes are included in this patch.
Change-Id: I2aa0d844855d5a18646d0bc3907620544ae71be2
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
allow longer lines in yaml data files
replace tab with spaces in front of yamllint command in tox.ini
Change-Id: I5da057c4acee79159a3246be7b9bceeb73a52ed6
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Let the validation and list-changes code use the zuul cache directory,
if ZUUL_CACHE_DIR is set or if /opt/git is present (the default for the
CI systems).
Change-Id: Ia6cf24d1361c1112c37e5aeec05546b19798bbbd
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Latest tox causes failures:
File "/usr/local/lib/python2.7/dist-packages/tox/config.py", line 1140, in processcommand
argv = list(shlexer)
File "/usr/lib/python2.7/shlex.py", line 269, in next
token = self.get_token()
File "/usr/lib/python2.7/shlex.py", line 96, in get_token
raw = self.read_token()
File "/usr/lib/python2.7/shlex.py", line 172, in read_token
raise ValueError, "No closing quotation"
ValueError: No closing quotation
This is caused by a backwards incompatible change in tox:
https://bitbucket.org/hpk42/tox/issues/181
We need to work with both older and newer tox versions, so let's remove
the comment at the end of the line
Change-Id: Id5ec8aeb700fcf9a63888e41e408d26b6e3e8481
launchpadlib 0.0.1.dev533 requires lazr.restfulclient, which contains
python2-only syntax (at least as of lazr.restfulclient 0.13.1). On a
system where "tox" uses python3 (eg: Debian "stretch"), the default
basepython will be python3, and venv creation (pip building wheels) will
fail on lazr.restfulclient.
This patch forces basepython=python2.7 across all testenvs.
Change-Id: I44f4c6f819550a8a586ae19bbed45fc9b67dd1c0