Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tox -l fails to output environments when using env_list(instead of envlist) in tox configuration #3178

Open
aht007 opened this issue Dec 26, 2023 · 0 comments
Labels
help:wanted Issues that have been acknowledged, a solution determined and a PR might likely be accepted.

Comments

@aht007
Copy link

aht007 commented Dec 26, 2023

Issue

tox -l should output all the generated environments list but when using env_list in the configuration file we get empty output from the command.

Environment

Provide at least:

  • OS: MacOS 13.5.2 (22G91)
Output of pip list of the host Python, where tox is installed
aiohttp                           3.8.3
aiosignal                         1.3.1
amqp                              5.0.9
aniso8601                         9.0.1
appdirs                           1.4.4
appnope                           0.1.2
argon2-cffi                       21.3.0
argon2-cffi-bindings              21.2.0
asgiref                           3.6.0
astroid                           2.9.0
asttokens                         2.0.5
async-generator                   1.10
async-timeout                     4.0.2
atlassian-python-api              3.32.2
attrs                             22.2.0
Authlib                           1.2.0
autopep8                          1.6.0
backcall                          0.2.0
backoff                           1.5.0
backports.entry-points-selectable 1.1.1
billiard                          3.6.4.0
black                             21.12b0
bleach                            4.1.0
boto                              2.43.0
boto3                             1.20.22
botocore                          1.23.22
build                             1.0.3
cachetools                        5.3.2
celery                            5.2.1
certifi                           2022.12.7
cffi                              1.15.1
chardet                           5.2.0
charset-normalizer                2.1.1
click                             8.1.7
click-didyoumean                  0.3.0
click-log                         0.4.0
click-plugins                     1.1.1
click-repl                        0.2.0
cloudflare                        2.1.0
code-annotations                  1.2.0
codecov                           2.1.12
colorama                          0.4.6
commonmark                        0.9.1
confuse                           1.7.0
contourpy                         1.0.7
coverage                          6.2
cryptography                      39.0.0
cycler                            0.11.0
ddt                               1.4.4
debugpy                           1.5.1
decorator                         5.1.1
defusedxml                        0.7.1
Deprecated                        1.2.13
diff-cover                        4.0.0
distlib                           0.3.8
Django                            3.2.16
django-codemod                    1.8.2
django-config-models              2.2.2
django-crum                       0.7.9
django-fernet-fields              0.6
django-model-utils                4.2.0
django-oauth-toolkit              1.3.2
django-upgrade                    1.4.0
django-waffle                     3.0.0
djangorestframework               3.13.1
dockerfile                        3.2.0
docutils                          0.18.1
easydict                          1.10
edx-celeryutils                   1.1.1
edx-codejail                      3.3.1
edx-django-utils                  5.2.0
edx-i18n-tools                    0.8.1
edx-lint                          5.2.1
edx-opaque-keys                   0.4
edx-repo-health                   1.0.0         /Users/ahtashamulhasaan/Desktop/edx/edx-repo-health
edx-rest-api-client               5.5.0
edx-toggles                       4.2.0
entrypoints                       0.3
et-xmlfile                        1.1.0
event-tracking                    1.1.4
exceptiongroup                    1.2.0
execnet                           1.9.0
executing                         0.8.2
factory-boy                       3.2.1
Faker                             10.0.0
filelock                          3.13.1
fonttools                         4.39.4
freezegun                         0.3.8
frozenlist                        1.3.3
future                            0.16.0
gitdb                             4.0.10
github3.py                        3.0.0
GitPython                         3.1.18
google-api-python-client          1.7.3
google-auth                       2.15.0
google-auth-httplib2              0.1.0
google-auth-oauthlib              0.8.0
gspread                           5.7.2
h11                               0.12.0
httplib2                          0.21.0
idna                              3.4
imageio                           2.28.1
importlib-metadata                7.0.0
importlib-resources               5.4.0
inflect                           5.3.0
iniconfig                         1.1.1
ipykernel                         6.7.0
ipython                           8.0.1
ipython-genutils                  0.2.0
isodate                           0.6.1
isort                             5.10.1
jedi                              0.18.1
jenkinsapi                        0.3.3
Jinja2                            3.0.3
jinja2-pluralize                  0.3.0
jmespath                          0.10.0
joblib                            1.2.0
jsonfield                         3.1.0
jsonlines                         3.1.0
jsonschema                        4.4.0
jupyter-client                    7.1.2
jupyter-core                      4.9.1
jupyterlab-pygments               0.1.2
jwcrypto                          1.0
keyring                           23.5.0
kiwisolver                        1.4.4
kombu                             5.2.2
kubernetes                        12.0.1
lazy                              1.4
lazy_loader                       0.2
lazy-object-proxy                 1.7.1
libcst                            0.4.1
lxml                              4.9.2
MarkupSafe                        2.0.1
matplotlib                        3.7.1
matplotlib-inline                 0.1.3
mccabe                            0.6.1
mistune                           0.8.4
mock                              4.0.3
multidict                         6.0.4
mypy-extensions                   0.4.3
nbclient                          0.5.10
nbconvert                         6.4.1
nbformat                          5.1.3
nest-asyncio                      1.5.4
networkx                          3.1
newrelic                          8.5.0
notebook                          6.4.8
numpy                             1.24.3
oauthlib                          3.2.2
opencv-contrib-python             4.7.0.72
opencv-python                     4.7.0.72
openedx-django-require            2.0.0
openpyxl                          3.1.2
outcome                           1.1.0
packaging                         23.2
pandas                            2.0.1
pandocfilters                     1.5.0
parso                             0.8.3
path                              16.2.0
pathspec                          0.9.0
pbr                               5.11.0
pep517                            0.13.0
pexpect                           4.8.0
pickleshare                       0.7.5
Pillow                            9.5.0
pip                               23.3.1
pip-tools                         7.3.0
pkginfo                           1.8.2
platformdirs                      4.1.0
pluggy                            1.3.0
polib                             1.1.1
prometheus-client                 0.13.1
prompt-toolkit                    3.0.24
psutil                            5.9.4
ptyprocess                        0.7.0
pure-eval                         0.2.2
py                                1.11.0
pyasn1                            0.4.8
pyasn1-modules                    0.2.8
pycodestyle                       2.8.0
pycparser                         2.21
pydocstyle                        6.1.1
PyGithub                          1.57
Pygments                          2.10.0
PyJWT                             2.6.0
pylint                            2.12.2
pylint-celery                     0.3
pylint-django                     2.4.4
pylint-plugin-utils               0.6
pymongo                           3.5.1
PyNaCl                            1.5.0
pyOpenSSL                         21.0.0
pyparsing                         3.0.9
pyproject-api                     1.6.1
pyproject_hooks                   1.0.0
pyrsistent                        0.18.1
pytest                            7.4.3
pytest-aiohttp                    1.0.4
pytest-asyncio                    0.20.3
pytest-cov                        3.0.0
pytest-django                     4.5.2
pytest-forked                     1.4.0
pytest-repo-health                2.2.4
pytest-xdist                      2.5.0
python-dateutil                   2.8.2
python-slugify                    5.0.2
pytz                              2023.3
pyupgrade                         2.10.1
pyupgrade-directories             0.2.0
PyWavelets                        1.4.1
PyYAML                            5.4
pyzmq                             22.3.0
readme-renderer                   32.0
requests                          2.28.1
requests-file                     1.5.1
requests-oauthlib                 1.3.1
requests-toolbelt                 0.10.1
rfc3986                           2.0.0
rich                              11.2.0
rsa                               4.9
ruamel.yaml                       0.16.13
ruamel.yaml.clib                  0.2.6
s3transfer                        0.5.2
sailthru-client                   2.3.5
scikit-image                      0.20.0
scikit-learn                      1.2.2
scipy                             1.9.1
selenium                          4.1.0
Send2Trash                        1.8.0
setuptools                        69.0.2
shellingham                       1.4.0
simple-salesforce                 1.12.2
simplejson                        3.18.1
six                               1.16.0
slumber                           0.7.1
smmap                             5.0.0
sniffio                           1.2.0
snowballstemmer                   2.2.0
sortedcontainers                  2.4.0
sqlparse                          0.4.3
stack-data                        0.1.4
stevedore                         1.32.0
tabulate                          0.8.9
terminado                         0.13.1
testpath                          0.5.0
text-unidecode                    1.3
threadpoolctl                     3.1.0
tifffile                          2023.4.12
tincan                            1.0.0
tokenize-rt                       4.2.1
toml                              0.10.2
tomli                             2.0.1
tornado                           6.1
tox                               3.28.0
tox-battery                       0.6.1
tqdm                              4.62.3
traitlets                         5.1.1
trio                              0.19.0
trio-websocket                    0.9.2
tubular                           0.0.1.dev1201 /Users/ahtashamulhasaan/Desktop/edx/tubular
twine                             3.7.1
typer                             0.3.2
typing_extensions                 4.0.1
typing-inspect                    0.7.1
tzdata                            2023.3
unicodecsv                        0.14.1
uritemplate                       3.0.1
urllib3                           1.26.13
validators                        0.20.0
vine                              5.0.0
virtualenv                        20.25.0
wcwidth                           0.2.5
webencodings                      0.5.1
websocket-client                  1.4.2
wheel                             0.42.0
wrapt                             1.11.2
wsproto                           1.0.0
yagocd                            0.4.4
yarl                              1.8.2
zeep                              4.2.1
zipp                              3.17.0

Output of running tox

Output of tox -rvv
 ~/Desktop/tox-test/ tox -rvv
using tox.ini: /Users/ahtashamulhasaan/Desktop/tox-test/tox.ini (pid 74965)
  removing /Users/ahtashamulhasaan/Desktop/tox-test/.tox/log
using tox-3.28.0 from /Users/ahtashamulhasaan/.pyenv/versions/3.8.10/lib/python3.8/site-packages/tox/__init__.py (pid 74965)
skipping sdist step
/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8 (/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8) is {'executable': '/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8', 'implementation': 'CPython', 'version_info': [3, 8, 10, 'final', 0], 'version': '3.8.10 (default, Jul 13 2021, 16:30:00) \n[Clang 12.0.5 (clang-1205.0.22.11)]', 'is_64': True, 'sysplatform': 'darwin', 'os_sep': '/', 'extra_version_info': None}
python uses /Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8
python start: getenv /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python
python cannot reuse: -r flag
python recreate: /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python
  removing /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python
setting PATH=/Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin:/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin:/usr/local/Cellar/pyenv/2.3.9/libexec:/usr/local/Cellar/pyenv/2.3.9/plugins/python-build/bin:/usr/local/sbin:/Users/ahtashamulhasaan/.nvm/versions/node/v18.13.0/bin:/Users/ahtashamulhasaan/.pyenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Visual\ Studio\ Code.app/Contents/Resources/app/bin/:/usr/local/bin/code:/Users/ahtashamulhasaan/Downloads/geckodriver:/opt/X11/bin:/Library/Apple/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/sbin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin
[74981] /Users/ahtashamulhasaan/Desktop/tox-test/.tox$ /Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8 -m virtualenv --no-download --python /Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8 python
created virtual environment CPython3.8.10.final.0-64 in 399ms
  creator CPython3Posix(dest=/Users/ahtashamulhasaan/Desktop/tox-test/.tox/python, clear=False, no_vcs_ignore=False, global=False)
  seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/Users/ahtashamulhasaan/Library/Application Support/virtualenv)
    added seed packages: pip==23.3.2, setuptools==69.0.3, wheel==0.42.0
  activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
python installdeps: pytest
setting PATH=/Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin:/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin:/usr/local/Cellar/pyenv/2.3.9/libexec:/usr/local/Cellar/pyenv/2.3.9/plugins/python-build/bin:/usr/local/sbin:/Users/ahtashamulhasaan/.nvm/versions/node/v18.13.0/bin:/Users/ahtashamulhasaan/.pyenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Visual\ Studio\ Code.app/Contents/Resources/app/bin/:/usr/local/bin/code:/Users/ahtashamulhasaan/Downloads/geckodriver:/opt/X11/bin:/Library/Apple/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/sbin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin
[74988] /Users/ahtashamulhasaan/Desktop/tox-test$ /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin/python -m pip install pytest
Collecting pytest
  Using cached pytest-7.4.3-py3-none-any.whl.metadata (7.9 kB)
Collecting iniconfig (from pytest)
  Using cached iniconfig-2.0.0-py3-none-any.whl (5.9 kB)
Collecting packaging (from pytest)
  Using cached packaging-23.2-py3-none-any.whl.metadata (3.2 kB)
Collecting pluggy<2.0,>=0.12 (from pytest)
  Using cached pluggy-1.3.0-py3-none-any.whl.metadata (4.3 kB)
Collecting exceptiongroup>=1.0.0rc8 (from pytest)
  Using cached exceptiongroup-1.2.0-py3-none-any.whl.metadata (6.6 kB)
Collecting tomli>=1.0.0 (from pytest)
  Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Using cached pytest-7.4.3-py3-none-any.whl (325 kB)
Using cached exceptiongroup-1.2.0-py3-none-any.whl (16 kB)
Using cached pluggy-1.3.0-py3-none-any.whl (18 kB)
Using cached packaging-23.2-py3-none-any.whl (53 kB)
Installing collected packages: tomli, pluggy, packaging, iniconfig, exceptiongroup, pytest
Successfully installed exceptiongroup-1.2.0 iniconfig-2.0.0 packaging-23.2 pluggy-1.3.0 pytest-7.4.3 tomli-2.0.1
python finish: getenv /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python after 4.04 seconds
python start: finishvenv 
write config to /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/.tox-config1 as '37f2e23237e81db644c692178c154d4dacc9d4b16bd56f963d57533746544e3b /Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin/python3.8\n3.28.0 0 0 0\n00000000000000000000000000000000 pytest'
python finish: finishvenv  after 0.01 seconds
python start: envreport 
setting PATH=/Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin:/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin:/usr/local/Cellar/pyenv/2.3.9/libexec:/usr/local/Cellar/pyenv/2.3.9/plugins/python-build/bin:/usr/local/sbin:/Users/ahtashamulhasaan/.nvm/versions/node/v18.13.0/bin:/Users/ahtashamulhasaan/.pyenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Visual\ Studio\ Code.app/Contents/Resources/app/bin/:/usr/local/bin/code:/Users/ahtashamulhasaan/Downloads/geckodriver:/opt/X11/bin:/Library/Apple/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/sbin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin
[74998] /Users/ahtashamulhasaan/Desktop/tox-test$ /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin/python -m pip freeze >.tox/python/log/python-0.log
python finish: envreport  after 0.45 seconds
python installed: exceptiongroup==1.2.0,iniconfig==2.0.0,packaging==23.2,pluggy==1.3.0,pytest==7.4.3,tomli==2.0.1
python start: run-test-pre 
python run-test-pre: PYTHONHASHSEED='2191107923'
python finish: run-test-pre  after 0.00 seconds
python start: run-test 
python run-test: commands[0] | pytest .
setting PATH=/Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin:/Users/ahtashamulhasaan/.pyenv/versions/3.8.10/bin:/usr/local/Cellar/pyenv/2.3.9/libexec:/usr/local/Cellar/pyenv/2.3.9/plugins/python-build/bin:/usr/local/sbin:/Users/ahtashamulhasaan/.nvm/versions/node/v18.13.0/bin:/Users/ahtashamulhasaan/.pyenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Visual\ Studio\ Code.app/Contents/Resources/app/bin/:/usr/local/bin/code:/Users/ahtashamulhasaan/Downloads/geckodriver:/opt/X11/bin:/Library/Apple/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/usr/local/sbin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:/Users/ahtashamulhasaan/development/flutter/bin
[75006] /Users/ahtashamulhasaan/Desktop/tox-test$ /Users/ahtashamulhasaan/Desktop/tox-test/.tox/python/bin/pytest .
============================================================================ test session starts =============================================================================
platform darwin -- Python 3.8.10, pytest-7.4.3, pluggy-1.3.0
cachedir: .tox/python/.pytest_cache
rootdir: /Users/ahtashamulhasaan/Desktop/tox-test
collected 2 items                                                                                                                                                            

test_base.py ..                                                                                                                                                        [100%]

============================================================================= 2 passed in 0.01s ==============================================================================
python finish: run-test  after 0.29 seconds
python start: run-test-post 
python finish: run-test-post  after 0.00 seconds
__________________________________________________________________________________ summary ___________________________________________________________________________________
  python: commands succeeded
  congratulations :)

Minimal example

[tox]
requires =
    tox<4
env_list = py38-django{32,42}-celery{44,50}-drf{latest}
skipsdist = True
[testenv]
deps =
  django32: Django>=3.2,<4.0
  django42: Django>=4.2,<4.3
  drflatest: djangorestframework
  celery53: -r{toxinidir}/requirements/celery53.txt
  pytest
commands =
  pytest {posargs: .}
@gaborbernat gaborbernat added the help:wanted Issues that have been acknowledged, a solution determined and a PR might likely be accepted. label Mar 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help:wanted Issues that have been acknowledged, a solution determined and a PR might likely be accepted.
Projects
None yet
Development

No branches or pull requests

2 participants