Skip to content

Commit

Permalink
Use official setup-uv action and built-in caching
Browse files Browse the repository at this point in the history
  • Loading branch information
JWCook committed Jan 22, 2025
1 parent fbc37eb commit f4d4ca0
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 12 deletions.
13 changes: 4 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,21 +21,16 @@ jobs:
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']

steps:
# Install prereqs and dependencies, with caching
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- uses: yezz123/setup-uv@v4

# Cache packages per python version, and reuse until lockfile changes
- name: Cache python packages
id: cache
uses: actions/cache@v4
- uses: astral-sh/setup-uv@v5
with:
path: .venv
key: venv-${{ matrix.python-version }}-${{ hashFiles('uv.lock') }}
enable-cache: true
cache-dependency-glob: uv.lock
- name: Install dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: uv sync

# Run tests with coverage report
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: ${{ env.LATEST_PY_VERSION }}
- uses: yezz123/setup-uv@v4
- uses: astral-sh/setup-uv@v5

- name: Set pre-release version
if: ${{ !startsWith(github.ref, 'refs/tags/v') }}
Expand Down
2 changes: 1 addition & 1 deletion HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# History

## 0.20.1 (Unreleased)
## 0.20.1 (2025-01-18)
* Fix `AttributeError` when initializing `Observation.taxon` with a `Taxon` object

## 0.20.0 (2025-01-02)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = 'pyinaturalist'
version = '0.20.1'
version = '0.20.2'
description = 'iNaturalist API client for python'
authors = [{ name = 'Jordan Cook' }]
license = 'MIT'
Expand Down

0 comments on commit f4d4ca0

Please sign in to comment.