Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Python Launcher for Windows (py.exe) seems to ignore virtual environment in recent beta 3.11.0b1 #92817

Closed
Assignees
zooba
Labels
3.11only security fixesOS-windowstype-bugAn unexpected behavior, bug, or error
@Dutcho

Description

@Dutcho

When typingpy, I get thestandard python version as set by%PY_PYTHON%, i.c. 3.10,even when a virtual environment (venv) is active.
When typingpython, I get the python version from thevenv, i.c. 3.11.

Iexpected the Python Launcher for Windows (py.exe) to prefer the CLI command argumentpy -<n.n> (if any) overvenv over%PY_PYTHON%.
That was the way I recallpy worked in 3.10. 3.11.0a7 had anissue in ignoring%PY_PYTHON%, which is now remedied in 3.11.0.b1 (thanks@zooba !). Thevenv part still seems to have an issue in 3.11.0b1.

Environment

(venv) >set pyPY_PYTHON=3.10(venv) >py -0p -V:3.11          C:\Program Files\Python311\python.exe -V:3.10 *        C:\Program Files\Python310\python.exe -V:3.9           C:\Program Files\Python39\python.exe

Issue

(venv) >py -V -VPython 3.10.4 (tags/v3.10.4:9d38120, Mar 23 2022, 23:13:41) [MSC v.1929 64 bit (AMD64)](venv) >python -V -VPython 3.11.0b1 (main, May  7 2022, 22:58:47) [MSC v.1931 64 bit (AMD64)](venv) >where pythonC:\Users\[...]\venv\Scripts\python.exeC:\Program Files\Python311\python.exe(venv) >where pyC:\Windows\py.exe(venv) >py -hPython Launcher for Windows Version 3.11.0b1usage:py [launcher-args] [python-args] [script [script-args]][...]

Metadata

Metadata

Assignees

Labels

3.11only security fixesOS-windowstype-bugAn unexpected behavior, bug, or error

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions


    [8]ページ先頭

    ©2009-2025 Movatter.jp