e5e141f134
tox4 even when running specific env with -e option tries to find python version for all envs defined in envlist[1] when running with --skip-missing-interpreters=false and fails if interpreter missing for any of the env. With py38 in envlist it tries to find python3.8 which is not available in ubuntu-jammy by default and fails, hence use generic version instead i.e py3 to handle it. Even though [1] is fixed we are still seeing this failure. [1] https://github.com/tox-dev/tox/issues/2811 Also had to add "ignore_basepython_conflict = True". Change-Id: I351870695b1c6706888d8a51fa33ea0fcbc63cd7
32 lines
881 B
INI
32 lines
881 B
INI
[tox]
|
|
minversion = 3.18.0
|
|
envlist = docs,py3
|
|
ignore_basepython_conflict = True
|
|
|
|
[testenv]
|
|
basepython = {env:TOX_PYTHON:python3}
|
|
usedevelop = True
|
|
setenv =
|
|
VIRTUAL_ENV={envdir}
|
|
OS_LOG_CAPTURE={env:OS_LOG_CAPTURE:true}
|
|
OS_STDOUT_CAPTURE={env:OS_STDOUT_CAPTURE:true}
|
|
OS_STDERR_CAPTURE={env:OS_STDERR_CAPTURE:true}
|
|
# Unit test requires docutils and it is recommended to install docutils via
|
|
# sphinx. We use doc/requirements.txt as well to avoid duplicated entries.
|
|
deps =
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/doc/requirements.txt
|
|
commands = stestr run --slowest {posargs}
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
|
|
[testenv:docs]
|
|
allowlist_externals = rm
|
|
deps =
|
|
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
|
-r{toxinidir}/doc/requirements.txt
|
|
commands =
|
|
rm -fr doc/build/
|
|
sphinx-build -W -b html doc/source doc/build/html
|