Search code examples
python-3.xpython-poetry

Poetry install failed Windows


Error message

After trying to install poetry with: python3 ./install-poetry.py --version 1.2.0a2 got the following error:

File "C:...pyenv\pyenv-win\versions\3.10.0b3\lib\subprocess.py", line 1434, in _execute_child
    hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] The system cannot find the file specified

Solution

  • Got the same error using “python3”, try providing the link to the executable e.g. "C:...pyenv\pyenv-win\versions\3.7.9\python.exe" instead of python3.

    This solved the problem for me.