55 pull_request :
66 branches : [main]
77
8+ env :
9+ LATEST_PY_VERSION : ' 3.14'
10+
811jobs :
912 test :
1013 runs-on : ubuntu-latest
1114 strategy :
1215 matrix :
13- python-version : ["3.9", "3.10", "3.11", "3.12", "3.13"]
16+ python-version : ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14" ]
1417 timeout-minutes : 20
1518
1619 steps :
1720 - name : Check out repository code
1821 uses : actions/checkout@v5
19-
20- # Setup Python (faster than using Python container)
21- - name : Setup Python
22- uses : actions/setup-python@v6
22+
23+ - name : Install uv
24+ uses : astral-sh/setup-uv@v3
2325 with :
24- python-version : ${{ matrix.python-version }}
25-
26- - name : Lint code
27- if : ${{ matrix.python-version == 3.13 }}
28- run : |
29- python -m pip install pre-commit
30- pre-commit run --all-files
31-
32- - name : Install types
33- run : |
34- python -m pip install ./stac_fastapi/types[dev]
26+ version : " 0.9.*"
27+ enable-cache : true
28+
29+ - name : Set up Python ${{ matrix.python-version }}
30+ run : uv python install ${{ matrix.python-version }}
3531
36- - name : Install core api
32+ - name : Install dependencies
3733 run : |
38- python -m pip install ./stac_fastapi/api[dev]
34+ uv sync --all-extras
3935
40- - name : Install Extensions
36+ - name : Lint code
37+ if : ${{ matrix.python-version == env.LATEST_PY_VERSION }}
4138 run : |
42- python -m pip install ./stac_fastapi/extensions[dev]
39+ uv run pre-commit run --all-files
4340
44- - name : Test
45- run : python -m pytest -svvv
41+ - name : Run tests
42+ run : uv run pytest -svvv
4643 env :
4744 ENVIRONMENT : testing
4845
@@ -60,25 +57,21 @@ jobs:
6057 - name : Check out repository code
6158 uses : actions/checkout@v5
6259
63- - name : Setup Python
64- uses : actions /setup-python@v6
60+ - name : Install uv
61+ uses : astral-sh /setup-uv@v3
6562 with :
66- python-version : " 3.13"
67-
68- - name : Install types
69- run : |
70- python -m pip install ./stac_fastapi/types[dev]
71-
72- - name : Install core api
73- run : |
74- python -m pip install ./stac_fastapi/api[dev,benchmark]
63+ version : " 0.9.*"
64+ enable-cache : true
65+
66+ - name : Set up Python3
67+ run : uv python install 3
7568
76- - name : Install extensions
69+ - name : Install dependencies
7770 run : |
78- python -m pip install ./stac_fastapi/extensions
71+ uv sync --all-extras
7972
8073 - name : Run Benchmark
81- run : python -m pytest stac_fastapi/api/tests/benchmarks.py --benchmark-only --benchmark-columns 'min, max, mean, median' --benchmark-json output.json
74+ run : uv run pytest stac_fastapi/api/tests/benchmarks.py --benchmark-only --benchmark-columns 'min, max, mean, median' --benchmark-json output.json
8275
8376 - name : Store and benchmark result
8477 if : github.repository == 'stac-utils/stac-fastapi'
0 commit comments