-
-
Notifications
You must be signed in to change notification settings - Fork 526
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix provisioning from pyvenv interpreter (#1452)
When the original interpreter [0] tox is called with is actually a pyvenv it will set the `__PYVENV_LAUNCHER__` environment variable to the path of pyvenv interpreter. If tox configuration specifies `requires` and the requirements are not satifsfied by [0], tox will create an intermediate virtual environment [1]. After setting up [1] tox will delegate the original call by spawning a new [1] interpreter with the identical identical list of arguments. It will also pass the value of `__PYVENV_LAUNCHER__` if present. This in turn causes `sys.executable` to resolve to [0] instead of [1] therefore ignoring all modifications including installed requirements. The fix is to make sure that when [0] spawns [1], `__PYVENV_LAUNCHER__` is removed from the environment.
- Loading branch information
1 parent
8e6f64a
commit 5582194
Showing
4 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Fix provisioning from a pyvenv interpreter. — by :user:`kentzo` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters