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

bug: tox should run pip with PIP_USER=0 #838

Closed
2 tasks done
anntzer opened this issue Jun 4, 2018 · 11 comments
Closed
2 tasks done

bug: tox should run pip with PIP_USER=0 #838

anntzer opened this issue Jun 4, 2018 · 11 comments
Assignees
Labels
area:testenv-creation bug:normal affects many people or has quite an impact help:wanted Issues that have been acknowledged, a solution determined and a PR might likely be accepted. level:medium rought estimate that this might be neither easy nor hard to implement pr-merged
Milestone

Comments

@anntzer
Copy link

anntzer commented Jun 4, 2018

  • Minimal reproduceable example or detailed description, assign "bug"
  • OS and pip list output

tox cannot use pip to install in a venv if the user has a config file that defaults to --user installs (e.g. because they (I) intend to use the distro package manager when touching distro packages) -- because pip crashes in such settings. By setting the PIP_USER environment variable to 0, tox could override that setting to force the use of in-venv installs.

Arch Linux Py3.6 (from distro) in a clean venv.
pip list

Package    Version
---------- -------
pip        9.0.3  
pluggy     0.6.0  
py         1.5.3  
setuptools 39.0.1 
six        1.11.0 
tox        3.0.0  
virtualenv 16.0.0

foo/setup.py

from setuptools import setup; setup(name="foo")

foo/tox.ini

[tox]
envlist = py36

~/.config/pip/pip.conf

[install]
user = true

Running tox yields

GLOB sdist-make: /tmp/foo/setup.py
py36 inst-nodeps: /tmp/foo/.tox/dist/foo-0.0.0.zip
ERROR: invocation failed (exit code 1), logfile: /tmp/foo/.tox/py36/log/py36-3.log
ERROR: actionid: py36
msg: installpkg
cmdargs: ['/tmp/foo/.tox/py36/bin/pip', 'install', '-U', '--no-deps', '/tmp/foo/.tox/dist/foo-0.0.0.zip']

Can not perform a '--user' install. User site-packages are not visible in this virtualenv.
Exception information:
Traceback (most recent call last):
  File "/tmp/foo/.tox/py36/lib/python3.6/site-packages/pip/_internal/basecommand.py", line 228, in main
    status = self.run(options, args)
  File "/tmp/foo/.tox/py36/lib/python3.6/site-packages/pip/_internal/commands/install.py", line 218, in run
    "Can not perform a '--user' install. User site-packages "
pip._internal.exceptions.InstallationError: Can not perform a '--user' install. User site-packages are not visible in this virtualenv.

py36 installed: foo==0.0.0
_____________________________________________________________________________________________ summary ______________________________________________________________________________________________
ERROR:   py36: InvocationError for command /tmp/foo/.tox/py36/bin/pip install -U --no-deps /tmp/foo/.tox/dist/foo-0.0.0.zip (see /tmp/foo/.tox/py36/log/py36-3.log) (exited with code 1)
@obestwalter obestwalter added the needs:discussion It's not quite clear if and how this should be done label Jun 4, 2018
@obestwalter
Copy link
Member

HI @anntzer, thanks for the detailed report. I am not sure if this needs or should be added to tox. This does not seem to be a common problem.

For setups that need this, the variable can be set directly in tox.ini like:

...

[testenv]
setenv = PIP_USER=0

...

(docs)

@anntzer
Copy link
Author

anntzer commented Jun 4, 2018

Well, that would mean that literally every project using tox "should" set this variable as they could be cloned by contributors who do have this setting.
While the problem may be uncommon, the possibility of defaulting to --user is a perfectly well documented feature of pip.

@obestwalter
Copy link
Member

obestwalter commented Jun 4, 2018

Which public project are we talking about? I am asking because there are tons of public projects using tox and of all the ones on Github 4 projects have this set:

https://github.com/search?l=INI&q=PIP_USER%3D0&type=Code

So maybe this would be a feasible solution for your project after all, if contributors complain about this problem?

I am not actively against adding this to the default, if it really makes sense, but I don't know enough about this yet and really don't know if it is a sensible default for most users. So I would be interested to hear other opinions about this.

The solution for your problem, might be a new problem for somebody who has been using tox without this default until now, you know? 🤷‍♂️

@anntzer
Copy link
Author

anntzer commented Jun 4, 2018

Your search itself shows that projects using tox had to repeatedly rediscover the need to set PIP_USER to false to get a portable tox.ini (in my specific case, I am a dev for matplotlib).
I have shown you a case where this setting is indeed needed. I cannot show you a case where it would be harmful simply because I truly cannot think of one (except of course if some unrelated program happens to also try to read that same environment variable, but that's not a particularly interesting case).

@gaborbernat
Copy link
Member

gaborbernat commented Jun 5, 2018

I agree we should set to zero by default unless explicitly overridden by the user or specified in passenv. @anntzer want to open a PR for this?

Thank you for reporting the issue!

@obestwalter
Copy link
Member

obestwalter commented Jun 5, 2018

I am still not sure about this and haven't heard anything yet, why hard coding that value as default is the best way to deal with it. It does sound reasonable, if it solves the problems of the folks using this setting in their config and if it doesn't cause problems for the rest of us, but I simply don't know.

This issue is also touching on a larger one, that has to do with the introduction of environment isolation in 2.0. I was not involved in the project when that was introduced, so I am not aware of the reasoning behind this (maybe there is something in the issues about this, but the changelog does not provide any reasoning for the decision to make this the default rather than opt-in). What I noticed though is a constant trickle of issues that had to do with this change and that lead to a growing number of env vars being passed through by default to solve these problems - especially on Windows:

tox/tox/config.py

Lines 593 to 618 in 023eef3

passenv = {"PATH", "PIP_INDEX_URL", "LANG", "LANGUAGE", "LD_LIBRARY_PATH"}
# read in global passenv settings
p = os.environ.get("TOX_TESTENV_PASSENV", None)
if p is not None:
env_values = [x for x in p.split() if x]
value.extend(env_values)
# we ensure that tmp directory settings are passed on
# we could also set it to the per-venv "envtmpdir"
# but this leads to very long paths when run with jenkins
# so we just pass it on by default for now.
if tox.INFO.IS_WIN:
passenv.add("SYSTEMDRIVE") # needed for pip6
passenv.add("SYSTEMROOT") # needed for python's crypto module
passenv.add("PATHEXT") # needed for discovering executables
passenv.add("COMSPEC") # needed for distutils cygwincompiler
passenv.add("TEMP")
passenv.add("TMP")
# for `multiprocessing.cpu_count()` on Windows (prior to Python 3.4).
passenv.add("NUMBER_OF_PROCESSORS")
passenv.add("PROCESSOR_ARCHITECTURE") # platform.machine()
passenv.add("USERPROFILE") # needed for `os.path.expanduser()`
passenv.add("MSYSTEM") # fixes #429
else:
passenv.add("TMPDIR")

This gives me the impression that it might be worth thinking about that decision again and maybe head for switching the default around after a deprecation period rather than adding more and more env var special casing. A tox.ini would have to explicitly opt-in to env var isolation then, instead of silently swallowing all the env vars, especially when many of them are essential.

I know that this is completely beyond the scope of this issue, but I wanted to share my thoughts why I am a bit more sceptic about just adding another env var special casing that solves another specific env var related problem of a specific group of users. Especially because this time it would be an explicitly hard coded override rather than just passing through the wish of the user.

At the moment I would rather lean to to passing PIP_USER through to the underlying environment (and check what else we should pass through from the PIP_* family of env vars, if there are more). Simply because this would be more in line with what we already do with the other env var special casing. It should also be documented then, that if a user forces --user installs globally in their config, they will have to call tox with PIP_USER=False.

@gaborbernat
Copy link
Member

I'm not sure I agree. All those arguments passed have a really good reason to be passed in and has mostly to do with the fact that we use pip (which then uses setuptools) to build/install packages. pip and setuptools do use a few environment variables to control their work logic, and makes sense to pass those along (as we have both pip hardcoded). Note that the list might and is completely different by the underlying build/install tools. E.g. conda uses something different, and that plugin might add just some env vars to ensure the plugin works as expected: isolated and in the virtual environment mode. I think the whole scope of tox is to work out of box in isolated environments, with minimal config. Installing packages in the user site go against tox's policy, and therefore setting that env var by default to false makes sense.

@obestwalter
Copy link
Member

Hey @gaborbernat, I think you misunderstood me. I meant it the other way around. I mean that it might be a better way forward to reverse the default in tox to not isolate environments at all - which means that passenv=* would be the implicit default. I think many users (especially newcomers) are confused about this isolation as default and it has a lot of ripple effects (e.g. codecov/codecov-python#151). I think we should reconsider this, because of this.

I would class environment var isolation as an advanced feature that should be deactivated by default.

Anyway ... sorry for hijacking this issue, I basically just tried to explain why I was not very welcoming in accepting the next env var related special casing, because of these thoughts. Just ignore me here and deal with the problem at hand - if you two know your way around this behaviour and see no problems in adding this, just go ahead. I will open an issue later on about the broader issue. 😄

@gaborbernat
Copy link
Member

gaborbernat commented Jun 5, 2018

I think the isolation offers lots of value for people; and makes reproducible tests so much easier. That codecov example is an application use case, and that documentation should specify it as you marked in in the PR. Most of the env vars we whitelist are whitelisted either because we want to increase isolation, or that we need those because we depend on them (e.g. having path for command discovery).

@asottile
Copy link
Contributor

asottile commented Jun 9, 2018

maybe a better solution would be PIP_CONFIG_FILE={}'.format(os.devnull)? (though I can already think of a situation where that might be undesirable: if an organization wanted to use that to enforce a pypi index they'd suddenly be back to public pypi)

@gaborbernat gaborbernat added level:medium rought estimate that this might be neither easy nor hard to implement and removed needs:discussion It's not quite clear if and how this should be done labels Jun 20, 2018
@gaborbernat gaborbernat added this to the 3.1 milestone Jun 20, 2018
@gaborbernat gaborbernat added help:wanted Issues that have been acknowledged, a solution determined and a PR might likely be accepted. bug:normal affects many people or has quite an impact area:testenv-creation labels Jun 20, 2018
@gaborbernat gaborbernat self-assigned this Jul 2, 2018
@gaborbernat gaborbernat modified the milestones: 3.1, 3.2 Jul 8, 2018
@anntzer
Copy link
Author

anntzer commented Jul 18, 2018

If we're trying to keep a minimal list of environment variables that do need to be set:

  • there's PIP_USER=0 (because --user makes testenv creation impossible, as mentioned above)
  • there's also PIP_NO_DEPS=0 (because --no-deps likely makes testenv creation incorrect, e.g. it leads to pytest being installed without its dependencies).

(Why do I have PIP_NO_DEPS set to 1 by default? Because I don't particularly like pip's dependency resolver (or lack thereof), and would rather rely (in normal cases) on my distro package manager's, which is much superior. Not that this is particularly relevant.)

@gaborbernat gaborbernat modified the milestones: 3.2, 3.4 Sep 14, 2018
@helpr helpr bot added the pr-available label Sep 16, 2018
@helpr helpr bot added pr-merged and removed pr-available labels Sep 16, 2018
DmytroLitvinov referenced this issue in DmytroLitvinov/kuna Sep 24, 2018



### Update [tox](https://pypi.org/project/tox) from **3.2.1** to **3.4.0**.


<details>
  <summary>Changelog</summary>
  
  
   ### 3.4.0
   ```
   ------------------

Bugfixes
^^^^^^^^

- add ``--exists-action w`` to default pip flags to handle better VCS dependencies (`pip documentation on this &lt;https://pip.pypa.io/en/latest/reference/pip/exists-action-option&gt;`_) - by :user:`gaborbernat` (`503 &lt;https://github.com/tox-dev/tox/issues/503&gt;`_)
- instead of assuming the Python version from the base python name ask the interpreter to reveal the version for the ``ignore_basepython_conflict`` flag - by :user:`gaborbernat` (`908 &lt;https://github.com/tox-dev/tox/issues/908&gt;`_)
- PEP-517 packaging fails with sdist already exists, fixed via ensuring the dist folder is empty before invoking the backend and `pypa/setuptools 1481 &lt;https://github.com/pypa/setuptools/pull/1481&gt;`_ - by :user:`gaborbernat` (`1003 &lt;https://github.com/tox-dev/tox/issues/1003&gt;`_)


Features
^^^^^^^^

- add ``commands_pre`` and ``commands_post`` that run before and after running
  the ``commands`` (setup runs always, commands only if setup suceeds, teardown always - all
  run until the first failing command)  - by :user:`gaborbernat` (`167 &lt;https://github.com/tox-dev/tox/issues/167&gt;`_)
- ``pyproject.toml`` config support initially by just inline the tox.ini under ``tool.tox.legacy_tox_ini`` key; config source priority order is ``pyproject.toml``, ``tox.ini`` and then ``setup.cfg`` - by :user:`gaborbernat` (`814 &lt;https://github.com/tox-dev/tox/issues/814&gt;`_)
- use the os environment variable ``TOX_SKIP_ENV`` to filter out tox environment names from the run list (set by ``envlist``)  - by :user:`gaborbernat` (`824 &lt;https://github.com/tox-dev/tox/issues/824&gt;`_)
- always set ``PIP_USER=0`` (do not install into the user site package, but inside the virtual environment created) and ``PIP_NO_DEPS=0`` (installing without dependencies can cause broken package installations) inside tox - by :user:`gaborbernat` (`838 &lt;https://github.com/tox-dev/tox/issues/838&gt;`_)
- tox will inject some environment variables that to indicate a command is running within tox: ``TOX_WORK_DIR`` env var is set to the tox work directory,
  ``TOX_ENV_NAME`` is set to the current running tox environment name, ``TOX_ENV_DIR`` is set to the current tox environments working dir - by :user:`gaborbernat` (`847 &lt;https://github.com/tox-dev/tox/issues/847&gt;`_)
- While running tox invokes various commands (such as building the package, pip installing dependencies and so on), these were printed in case they failed as Python arrays. Changed the representation to a shell command, allowing the users to quickly replicate/debug the failure on their own - by :user:`gaborbernat` (`851 &lt;https://github.com/tox-dev/tox/issues/851&gt;`_)
- skip missing interpreters value from the config file can now be overridden via the ``--skip-missing-interpreters`` cli flag - by :user:`gaborbernat` (`903 &lt;https://github.com/tox-dev/tox/issues/903&gt;`_)
- keep additional environments config order when listing them - by :user:`gaborbernat` (`921 &lt;https://github.com/tox-dev/tox/issues/921&gt;`_)
- allow injecting config value inside the ini file dependent of the fact that we&#39;re connected to an interactive shell or not  - by :user:`gaborbernat` (`947 &lt;https://github.com/tox-dev/tox/issues/947&gt;`_)
- do not build sdist if skip install is specified for the envs to be run - by :user:`gaborbernat` (`974 &lt;https://github.com/tox-dev/tox/issues/974&gt;`_)
- when verbosity level increases above two start passing through verbosity flags to pip - by :user:`gaborbernat` (`982 &lt;https://github.com/tox-dev/tox/issues/982&gt;`_)
- when discovering the interpreter to use check if the tox host Python matches and use that if so - by :user:`gaborbernat` (`994 &lt;https://github.com/tox-dev/tox/issues/994&gt;`_)
- ``-vv`` will print out why a virtual environment is re-created whenever this operation is triggered - by :user:`gaborbernat` (`1004 &lt;https://github.com/tox-dev/tox/issues/1004&gt;`_)


Documentation
^^^^^^^^^^^^^

- clarify that ``python`` and ``pip`` refer to the virtual environments executable - by :user:`gaborbernat` (`305 &lt;https://github.com/tox-dev/tox/issues/305&gt;`_)
- add Sphinx and mkdocs example of generating documentation via tox - by :user:`gaborbernat` (`374 &lt;https://github.com/tox-dev/tox/issues/374&gt;`_)
- specify that ``setup.cfg`` tox configuration needs to be inside the ``tox:tox`` namespace - by :user:`gaborbernat` (`545 &lt;https://github.com/tox-dev/tox/issues/545&gt;`_)
   ```
   
  
  
   ### 3.3.0
   ```
   ------------------

Bugfixes
^^^^^^^^

- fix ``TOX_LIMITED_SHEBANG`` when running under python3 - by :user:`asottile` (`931 &lt;https://github.com/tox-dev/tox/issues/931&gt;`_)


Features
^^^^^^^^

- `PEP-517 &lt;https://www.python.org/dev/peps/pep-0517/&gt;`_ source distribution support (create a
  ``.package`` virtual environment to perform build operations inside) by :user:`gaborbernat` (`573 &lt;https://github.com/tox-dev/tox/issues/573&gt;`_)
- `flit &lt;https://flit.readthedocs.io&gt;`_ support via implementing ``PEP-517`` by :user:`gaborbernat` (`820 &lt;https://github.com/tox-dev/tox/issues/820&gt;`_)
- packaging now is exposed as a hook via ``tox_package(session, venv)`` - by :user:`gaborbernat` (`951 &lt;https://github.com/tox-dev/tox/issues/951&gt;`_)


Miscellaneous
^^^^^^^^^^^^^

- Updated the VSTS build YAML to use the latest jobs and pools syntax - by :user:`davidstaheli` (`955 &lt;https://github.com/tox-dev/tox/issues/955&gt;`_)
   ```
   
  
</details>


 

<details>
  <summary>Links</summary>
  
  - PyPI: https://pypi.org/project/tox
  - Changelog: https://pyup.io/changelogs/tox/
  - Docs: https://tox.readthedocs.org/
</details>





### Update [Sphinx](https://pypi.org/project/Sphinx) from **1.8.0** to **1.8.1**.


<details>
  <summary>Changelog</summary>
  
  
   ### 1.8.1
   ```
   =====================================

Incompatible changes
--------------------

* LaTeX ``\pagestyle`` commands have been moved to the LaTeX template. No
  changes in PDF, except possibly if ``\sphinxtableofcontents``, which
  contained them, had been customized in :file:`conf.py`. (refs: 5455)

Bugs fixed
----------

* 5418: Incorrect default path for sphinx-build -d/doctrees files
* 5421: autodoc emits deprecation warning for :confval:`autodoc_default_flags`
* 5422: lambda object causes PicklingError on storing environment
* 5417: Sphinx fails to build with syntax error in Python 2.7.5
* 4911: add latexpdf to make.bat for non make-mode
* 5436: Autodoc does not work with enum subclasses with properties/methods
* 5437: autodoc: crashed on modules importing eggs
* 5433: latex: ImportError: cannot import name &#39;DEFAULT_SETTINGS&#39;
* 5431: autodoc: ``autofunction`` emits a warning for callable objects
* 5457: Fix TypeError in error message when override is prohibited
* 5453: PDF builds of &#39;howto&#39; documents have no page numbers
* 5463: mathbase: math_role and MathDirective was disappeared in 1.8.0
* 5454: latex: Index has disappeared from PDF for Japanese documents
* 5432: py domain: ``:type:`` field can&#39;t process ``:term:`` references
* 5426: py domain: TypeError has been raised for class attribute
   ```
   
  
</details>


 

<details>
  <summary>Links</summary>
  
  - PyPI: https://pypi.org/project/sphinx
  - Changelog: https://pyup.io/changelogs/sphinx/
  - Homepage: http://sphinx-doc.org/
</details>





### Update [twine](https://pypi.org/project/twine) from **1.11.0** to **1.12.0**.


<details>
  <summary>Changelog</summary>
  
  
   ### 1.12.0
   ```
   * :feature:`395 major` Add ``twine check`` command to check long description
* :feature:`392 major` Drop support for Python 3.3
* :feature:`363` Empower ``--skip-existing`` for Artifactory repositories
* 🐛`367` Avoid MD5 when Python is compiled in FIPS mode
   ```
   
  
</details>


 

<details>
  <summary>Links</summary>
  
  - PyPI: https://pypi.org/project/twine
  - Changelog: https://pyup.io/changelogs/twine/
  - Docs: https://twine.readthedocs.io/
</details>
guykisel referenced this issue in guykisel/inline-plz Sep 24, 2018
This PR updates [tox](https://pypi.org/project/tox) from **3.1.2** to **3.4.0**.



<details>
  <summary>Changelog</summary>
  
  
   ### 3.4.0
   ```
   ------------------

Bugfixes
^^^^^^^^

- add ``--exists-action w`` to default pip flags to handle better VCS dependencies (`pip documentation on this &lt;https://pip.pypa.io/en/latest/reference/pip/exists-action-option&gt;`_) - by :user:`gaborbernat` (`503 &lt;https://github.com/tox-dev/tox/issues/503&gt;`_)
- instead of assuming the Python version from the base python name ask the interpreter to reveal the version for the ``ignore_basepython_conflict`` flag - by :user:`gaborbernat` (`908 &lt;https://github.com/tox-dev/tox/issues/908&gt;`_)
- PEP-517 packaging fails with sdist already exists, fixed via ensuring the dist folder is empty before invoking the backend and `pypa/setuptools 1481 &lt;https://github.com/pypa/setuptools/pull/1481&gt;`_ - by :user:`gaborbernat` (`1003 &lt;https://github.com/tox-dev/tox/issues/1003&gt;`_)


Features
^^^^^^^^

- add ``commands_pre`` and ``commands_post`` that run before and after running
  the ``commands`` (setup runs always, commands only if setup suceeds, teardown always - all
  run until the first failing command)  - by :user:`gaborbernat` (`167 &lt;https://github.com/tox-dev/tox/issues/167&gt;`_)
- ``pyproject.toml`` config support initially by just inline the tox.ini under ``tool.tox.legacy_tox_ini`` key; config source priority order is ``pyproject.toml``, ``tox.ini`` and then ``setup.cfg`` - by :user:`gaborbernat` (`814 &lt;https://github.com/tox-dev/tox/issues/814&gt;`_)
- use the os environment variable ``TOX_SKIP_ENV`` to filter out tox environment names from the run list (set by ``envlist``)  - by :user:`gaborbernat` (`824 &lt;https://github.com/tox-dev/tox/issues/824&gt;`_)
- always set ``PIP_USER=0`` (do not install into the user site package, but inside the virtual environment created) and ``PIP_NO_DEPS=0`` (installing without dependencies can cause broken package installations) inside tox - by :user:`gaborbernat` (`838 &lt;https://github.com/tox-dev/tox/issues/838&gt;`_)
- tox will inject some environment variables that to indicate a command is running within tox: ``TOX_WORK_DIR`` env var is set to the tox work directory,
  ``TOX_ENV_NAME`` is set to the current running tox environment name, ``TOX_ENV_DIR`` is set to the current tox environments working dir - by :user:`gaborbernat` (`847 &lt;https://github.com/tox-dev/tox/issues/847&gt;`_)
- While running tox invokes various commands (such as building the package, pip installing dependencies and so on), these were printed in case they failed as Python arrays. Changed the representation to a shell command, allowing the users to quickly replicate/debug the failure on their own - by :user:`gaborbernat` (`851 &lt;https://github.com/tox-dev/tox/issues/851&gt;`_)
- skip missing interpreters value from the config file can now be overridden via the ``--skip-missing-interpreters`` cli flag - by :user:`gaborbernat` (`903 &lt;https://github.com/tox-dev/tox/issues/903&gt;`_)
- keep additional environments config order when listing them - by :user:`gaborbernat` (`921 &lt;https://github.com/tox-dev/tox/issues/921&gt;`_)
- allow injecting config value inside the ini file dependent of the fact that we&#39;re connected to an interactive shell or not  - by :user:`gaborbernat` (`947 &lt;https://github.com/tox-dev/tox/issues/947&gt;`_)
- do not build sdist if skip install is specified for the envs to be run - by :user:`gaborbernat` (`974 &lt;https://github.com/tox-dev/tox/issues/974&gt;`_)
- when verbosity level increases above two start passing through verbosity flags to pip - by :user:`gaborbernat` (`982 &lt;https://github.com/tox-dev/tox/issues/982&gt;`_)
- when discovering the interpreter to use check if the tox host Python matches and use that if so - by :user:`gaborbernat` (`994 &lt;https://github.com/tox-dev/tox/issues/994&gt;`_)
- ``-vv`` will print out why a virtual environment is re-created whenever this operation is triggered - by :user:`gaborbernat` (`1004 &lt;https://github.com/tox-dev/tox/issues/1004&gt;`_)


Documentation
^^^^^^^^^^^^^

- clarify that ``python`` and ``pip`` refer to the virtual environments executable - by :user:`gaborbernat` (`305 &lt;https://github.com/tox-dev/tox/issues/305&gt;`_)
- add Sphinx and mkdocs example of generating documentation via tox - by :user:`gaborbernat` (`374 &lt;https://github.com/tox-dev/tox/issues/374&gt;`_)
- specify that ``setup.cfg`` tox configuration needs to be inside the ``tox:tox`` namespace - by :user:`gaborbernat` (`545 &lt;https://github.com/tox-dev/tox/issues/545&gt;`_)
   ```
   
  
  
   ### 3.3.0
   ```
   ------------------

Bugfixes
^^^^^^^^

- fix ``TOX_LIMITED_SHEBANG`` when running under python3 - by :user:`asottile` (`931 &lt;https://github.com/tox-dev/tox/issues/931&gt;`_)


Features
^^^^^^^^

- `PEP-517 &lt;https://www.python.org/dev/peps/pep-0517/&gt;`_ source distribution support (create a
  ``.package`` virtual environment to perform build operations inside) by :user:`gaborbernat` (`573 &lt;https://github.com/tox-dev/tox/issues/573&gt;`_)
- `flit &lt;https://flit.readthedocs.io&gt;`_ support via implementing ``PEP-517`` by :user:`gaborbernat` (`820 &lt;https://github.com/tox-dev/tox/issues/820&gt;`_)
- packaging now is exposed as a hook via ``tox_package(session, venv)`` - by :user:`gaborbernat` (`951 &lt;https://github.com/tox-dev/tox/issues/951&gt;`_)


Miscellaneous
^^^^^^^^^^^^^

- Updated the VSTS build YAML to use the latest jobs and pools syntax - by :user:`davidstaheli` (`955 &lt;https://github.com/tox-dev/tox/issues/955&gt;`_)
   ```
   
  
  
   ### 3.2.1
   ```
   ------------------

Bugfixes
^^^^^^^^

- ``--parallel--safe-build`` no longer cleans up its folders (``distdir``, ``distshare``, ``log``). - by :user:`gaborbernat` (`849 &lt;https://github.com/tox-dev/tox/issues/849&gt;`_)
   ```
   
  
  
   ### 3.2.0
   ```
   ------------------

Features
^^^^^^^^

- Switch pip invocations to use the module ``-m pip`` instead of direct invocation. This could help
  avoid some of the shebang limitations.  - by :user:`gaborbernat` (`935 &lt;https://github.com/tox-dev/tox/issues/935&gt;`_)
- Ability to specify package requirements for the tox run via the ``tox.ini`` (``tox`` section under key ``requires`` - PEP-508 style): can be used to specify both plugin requirements or build dependencies. - by :user:`gaborbernat` (`783 &lt;https://github.com/tox-dev/tox/issues/783&gt;`_)
- Allow to run multiple tox instances in parallel by providing the
  ``--parallel--safe-build`` flag. - by :user:`gaborbernat` (`849 &lt;https://github.com/tox-dev/tox/issues/849&gt;`_)
   ```
   
  
  
   ### 3.1.3
   ```
   ------------------

Bugfixes
^^^^^^^^

- A caching issue that caused the ``develop-inst-nodeps`` action, which
  reinstalls the package under test, to always run has been resolved. The
  ``develop-inst-noop`` action, which, as the name suggests, is a no-op, will now
  run unless there are changes to ``setup.py`` or ``setup.cfg`` files that have
  not been reflected - by stephenfin (`909 &lt;https://github.com/tox-dev/tox/issues/909&gt;`_)


Features
^^^^^^^^

- Python version testenvs are now automatically detected instead of comparing
  against a hard-coded list of supported versions.  This enables ``py38`` and
  eventually ``py39`` / ``py40`` / etc. to work without requiring an upgrade to
  ``tox``.  As such, the following public constants are now deprecated
  (and scheduled for removal in ``tox`` 4.0: ``CPYTHON_VERSION_TUPLES``,
  ``PYPY_VERSION_TUPLES``, ``OTHER_PYTHON_INTERPRETERS``, and ``DEFAULT_FACTORS`` -
  by :user:`asottile` (`914 &lt;https://github.com/tox-dev/tox/issues/914&gt;`_)


Documentation
^^^^^^^^^^^^^

- Add a system overview section on the index page that explains briefly how tox works -
  by :user:`gaborbernat`. (`867 &lt;https://github.com/tox-dev/tox/issues/867&gt;`_)
   ```
   
  
</details>


 

<details>
  <summary>Links</summary>
  
  - PyPI: https://pypi.org/project/tox
  - Changelog: https://pyup.io/changelogs/tox/
  - Docs: https://tox.readthedocs.org/
</details>
@tox-dev tox-dev locked and limited conversation to collaborators Jan 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area:testenv-creation bug:normal affects many people or has quite an impact help:wanted Issues that have been acknowledged, a solution determined and a PR might likely be accepted. level:medium rought estimate that this might be neither easy nor hard to implement pr-merged
Projects
None yet
Development

No branches or pull requests

4 participants