#11034·poetry

poetry update fails on win10_x64

Author: farzboodCreated Aug 30, 2026Updated Aug 30, 2026
Labelskind/bugstatus/triage

Description

the poetry self update command failing to complete update process (in windows powershell).

Workarounds

perform a clean install, instead updating. PS C:\Windows\system32> (Invoke-WebRequest -Uri https://install.python-poetry.org -UseBasicParsing).Content | python3 - Retrieving Poetry metadata

Welcome to Poetry!

This will download and install the latest version of Poetry, a dependency and package manager for Python.

It will add the poetry command to Poetry's bin directory, located at:

C:\Users\IPEN\AppData\Roaming\Python\Scripts

You can uninstall at any time by executing this script with the --uninstall option, and these changes will be reverted.

Installing Poetry (2.4.2) Installing Poetry (2.4.2): Saving existing environment Installing Poetry (2.4.2): Creating environment Installing Poetry (2.4.2): Installing Poetry Installing Poetry (2.4.2): Creating script Installing Poetry (2.4.2): Done

Poetry (2.4.2) is installed now. Great!

You can test that everything is set up by executing:

poetry --version

Poetry Installation Method

[edit] official installer

Operating System

win10_x64

Poetry Version

2.4.2

Poetry Configuration

bash
cache-dir = "C:\\Users\\IPEN\\AppData\\Local\\pypoetry\\Cache"
data-dir = "C:\\Users\\IPEN\\AppData\\Roaming\\pypoetry"
installer.max-workers = null
installer.no-binary = null
installer.only-binary = null
installer.parallel = true
installer.re-resolve = false
keyring.enabled = true
python.installation-dir = "{data-dir}\\python"  # C:\Users\IPEN\AppData\Roaming\pypoetry\python
requests.max-retries = 0
solver.lazy-wheel = true
solver.min-release-age = 0
solver.min-release-age-exclude = null
solver.min-release-age-exclude-source = null
system-git-client = false
virtualenvs.create = true
virtualenvs.in-project = true
virtualenvs.options.always-copy = false
virtualenvs.options.no-pip = false
virtualenvs.options.system-site-packages = false
virtualenvs.path = "{cache-dir}\\virtualenvs"  # C:\Users\IPEN\AppData\Local\pypoetry\Cache\virtualenvs
virtualenvs.prompt = "{project_name}-py{python_version}"
virtualenvs.use-poetry-python = false

Python Sysconfig

Platform: "win-amd64" Python version: "3.13" Current installation scheme: "nt"

Paths: data = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" include = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Include" platinclude = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Include" platlib = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib\site-packages" platstdlib = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib" purelib = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib\site-packages" scripts = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Scripts" stdlib = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib"

Variables: BINDIR = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" BINLIBDEST = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib" EXE = ".exe" EXT_SUFFIX = ".cp313-win_amd64.pyd" INCLUDEPY = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Include" LDLIBRARY = "python313.dll" LIBDEST = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib" LIBDIR = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\libs" LIBRARY = "python313.dll" Py_GIL_DISABLED = "0" SOABI = "cp313-win_amd64" TZPATH = "" VERSION = "313" VPATH = "...." abi_thread = "" abiflags = "" base = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" exec_prefix = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" implementation = "Python" implementation_lower = "python" installed_base = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" installed_platbase = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" platbase = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" platlibdir = "DLLs" prefix = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" projectbase = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" py_version = "3.13.7" py_version_nodot = "313" py_version_nodot_plat = "313" py_version_short = "3.13" srcdir = "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7" userbase = "C:\Users\IPEN\AppData\Roaming\Python"

Example pyproject.toml

toml

Poetry Runtime Logs

powershell prompt output:

Windows PowerShell Copyright (C) Microsoft Corporation. All rights reserved.

Try the new cross-platform PowerShell https://aka.ms/pscore6

PS C:\Windows\system32> poetry self update Updating Poetry version ...

Using version ^2.4.2 for poetry

Updating dependencies Resolving dependencies... (130.7s)

Package operations: 0 installs, 21 updates, 0 removals

  • Updating certifi (2026.5.20 -> 2026.7.22)
  • Updating idna (3.17 -> 3.19)
  • Updating anyio (4.13.0 -> 4.14.2)
  • Updating charset-normalizer (3.4.7 -> 3.5.1)
  • Updating filelock (3.29.0 -> 3.32.4)
  • Updating backports-zstd (1.5.0 -> 1.7.0)
  • Updating distlib (0.4.0 -> 0.4.3)
  • Updating jaraco-functools (4.5.0 -> 4.6.0)
  • Updating msgpack (1.1.2 -> 1.2.2)
  • Updating packaging (26.2 -> 26.3)
  • Updating platformdirs (4.10.0 -> 4.11.5)
  • Updating python-discovery (1.4.0 -> 1.6.0)
  • Updating build (1.5.0 -> 1.6.0)
  • Updating dulwich (1.2.5 -> 1.2.14)
  • Updating fastjsonschema (2.21.2 -> 2.22.2)
  • Updating pbs-installer (2026.5.10 -> 2026.8.25)
  • Updating pkginfo (1.12.1.2 -> 1.13)
  • Updating tomlkit (0.15.0 -> 0.15.1)
  • Updating trove-classifiers (2026.5.22.10 -> 2026.6.1.19)
  • Updating virtualenv (21.4.1 -> 21.7.7)
  • Updating poetry (2.4.1 -> 2.4.2): Failed

CalledProcessError

Command '['C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Scripts\python.exe', '-m', 'pip', 'uninstall', 'poetry', '-y']' returned non-zero exit status 2.

at ~.pyenv\pyenv-win\versions\3.13.7\Lib\subprocess.py:577 in run 573│ # We don't call process.wait() as .exit does that for us. 574│ raise 575│ retcode = process.poll() 576│ if check and retcode: → 577│ raise CalledProcessError(retcode, process.args, 578│ output=stdout, stderr=stderr) 579│ return CompletedProcess(process.args, retcode, stdout, stderr) 580│ 581│

The following error occurred when trying to handle this error:

EnvCommandError

Command ['C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Scripts\python.exe', '-m', 'pip', 'uninstall', 'poetry', '-y'] errored with the following return code 2

Output: Found existing installation: poetry 2.4.1 Uninstalling poetry-2.4.1: ERROR: Exception: Traceback (most recent call last): File "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib\shutil.py", line 856, in move os.rename(src, real_dst) ~~~~~~~~~^^^^^^^^^^^^^^^ PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: 'c:\\users\ipen\appdata\roaming\pypoetry\venv\scripts\poetry.exe' -> 'C:\Users\IPEN\AppData\Local\Temp\pip-uninstall-oezrh9bc\poetry.exe' During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\cli\base_command.py", line 109, in _run_wrapper status = _inner_run() File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\cli\base_command.py", line 102, in _inner_run return self.run(options, args) ~~~~~~~~^^^^^^^^^^^^^^^ File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\commands\\uninstall.py", line 105, in run uninstall_pathset = req.uninstall( auto_confirm=options.yes, verbose=self.verbosity > 0, ) File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\req\req_install.py", line 685, in uninstall uninstalled_pathset.remove(auto_confirm, verbose) ~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\req\req_uninstall.py", line 373, in remove moved.stash(path) ~~~~~~~~~~~^^^^^^ File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\req\req_uninstall.py", line 264, in stash renames(path, new_path) ~~~~~~~^^^^^^^^^^^^^^^^ File "C:\Users\IPEN\AppData\Roaming\pypoetry\venv\Lib\site-packages\pip_internal\\utils\misc.py", line 344, in renames shutil.move(old, new) ~~~~~~~~~~~^^^^^^^^^^ File "C:\Users\IPEN.pyenv\pyenv-win\versions\3.13.7\Lib\shutil.py", line 877, in move os.unlink(src) ~~~~~~~~~^^^^^ PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: 'c:\\users\ipen\appdata\roaming\pypoetry\venv\scripts\poetry.exe'

at venv\Lib\site-packages\poetry\\utils\env\base_env.py:453 in _run

C