199 Commits

Author SHA1 Message Date
Takashi Kajinami
b452ea7089 Skip test_stack_update_with_replacing_userdata
This test case is frequently failing because of a known libvirt issue
in Ubuntu Jammy. We already disabled one functional test case, but will
disable this test case as well, to reduce failure rate of CI runs and
unblock gate.

The existing skip for a different test case[1] is re-implemented using
the proper configuration knob.

This also fixes tox.ini to adapt to new tox 4.0.
 - Update how passenv is defined because space-separated list is no
   longer allowed. Also the values are not case sensitive.
 - skipdist=True breaks installation so is removed.

[1] https://review.opendev.org/c/openstack/heat/+/866545

Co-Authored-By: Rabi Mishra <ramishra@redhat.com>
Related-Bug: #1998274
Story: 2010487
Task: 47056
Change-Id: I915dc83ccde6b6b8497642857292f9974fd84e98
2022-12-23 13:26:52 +09:00
rabi
38238b88f7 Fix tests for fixtures 4.0.0
This fixes ForeignKeyConstraintFixture for the db
tests. Also drops install_command from tox.ini.

Change-Id: I3d0abf68cae89566f4d346cd16919a6050168130
2022-06-27 22:41:52 +05:30
Zuul
2311cdf959 Merge "Changed minversion in tox to 3.18.0" 2022-06-21 21:02:40 +00:00
Zuul
44dd85dbcd Merge "Update python testing as per zed cycle teting runtime" 2022-06-13 12:14:26 +00:00
LeopardMa
e2425a94a6 Update python testing as per zed cycle teting runtime
In Zed cycle, we have dropped the python 3.6/3.7[1] testing
and its support. Removing the py36 centos8 job as well as
updating the python classifier also to reflect the same.

[1] https://governance.openstack.org/tc/reference/runtimes/zed.html

Change-Id: I5073a67df7a0b73dac21de4302743712f5541941
2022-06-04 11:39:19 +08:00
wu.shiming
2a7a8cb0e0 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: Ia986290812e8f577cb89477d20a169f8aafd91df
2022-05-22 13:48:40 +00:00
Ghanshyam Mann
49cbb92ed6 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: I703229320320295b4a90e72c543f8959f85daaa9
2022-04-30 15:41:05 -05:00
Ghanshyam Mann
d5ef98b88e Updating python testing classifier as per Yoga testing runtime
Yoga testing runtime[1] has been updated to add py39
testing as voting. Unit tests update are handled by the
job template change in openstack-zuul-job

- https://review.opendev.org/c/openstack/openstack-zuul-jobs/+/820286

this commit updates the classifier in setup.cfg file.

[1] https://governance.openstack.org/tc/reference/runtimes/yoga.html

Change-Id: I573f6f4f4a9257a4c9c25a9d61a9ea29267377d1
2021-12-14 02:48:30 +00:00
Ian Wienand
bf9186a37e Fallback to upstream for Fedora image
OpenDev infra only keep around the latest two Fedora releases in their
mirrors.  Probe for the image from the local test mirror, but if not
found, fallback to upstream.  This will be much less reliable, but can
avoid gate breakage until new images can be used.

Also, use endpoint_type when creating keystoneclient

Keystone admin endpoint has been removed from devstack with[1].
This would use the public endpoint by default.

Change-Id: I96ab14871ee8c5d5b83cc0cd4abc840ef0218ca8
2021-11-12 15:32:19 +05:30
ramishra
f4ab9d0bc0 Fix multiple gate issues
- Remove B322 bandit from exclusions
- Fix tests for db resource update exposed by SQLAlchemy>=1.3.21

Change-Id: I18efbbbe211a42325a946f5ca74b4e26bfb3316e
2021-01-06 16:56:52 +05:30
likui
a5e3ebe76e 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: I68d6faca20e5d8f1523dbd9f3e4f077a2680aa18
2020-11-24 17:06:37 +08:00
zhoulinhui
e9671342a6 Dep's should be restricted by upper-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: Ie0eaeae33065386abb003831feac6ab90cba09bf
2020-10-06 22:10:37 +08:00
ricolin
3709d0887d Mark support for python3.8
Change-Id: I3f79b7b5a32ad16ea5cd5f70b9e98bb21682a9cc
2020-09-18 05:10:55 +00:00
Andreas Jaeger
37a83c1ede pep8: Enable E226
Enable
"E226 missing whitespace around arithmetic operator"

And fix problems encountered.

Change-Id: I90cbf6220f487a0808e13cd3998c8127be563498
2020-04-30 16:42:53 +02:00
Andreas Jaeger
7f770b95b8 Update pep8 rules
Remove E402 from flake8 list, issues are fixed or addressed with noqa.
Remove E305 as comment, the warning is enabled.
Enable E241 and fix all problems

Change-Id: Ifd2bbce98be4206908da769df686a370328c7ee1
2020-04-30 16:33:43 +02:00
Hervé Beraud
c9eaca9e59 Prepare the six and python 2.7 support dropping
With python 3 the input function is safe.
The six dropping will re-introduce the usage of the input function
and bandit checks will fails.

We drop python 2.7 support so we ignore the bandit check B322 [1] before
starting to drop six support.

[1] https://bandit.readthedocs.io/en/latest/blacklists/blacklist_calls.html#b322-input

Change-Id: Ie956a65ebc4c781c5e661e8021f674833be8b323
2020-04-22 12:23:44 +02:00
Zuul
d4c7e27a7e Merge "Fix hacking warnings" 2020-04-18 23:00:18 +00:00
Zuul
c83e37f26c Merge "Update hacking for Python3" 2020-04-18 12:44:22 +00:00
Andreas Jaeger
57eb87149f Fix hacking warnings
Fix some warnings found by hacking and enable them again.

Change-Id: Ia09de4d0fda752a009b9246b4e6d485601cd9562
2020-04-16 06:43:27 +00:00
Andreas Jaeger
a27dc56f52 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Update local hacking checks for new flake8.

Ignore new warnings, they will be fixed in followup.

Remove hacking and friends from lower-constraints, they are not needed
to be installed at run-time.

Add Pygments to lower-constraints to pass requirements-check.

Change-Id: I20da1309e4d65707130fe517f013d3ed625bf94c
2020-04-16 08:41:49 +02:00
Pavlo Shchelokovskyy
31ea2fcde1 Fix genconfig tox env
we no longer keep configuration for in-repo integration tests in the
repo, relying on heat-tempest-plugin instead.

As a result, currently the `tox -egenconfig` is broken as it tries to
generate config sample calling non-existing config.py module.

Change-Id: I48685d7c791d98db83a7cbcf4ef926ee25ca62a4
2020-04-09 09:12:09 +00:00
Andreas Jaeger
97db901658 [ussuri][goal] Finish dropping python 2.7 support
OpenStack is dropping the py2.7 support in ussuri cycle.

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

This change cleans up:
* remove old requirements
* remove universal wheel building, we don't need this for py3
* cleanup setup.py
* tox.ini: move basepython around; remove install_command since the
  default is fine and constraints should be in deps; add
  ignore_basepython_conflict

Change-Id: Ife0a696ca62be21d3d93c5d8279a412578f62697
2020-02-06 18:58:12 +01:00
Zuul
28ce9f3ad4 Merge "tox: Keeping going with docs" 2019-12-20 05:26:43 +00:00
Zuul
55d7b1327a Merge "PDF documentation build" 2019-12-05 06:20:45 +00:00
Zane Bitter
e0dbb3f7fa Drop Python2 support
Change-Id: I6f248dfd82502ef225ba755246c2de385d30f4b2
2019-11-06 16:55:41 +08:00
caoyuan
eb10545b37 tox: Keeping going with docs
1. Sphinx 1.8 introduced [1] the '--keep-going' argument which, as its name
suggests, keeps the build running when it encounters non-fatal errors.
This is exceptionally useful in avoiding a continuous edit-build loop
when undertaking large doc reworks where multiple errors may be
introduced.

2. Add whitelist_externals to fix the warning

[1] https://github.com/sphinx-doc/sphinx/commit/e3483e9b045

Change-Id: I47683ab1313981a8202afe6b3fe1779d40340452
2019-11-01 11:30:12 +08:00
matthew-fuller
debff05779 PDF documentation build
This change provides the necessary modifications to enable
building of pdf documentation. The resources.py extension
required modification to:
  - prevent attributes from being rendered as stray \items
    outside of a list environment
  - prevent update policies from being rendered as stray
    \items outside of a list environment
  - remove the 'Note:' admonition around the 'Not implemented'
    message when it applies to a sub-property, such as a list.
    The admonition was not rendered as a list item, causing the
    build to fail due to an empty list.

Change-Id: Id4e533430600b5ff03fd63cdc09b9a00741b8e4e
2019-10-01 08:57:22 -07:00
Andreas Jaeger
208cdfea39 Update api-ref location
The api documentation is now published on docs.openstack.org instead
of developer.openstack.org. Update all links that are changed to the
new location.

Note that redirects will be set up as well but let's point now to the
new location.

For details, see:
http://lists.openstack.org/pipermail/openstack-discuss/2019-July/007828.html

Change-Id: I69a41aa850c87e92bf5c3e7fed32e0e961a3c6d3
2019-07-22 18:55:34 +02:00
Elod Illes
d116b21696 Add local bindep.txt
As it was announced [1] global bindep-fallback.txt was removed and now
projects need to have a local bindep.txt to be able to install binary
dependencies for testing.

In test jobs the script tools/test-setup.sh is called which requires
mysql and postgres servers and clients to be installed.

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-June/007272.html

Change-Id: If9befe4115c64c2fda52321002ba5fe1124eaf7c
2019-06-26 17:48:15 +02:00
ZhongShengping
f66dac5c63 Update Python 3 test runtimes for Train
This goal is to implement the process set out in the 2018-10-24 Python
Update Process TC resolution[1], for the Train cycle to ensure unit
testing is in place for all of the Tested Runtimes for Train[2].
In practice, this generally means adding unit tests for Python 3.7 and dropping
unit tests for Python 3.5. Using the Zuul template for Train will ensure that
all projects that support Python3 will be tested against the agreed runtime
versions, and make it easier to update them in future.

[1]https://governance.openstack.org/tc/resolutions/20181024-python-update-process.html
[2]https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: I62abb218bb314345dd7da1cbf9133d10db9696ff
Depends-On: https://review.opendev.org/#/c/641878/
2019-05-09 17:35:06 +08:00
Zuul
38e43a0071 Merge "Dropping the py35 testing" 2019-05-04 16:01:58 +00:00
Rabi Mishra
86e41a8a8f Fix upper-constraints.txt url
Wrong link used in commit 203bce9cd7449ef09a8777a4761f71518da3ed72.

Change-Id: I90cf7584830afccdd0028b0ed7e5061e67430815
2019-04-24 08:52:03 +05:30
ricolin
203bce9cd7 Switch to use opendev.org
Our cgit instance will be going away and opendev.org is the new
preferred URL for browsing our git repos. Redirects will exist for the
foreseeable future, but it's more efficient to just go directly to the
new locations.

Change-Id: Ic5fa1a8436f57836ad37b752a0cca1cd4f3a21a7
2019-04-22 09:36:50 +05:30
Ghanshyam Mann
132457d447 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

[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: I9ab70c74eeff509410d90f4305af116d83420f45
2019-04-14 21:54:27 +00:00
Rabi Mishra
87b4a92a62 Fix lower-constraints tox env to use proper constraints
- Bumps some of the lower constraints
- Fixes common/endpoint_utils.py to fallback to use auth_uri.

Change-Id: Ief0868d5feef3ee6b0689c6be27649ff009fbbcc
2019-04-10 09:11:56 +05:30
Doug Hellmann
8ae5f8657b change the dist name to 'openstack-heat'
We are updating all Python projects to publish artifacts to PyPI. The
name "heat" is already taken there by another project, and they have
rejected our request to claim the name. We therefore need to change the
dist name used to package heat. We have some other projects publishing
using an "openstack-" prefix, so I propose using the name
"openstack-heat". This will not change the imports or anything else
about how the code works, just how it is packaged.

Add a grenade plugin for upgrading between the packages with different
names so that we can clean up the old version of the code and avoid
discovering the heat plugins multiple times in different locations.

Change-Id: I59b55cffd9e648f842eb286b936f09c5b55a76db
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-11-01 11:54:05 -04:00
Nguyen Van Trung
d60514f86e Don't quote {posargs} in tox.ini
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: Iccbd680731592abab4980a51aa97c60d6ef95005
2018-10-09 10:13:15 +07:00
Zuul
fc2e49d834 Merge "Support py36 for test in tox" 2018-09-05 21:33:23 +00:00
ricolin
7991199542 Support py36 for test in tox
Ubuntu Artful and  Fedora 26 already ship Python 3.6 by default
(And Bionic and F28 have been released since then.). Considering
better support of python3 with system, we should enable py36 for test
environment.

You can find some discussion in:
http://lists.openstack.org/pipermail/openstack-dev/2018-June/131193.html

Depends-On: https://review.openstack.org/#/c/597267

Change-Id: I0187e862c0b74dbb836d36e7062ccc9e47a51cc2
2018-08-29 04:38:22 +00:00
Dao Cong Tien
e8824a2c93 Adds doc8 check to pep8
This patch adds doc8 check for .rst files to pep8.
Files that fail doc8 check are also fixed.

Ignore D001 of doc8 check. This requires lot of changes and
should be done in a separated patch.

Change-Id: I7732abc55ec27026efbf56663ba02ff27e8ec847
2018-07-26 14:57:58 +07:00
Zuul
bea5084ea8 Merge "Docs: Eliminate warnings in docs generation" 2018-07-23 16:43:14 +00:00
Zuul
f08a2f0134 Merge "fix tox python3 overrides" 2018-07-04 14:09:51 +00:00
Zane Bitter
76ec5af884 Docs: Eliminate warnings in docs generation
Fix all of the existing sphinx warnings, and treat warnings as errors in
future.

Change-Id: I084ef65da1002c47c7d05a68d6f0268b89a36a7a
Depends-On: https://review.openstack.org/553639
Depends-On: https://review.openstack.org/559348
2018-06-21 16:38:47 -04:00
Doug Hellmann
55d1f4006c 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: I6dde50de599eb3b6b001cbc044929c64df044575
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-06-13 15:00:48 -04:00
Zane Bitter
8f76a10cae tox: Don't delete Python3 .pyc files
Python3 is smarter than Python2 about when to make use of .pyc files, so
there's no need to remove them before running unit tests just in case the
developer has switched branches.[1] To save recompiling before every test
run, disable this behaviour for Python3.

Also, use a consistent find command in all of the environments where we do
this.

[1] https://www.python.org/dev/peps/pep-3147/#case-3-pycache-foo-magic-pyc-with-no-source

Change-Id: Iabaa4a697329e7538fab93541f41fc208e591382
2018-03-28 21:36:37 -04:00
Doug Hellmann
337d83ccde 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: I72fd5f8c87133713cd272de210b7e957880f48f9
Depends-On: https://review.openstack.org/555034
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-03-22 12:40:31 -04:00
ricolin
e82bb7f330 Create doc/requirements.txt
For compliance with the Project Testing Interface as described in:
https://governance.openstack.org/tc/reference/project-testing-interface.html

Refer to:
http://lists.openstack.org/pipermail/openstack-dev/2017-November/124815.html

Change-Id: Ifdfdaacad8574fcfcac9c1b52b0bed6fed4f8411
2018-03-16 00:38:09 +08:00
rabi
f91686c3a7 Fix coverage run with tox -ecover
We removed .testr.conf in 93746a9b2895d44fd105ba26ae77ddffbe2db167
and tox -ecover fails with error.

Change-Id: I31b00afffe38ab5c7591ba54c959349716df7c48
2018-02-07 12:50:07 +05:30
Zuul
04be5a736e Merge "Remove CloudWatch API" 2018-01-31 19:29:03 +00:00
rabi
6d55417f80 Remove CloudWatch API
This patch removes the API, the next set of patches in the
series would remove stack watch service and related
WatchRule implementation.

Change-Id: I8b0472be862907298c8da51f435b5d8b19610ec3
Partial-Bug: #1743707
2018-01-28 09:11:17 +05:30