Skip to content

Commit 1ddcd78

Browse files
honzajavorekclaude
andcommitted
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 <noreply@anthropic.com>
1 parent 85d00d0 commit 1ddcd78

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

‎.readthedocs.yml‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,15 @@ build:
77
# Install exactly what's in uv.lock, same as CI
88
# https://docs.readthedocs.com/platform/stable/build-customization.html#install-dependencies-with-uv
99
# uv comes from PyPI, because installing it with asdf resolves "latest"
10-
# through GitHub, which fails intermittently on Read the Docs
10+
# through GitHub, which fails intermittently on Read the Docs. The reshim
11+
# puts the uv command on PATH, so it works even after the venv activates.
1112
pre_create_environment:
1213
- python -m pip install uv
14+
- asdf reshim python
1315
create_environment:
14-
- python -m uv venv "${READTHEDOCS_VIRTUALENV_PATH}"
16+
- uv venv "${READTHEDOCS_VIRTUALENV_PATH}"
1517
install:
16-
- UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" python -m uv sync --frozen --no-dev
18+
- UV_PROJECT_ENVIRONMENT="${READTHEDOCS_VIRTUALENV_PATH}" uv sync --frozen --no-dev
1719
sphinx:
1820
configuration: docs/conf.py
1921
fail_on_warning: true

0 commit comments

Comments
 (0)