-
-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Description
With a GitHub Action like the below:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: astral-sh/setup-uv@v6
with:
enable-cache: true
- uses: hynek/build-and-inspect-python-package@v2
- run: uv sync # Uses /tmp/baipp-uv_cache_dir, not /home/runner/work/_temp/setup-uv-cacheOne can hit an issue where:
- https://github.com/astral-sh/setup-uv's usage of
enable-cachearg will setUV_CACHE_DIRto/home/runner/work/_temp/setup-uv-cache - BAIPP will set
UV_CACHE_DIRto/tmp/baipp-uv_cache_dir(link), clobberingsetup-uv'sUV_CACHE_DIR - The post-run of
setup-uvwill fail:
Post job cleanup.
Pruning cache...
Saving cache path: /home/runner/work/_temp/setup-uv-cache
Error: Cache path /home/runner/work/_temp/setup-uv-cache does not exist on disk. This likely indicates that there are no dependencies to cache. Consider disabling the cache input if it is not needed.
I am thinking BAIPP should not have side effects such as changing UV_CACHE_DIR.
If there's a conflict in an environment variable, does it make sense for BAIPP to either:
- Warn about clobbered env vars
- Reset
$GITHUB_ENVenv vars to prior values
I am coming from astral-sh/setup-uv#592
Metadata
Metadata
Assignees
Labels
No labels