Skip to content

Commit e6389e6

Browse files
Add a upstream workflow with a dispatch trigger; follow SPEC0 (#1245)
* switch to uv * switch to hatch * switch to hatch * update changelog * Add a upstream workflow with a dispatch trigger; follow SPEC0 * Update .github/workflows/upstream.yml Co-authored-by: Vincent Sarago <[email protected]> * Only run on commits to main that change xarray extension * Don't bother on tags * Run on multiple python versions --------- Co-authored-by: vincentsarago <[email protected]>
1 parent 1e4bdd6 commit e6389e6

File tree

3 files changed

+44
-2
lines changed

3 files changed

+44
-2
lines changed

.github/workflows/upstream.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Upstream
2+
3+
# Only on pushes to main, tags, or workflow dispatches
4+
on:
5+
push:
6+
branches:
7+
- main
8+
paths:
9+
# Only run test and docker publish if some code have changed
10+
- 'src/titiler/xarray/**'
11+
workflow_dispatch:
12+
13+
jobs:
14+
test-upstream:
15+
runs-on: ubuntu-latest
16+
strategy:
17+
matrix:
18+
python-version: ['3.11', '3.12', '3.13']
19+
20+
steps:
21+
- uses: actions/checkout@v5
22+
23+
- name: Set up uv
24+
uses: astral-sh/setup-uv@v6
25+
with:
26+
python-version: ${{ matrix.python-version }}
27+
28+
- name: Test titiler.xarray
29+
working-directory: src/titiler/xarray
30+
run: |
31+
uv run --group test --group upstream pytest

src/titiler/xarray/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ Here is the list of available options:
2727
- **s3**: `s3fs`
2828
- **http**: `aiohttp`
2929

30+
#### Dependencies
31+
32+
Titiler.xarray follows [SPEC 0](https://scientific-python.org/specs/spec-0000/), similar to [xarray](https://docs.xarray.dev/en/v2025.09.0/getting-started-guide/installing.html#minimum-dependency-versions).
33+
3034
## How To
3135

3236
```python

src/titiler/xarray/pyproject.toml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "titiler-xarray"
33
description = "Xarray plugin for TiTiler."
44
readme = "README.md"
5-
requires-python = ">=3.10"
5+
requires-python = ">=3.11"
66
authors = [
77
{name = "Vincent Sarago", email = "[email protected]"},
88
{name = "Aimee Barciauskas", email = "[email protected]"},
@@ -21,7 +21,6 @@ classifiers = [
2121
"Intended Audience :: Science/Research",
2222
"License :: OSI Approved :: MIT License",
2323
"Programming Language :: Python :: 3",
24-
"Programming Language :: Python :: 3.10",
2524
"Programming Language :: Python :: 3.11",
2625
"Programming Language :: Python :: 3.12",
2726
"Programming Language :: Python :: 3.13",
@@ -62,6 +61,7 @@ s3 = [
6261
http = [
6362
"aiohttp",
6463
]
64+
[dependency-groups]
6565
test = [
6666
"pytest",
6767
"pytest-cov",
@@ -74,6 +74,13 @@ test = [
7474
"aiohttp",
7575
"requests",
7676
]
77+
upstream = [
78+
'xarray @ git+https://github.com/pydata/xarray',
79+
'universal_pathlib @ git+https://github.com/fsspec/universal_pathlib',
80+
'numcodecs @ git+https://github.com/zarr-developers/numcodecs',
81+
'ujson @ git+https://github.com/ultrajson/ultrajson',
82+
'zarr @ git+https://github.com/zarr-developers/zarr-python',
83+
]
7784

7885
[project.urls]
7986
Homepage = "https://developmentseed.org/titiler/"

0 commit comments

Comments
 (0)