[issue47093] Documentation Fix: Remove .bat when activating venv on windows

Eryk Sun report at bugs.python.org
Tue Mar 22 11:44:47 EDT 2022


Eryk Sun <eryksun at gmail.com> added the comment:

Running `tutorial-env\Scripts\activate` should suffice. The .bat script is for CMD, and the .ps1 script is for PowerShell. The shell should run the right script without having to include the extension. 

In Windows 10+, if you use a case-sensitive directory for the virtual environment, note that the script name for PowerShell is "Activate.ps1". PowerShell 7+ checks the directory for any name that case-insensitively matches "activate", but you'll have to run `tutorial-env\Scripts\Activate` in PowerShell 5.1.

----------
components: +Windows
keywords: +easy
nosy: +eryksun, paul.moore, steve.dower, tim.golden, zach.ware
stage:  -> needs patch
versions: +Python 3.10, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue47093>
_______________________________________


More information about the Python-bugs-list mailing list