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

Name ".tox" should not be allowed in "envlist" #1684

Closed
sinoroc opened this issue Oct 6, 2020 · 3 comments · Fixed by #1800
Closed

Name ".tox" should not be allowed in "envlist" #1684

sinoroc opened this issue Oct 6, 2020 · 3 comments · Fixed by #1800
Labels
bug:normal affects many people or has quite an impact

Comments

@sinoroc
Copy link

sinoroc commented Oct 6, 2020

  • tox 3.20.0

Name .tox should not be allowed in envlist.

Apparently there are safe guards in code, so that when isolated_build is set in tox.ini then adding .package to envlist and/or running tox -e .package throws an exception relatively early on:

tox.exception.ConfigError: ConfigError: isolated_build_env .package cannot be part of envlist

There doesn't seem to be such safe guards for the case where requires is set in tox.ini and .tox is added to envlist.


[tox]
envlist =
    .tox
requires =
    wheel
skipsdist = True

[testenv]
commands =
    python -V
$ rm -rf .tox && tox
.tox create: /home/sinoroc/workspace/dot-tox/.tox/.tox
.tox installdeps: wheel, tox >= 3.20.0
.tox recreate: /home/sinoroc/workspace/dot-tox/.tox/.tox
ERROR: invocation failed (exit code 2), logfile: /home/sinoroc/workspace/dot-tox/.tox/.tox/log/.tox-0.log
=============================================== log start ===============================================

================================================ log end ================================================
ERROR: InvocationError for command /home/sinoroc/workspace/dot-tox/.tox/.tox/bin/python -m virtualenv --no-download --python /home/sinoroc/workspace/dot-tox/.tox/.tox/bin/python .tox (exited with code 2)
________________________________________________ summary ________________________________________________
ERROR:   .tox: InvocationError for command /home/sinoroc/workspace/dot-tox/.tox/.tox/bin/python -m virtualenv --no-download --python /home/sinoroc/workspace/dot-tox/.tox/.tox/bin/python .tox (exited with code 2)

@sinoroc sinoroc added the bug:normal affects many people or has quite an impact label Oct 6, 2020
jayvdb added a commit to jayvdb/tox that referenced this issue Jan 11, 2021
gaborbernat pushed a commit that referenced this issue Jan 12, 2021
@sinoroc
Copy link
Author

sinoroc commented Jan 12, 2021

I have not tested those and they might well be covered already, but since we are here: are other names such as .tmp, dist, log, .package.lock, etc. already safe guarded?

@gaborbernat
Copy link
Member

Those are within the tox environments, so they don't need safeguarding.

@gaborbernat
Copy link
Member

Released now via https://tox.readthedocs.io/en/latest/changelog.html#v3-21-1-2021-01-13

@tox-dev tox-dev locked and limited conversation to collaborators Jan 14, 2021
ssbarnea pushed a commit to ssbarnea/tox that referenced this issue Apr 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug:normal affects many people or has quite an impact
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants