847f9a40ca
With setuptools release 61.0.0 sahara-image-elements' package build
command (python3 setup.py sdist bdist_wheel) started to fail:
error: Multiple top-level packages discovered in a flat-layout:
['roles', 'elements', 'playbooks'].
This bug is mentioned in setuptools issue 3197 [1], and the suggested
workaround is to disable auto-discovery by adding 'py_modules=[]' in
setup.py.
To unblock the gate the following needed to be updated as well:
- requirements constraints
- fix lower-constraints job constraints (only the 1st constraints is
used by pip, which was upper-constraints.txt from install command)
[1] https://github.com/pypa/setuptools/issues/3197
changes:
tox.ini
NOTE(elod.illes): upper constraints should point to yoga version of the
file in stable/yoga.
Change-Id: Ib2d3e296e6d405671594dfd630e381ae414a2709
(cherry picked from commit 008b0d7e83
)
46 lines
1.1 KiB
INI
46 lines
1.1 KiB
INI
[tox]
|
|
envlist = pep8
|
|
minversion = 2.0
|
|
skipsdist = True
|
|
|
|
[testenv]
|
|
basepython = python3
|
|
usedevelop = True
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
deps =
|
|
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/yoga}
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
passenv = http_proxy HTTP_PROXY https_proxy HTTPS_PROXY no_proxy NO_PROXY
|
|
|
|
[testenv:bashate]
|
|
whitelist_externals = bash
|
|
commands = bash -c "find {toxinidir} -not -wholename \*.tox/\* -and \( -name \*.sh -or -wholename \*.d/\* -and -not -name \*.md -and -not -name \*.rst -and -not -name \*.py \) -print0 | xargs -0 bashate -v"
|
|
|
|
[testenv:pep8]
|
|
setenv =
|
|
ELEMENTS_DIR=elements
|
|
commands =
|
|
flake8 {posargs}
|
|
{toxinidir}/tools/run_bashate.sh
|
|
dib-lint
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
passenv = *
|
|
|
|
[dib-lint]
|
|
ignore=safe_sudo
|
|
|
|
[flake8]
|
|
show-source = true
|
|
builtins = _
|
|
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,tools
|
|
|
|
[testenv:lower-constraints]
|
|
deps =
|
|
-c{toxinidir}/lower-constraints.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
-r{toxinidir}/requirements.txt
|