[New-bugs-announce] [issue44567] venv fails when called from within long path on Windows

schwaerz report at bugs.python.org
Mon Jul 5 11:51:01 EDT 2021


New submission from schwaerz <joerg.schwaerzler at infineon.com>:

When trying to create a venv from within a long path name in Windows 10 (long paths enabled in the registry), python crashes. Used python 3.9.6.

When reducing the path length by one character, it starts working.
When disabling the long path support in Windows, I get an error message about paths being too long.

btw.: I can see same / similar behavior when using virtualenv/pipenv/poetry (did not try any other venv-like tooling...)

For the instructions please check the following snippet:

d:\slave\workspace\1--folder-with-232-character-absolute-path-length----------------------------------------------------------------------------------------------------------------------------------------------------------------232>python -m venv .venv
Error: Command '['d:\\slave\\workspace\\1--folder-with-232-character-absolute-path-length----------------------------------------------------------------------------------------------------------------------------------------------------------------232\\.venv\\Scripts\\python.exe', '-Im', 'ensurepip', '--upgrade', '--default-pip']' returned non-zero exit status 3221226505.

%Errorlevel% sometimes was 1 and sometimes was -1073740791 (0xc0000409). Unfortunately I cannot recalled what I had to do to get the latter one... I tried with python 3.8.0, too. Same behavior.

----------
components: Windows
messages: 397000
nosy: paul.moore, schwaerz, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: venv fails when called from within long path on Windows
versions: Python 3.8, Python 3.9

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


More information about the New-bugs-announce mailing list