From 85d00d0b732b1f18507ad5e629c11619d60faf13 Mon Sep 17 00:00:00 2001 From: Honza Javorek Date: Thu, 5 Nov 2026 10:00:14 +0100 Subject: [PATCH 1/2] Install uv from PyPI on Read the Docs Installing uv with asdf resolves "latest" through GitHub, which failed on Read the Docs with "No compatible versions available (uv [0-9])". Co-Authored-By: Claude Opus 5.5 --- .readthedocs.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.readthedocs.yml b/.readthedocs.yml index d42c8f9..1aceac4 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -6,14 +6,14 @@ build: jobs: # Install exactly what's in uv.lock, same as CI # https://docs.readthedocs.com/platform/stable/build-customization.html#install-dependencies-with-uv + # uv comes from PyPI, because installing it with asdf resolves "latest" + # through GitHub, which fails intermittently on Read the Docs pre_create_environment: - - asdf plugin add uv - - asdf install uv latest - - asdf global uv latest + - python -m pip install uv create_environment: - - uv venv "${READTHEDOCS_VIRTUALENV_PATH}" + - python -m uv venv "${READTHEDOCS_VIRTUALENV_PATH}" install: - - UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" uv sync --frozen --no-dev + - UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" python -m uv sync --frozen --no-dev sphinx: configuration: docs/conf.py fail_on_warning: true From 1ddcd7888e96e57d5f113fdaf767f353273b6bc3 Mon Sep 17 00:00:00 2001 From: Honza Javorek Date: Thu, 5 Nov 2026 10:02:10 +0100 Subject: [PATCH 2/2] Make uv available after Read the Docs activates the venv Once the venv exists, python points to it, and it has no uv module. Reshim asdf so the uv command from the base Python is on PATH. Co-Authored-By: Claude Opus 5.5 --- .readthedocs.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.readthedocs.yml b/.readthedocs.yml index 1aceac4..bbd92e2 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -7,13 +7,15 @@ build: # Install exactly what's in uv.lock, same as CI # https://docs.readthedocs.com/platform/stable/build-customization.html#install-dependencies-with-uv # uv comes from PyPI, because installing it with asdf resolves "latest" - # through GitHub, which fails intermittently on Read the Docs + # through GitHub, which fails intermittently on Read the Docs. The reshim + # puts the uv command on PATH, so it works even after the venv activates. pre_create_environment: - python -m pip install uv + - asdf reshim python create_environment: - - python -m uv venv "${READTHEDOCS_VIRTUALENV_PATH}" + - uv venv "${READTHEDOCS_VIRTUALENV_PATH}" install: - - UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" python -m uv sync --frozen --no-dev + - UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" uv sync --frozen --no-dev sphinx: configuration: docs/conf.py fail_on_warning: true