[issue46950] Windows 11, VENV not working with case sensitive windows paths

Darrel O'Pry report at bugs.python.org
Mon Mar 14 14:01:05 EDT 2022


Darrel O'Pry <darrel.opry at spry-group.com> added the comment:

I've done some additional troubleshooting today. I have case sensitivity enabled in my git checkouts where I am creating the virtual env. I do this for a more consistent cross-platform experience for managing code with team members also using linux and macos. I have had issues in the past with case changes in filenames causing issue on projects and enabling case sensitivity has eliminate these issues when working with my counterparts on other platforms. 


I've tested the following with both powershell and bash. 

```
mkdir test-venv-case-sensitivity
cd test-venv-case-sensitivity
fsutil.exe file setCaseSensitiveInfo . enable
python -m venv ./venv
./venv/Scripts/Activate.ps1
pip # you should get the error "No module named 'pip'
cd ./venv/
fsutil.exe file setCaseSensitiveInfo . disable
pip # the command now works
```

This wasn't an issue prior to upgrading to Windows 11, so something may have changed in the handling of the case sensitivity flag on Windows. 

I have a venv created on windows 10, prior to my windows 11 upgrade that does work. 

I didn't encounter the issue until setting up an installation of Python 3.9.10 to support another project, then trying to create a new 3.10.2 venv. 

I can work around the issue by specifically disabling case sentitivity in my venv folders, but it would be nice if venvs worked out of the box with case sensitive filesytems on windows. 


It seems like some code is making assumptions about case sensitivity on windows. 




I found that if I disable case sensitivity in the venv folder, the venv starts working again.

----------
title: Windows 11 venv -> Windows 11, VENV not working with case sensitive windows paths

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


More information about the Python-bugs-list mailing list