venv/scripts/common/activate should use uname
instead of $OSTYPE
to detect Cygwin and MSYS
#112507
Labels
stdlib
Python modules in the Lib dir
topic-venv
Related to the venv module
type-bug
An unexpected behavior, bug, or error
Bug report
Bug description:
The venv activate script uses the
$OSTYPE
variable to determine if it's running on Cygwin or MSYS.cpython/Lib/venv/scripts/common/activate
Lines 41 to 49 in fb202af
$OSTYPE
is not defined by POSIX. It's provided by bash and zsh, but may not be present in other shells like dash. Theuname
command is always available in any shell and should be used instead.CPython versions tested on:
3.12
Operating systems tested on:
Windows
Linked PRs
uname
instead of$OSTYPE
#112508The text was updated successfully, but these errors were encountered: