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

Respect virtualenvs.in-project setting, if .venv is found in project folder #2771

Merged
merged 7 commits into from
Sep 23, 2020

Conversation

finswimmer
Copy link
Member

At the moment, when there is a folder called .venv within the project folder, poetry will use it as the path to the venv regardless whether virtualenvs.in-project is set to true or not. This leads to confusions as described in #1770 and #2756.

With this PR poetry will check if virtualenvs.in-project is set to true if it finds a .venv folder.

Closes: #1770
Closes: #2756

Copy link
Member

@abn abn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple of comments. Also, would be good to cover these cases in test cases to avoid any regression.

poetry/utils/env.py Outdated Show resolved Hide resolved
tests/installation/test_chef.py Outdated Show resolved Hide resolved
@finswimmer finswimmer requested a review from abn August 5, 2020 18:23
tests/utils/test_env.py Outdated Show resolved Hide resolved
tests/utils/test_env.py Outdated Show resolved Hide resolved
docs/docs/configuration.md Outdated Show resolved Hide resolved
finswimmer and others added 2 commits September 21, 2020 20:46
Co-authored-by: Arun Babu Neelicattu <arun.neelicattu@gmail.com>
@finswimmer finswimmer requested a review from abn September 21, 2020 19:25
Copy link
Member

@abn abn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor suggestions. Otherwise looks good.

poetry/utils/env.py Outdated Show resolved Hide resolved
tests/utils/test_env.py Outdated Show resolved Hide resolved
@finswimmer finswimmer requested a review from abn September 22, 2020 17:44
Copy link
Member

@abn abn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missed the documentation in the last pass.

docs/docs/configuration.md Outdated Show resolved Hide resolved
docs/docs/configuration.md Outdated Show resolved Hide resolved
@abn abn merged commit 81b2774 into python-poetry:master Sep 23, 2020
@sdispater sdispater mentioned this pull request Sep 25, 2020
Copy link

github-actions bot commented Mar 1, 2024

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Poetry says that "environment seems to be broken" all the time About environment mangement and .venv folder
2 participants