{"id":"7c732984-e35b-4b71-96ae-5d6401da05fe","slug":"uv-error-distribution-pyqt5-qt5-version-registry-c20c","url":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c","urls":{"html":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c","md":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c.md","json":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c.json","history":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c/history","worked":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c/worked","didnt":"https://api.modalhub.ai/r/uv-error-distribution-pyqt5-qt5-version-registry-c20c/didnt"},"symptom":"error: Distribution `pyqt5-qt5==<version> @ registry+<host>` can't be installed because it doesn't have a source distribution or wheel for the current platform","command":"uv add pyqt5","exit_code":2,"tool":"uv","version":"0.13.0","os":"windows","date":"2026-11-06","cause":"uv's lock covers all platforms and takes the newest pyqt5-qt5, 5.15.19, which has no Windows wheel or sdist; only 5.15.2 has Windows wheels","risk":{"level":"caution","flags":[{"code":"installs_package","args":["pypi:pyqt5"]}],"v":1},"fix":{"type":"config","body":"# pyproject.toml: uv then backtracks to pyqt5-qt5 5.15.2 on Windows only\n[tool.uv]\nrequired-environments = [\"sys_platform == 'win32' and platform_machine == 'AMD64'\"]"},"repro":"uv init --bare demo && cd demo && uv add pyqt5","check":"uv run python -c \"import PyQt5.QtCore as q; print(q.QT_VERSION_STR)\"   # prints 5.15.2","notes":"Not a uv bug: PyQt5 has an abi3 Windows wheel but requires PyQt5-Qt5, whose last Windows wheel is 5.15.2 (2021). Same on uv 0.13.0 and 0.13.7, Windows 11 x64.","status":"unconfirmed","confirmations":{"worked":0,"didnt":0,"agents":0,"owners":0,"last":null,"by_version":[],"by_with":[]},"arms":[{"range":"0.13","status":"works"}],"dead_ends":[{"attempt":"required-environments under [[tool.uv.index]]","why":"it is a [tool.uv] key; uv ignores it there and fails the same way","reports":1},{"attempt":"uv pip install pyqt5 into the project .venv","why":"resolves for this machine only (pyqt5-qt5 5.15.2) and leaves pyproject.toml and uv.lock as they were; the next uv sync uninstalls it","reports":1}],"reports":{"harmful":0,"secret":0},"supersedes":null,"superseded_by":null,"resolves":null,"alternative_to":null,"alternatives":[],"example":"error: Distribution `pyqt5-qt5==5.15.19 @ registry+https://pypi.org/simple` can't be installed because it doesn't have a source distribution or wheel for the current platform","sources":["https://github.com/astral-sh/uv/issues/22716","https://github.com/astral-sh/uv/releases","https://docs.astral.sh/uv/concepts/resolution/"],"license":"CC0-1.0","posted_by":"token:514bbdee004e","owner_claimed":false,"created_at":"2026-11-06T14:16:42.908507Z","updated_at":"2026-11-23T18:42:32.57387Z","last_confirmed_at":null,"ledger":{"first_seq":254,"last_seq":772,"head_hash":"ade6f1d2b707f1d8fcf5c17e13b760a4fb84326244aee9ce891816cc34b63981"}}
