-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
gh-135773: have pyvenv.cfg without home key anchor a venv and deduce home #135831
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
Conversation
…sing.venv.home
Hi all, With ncoghlan's sponsorship, I've written a PEP to formalize relative home path behavior for 3.15 and later. It's been assigned as PEP 796 and is awaiting PEP editor review before being posted for discussion. Is this sufficient progress to make people comfortable approving this PR and applying to 3.14? If not, is there additional work that would? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With PEP 796 being proposed for 3.15, I'm going to go ahead and merge this so we only have one quirky legacy behaviour in older versions rather than 3.14 being a special case.
Thanks @rickeylev for the PR, and @ncoghlan for merging it 🌮🎉.. I'm working now to backport this PR to: 3.14. |
…educe home (pythonGH-135831) This is still formally undefined behaviour, but we may as well keep the *same* undefined behaviour as previous versions. PEP 796 proposes a cleaner and more consistent replacement for 3.15+ (cherry picked from commit 93263d43141a81d369adfcddf325f9a54cb5766d) Co-authored-by: Richard Levasseur <rlevasseur@google.com>
GH-136287 is a backport of this pull request to the 3.14 branch. |
…deduce home (GH-135831) (#136287) gh-135773: have pyvenv.cfg without home key anchor a venv and deduce home (GH-135831) This is still formally undefined behaviour, but we may as well keep the *same* undefined behaviour as previous versions. PEP 796 proposes a cleaner and more consistent replacement for 3.15+ (cherry picked from commit 93263d4) Co-authored-by: Richard Levasseur <rlevasseur@google.com>
This restores the 3.13 behavior where pyvenv.cfg without a home key still activates
a virtual environment. In such cases, home is typically found by reading the symlink
that venv's interpreter executable points to.