From a9e30537f6468b35f32b093384438946d7f5a482 Mon Sep 17 00:00:00 2001 From: "Gregory H. Halverson" Date: Thu, 5 Mar 2026 15:16:16 -0800 Subject: [PATCH 1/2] Update python-publish workflow to use PyPI trusted publishers with OIDC --- .github/workflows/python-publish.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index b7a704b..d03fd84 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -14,6 +14,7 @@ on: permissions: contents: read + id-token: write jobs: deploy: @@ -23,7 +24,7 @@ jobs: steps: - uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v3 + uses: actions/setup-python@v4 with: python-version: '3.x' - name: Install dependencies @@ -33,7 +34,6 @@ jobs: - name: Build package run: python -m build - name: Publish package - uses: pypa/gh-action-pypi-publish@27b31702a0e7fc50959f5ad993c78deac1bdfc29 + uses: pypa/gh-action-pypi-publish@release/v1 with: - user: __token__ - password: ${{ secrets.PYPI_API_TOKEN }} + repository-url: https://upload.pypi.org/legacy/ From 311dd58005dc1524919eca19818a071bd3b90c54 Mon Sep 17 00:00:00 2001 From: "Gregory H. Halverson" Date: Mon, 27 Jul 2026 14:26:00 -0700 Subject: [PATCH 2/2] fixing BBox issue in wrap_geometry --- pyproject.toml | 2 +- rasters/wrap_geometry.py | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index b8befdf..3853b63 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "rasters" -version = "1.18.0" +version = "1.19.0" description = "raster processing toolkit" readme = "README.md" authors = [ diff --git a/rasters/wrap_geometry.py b/rasters/wrap_geometry.py index c1b2623..1750de8 100644 --- a/rasters/wrap_geometry.py +++ b/rasters/wrap_geometry.py @@ -50,9 +50,8 @@ def wrap_geometry(geometry: Any, crs: Union[CRS, str] = None) -> SpatialGeometry # If the geometry is a RasterGeometry, return it as is return geometry - # Check if the geometry is already a SpatialGeometry by checking for specific types - if isinstance(geometry, (Point, MultiPoint, Polygon, MultiPolygon)): - # If the geometry is already a SpatialGeometry, return it as is + # If the geometry is already a SpatialGeometry (e.g., BBox), return it as is. + if isinstance(geometry, SpatialGeometry): return geometry if isinstance(geometry, GeoSeries) and all(geometry.geom_type == 'Point'):