diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ddc4b64..ad59fe3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,7 +17,7 @@ permissions: contents: read env: - PYTHON_VERSION: "3.8" + PYTHON_VERSION: "3.9" RUST_BACKTRACE: "1" diff --git a/h3ronpy/CHANGES.rst b/h3ronpy/CHANGES.rst index 1748098..40484c4 100644 --- a/h3ronpy/CHANGES.rst +++ b/h3ronpy/CHANGES.rst @@ -12,6 +12,8 @@ Versioning `__. Unreleased ---------- +- The minimum supported python version is now 3.9. + 0.21.1 - 2024-10-04 ------------------- diff --git a/h3ronpy/Cargo.toml b/h3ronpy/Cargo.toml index 0c731ff..fdc7448 100644 --- a/h3ronpy/Cargo.toml +++ b/h3ronpy/Cargo.toml @@ -25,6 +25,6 @@ ndarray = { version = "0.15", features = ["rayon"] } numpy = "0.21" ordered-float = ">=2.0.1" py_geo_interface = { version = "0.8", features = ["f64", "wkb"] } -pyo3 = { version = "0.21", features = ["extension-module", "abi3", "abi3-py38"] } +pyo3 = { version = "0.21", features = ["extension-module", "abi3", "abi3-py39"] } rasterh3 = { version = "^0.8", features = ["rayon"] } rayon = { workspace = true } diff --git a/h3ronpy/pyproject.toml b/h3ronpy/pyproject.toml index f5643b9..412f92e 100644 --- a/h3ronpy/pyproject.toml +++ b/h3ronpy/pyproject.toml @@ -1,6 +1,6 @@ [build-system] requires = [ - "maturin==1.2", + "maturin>=1.7", ] build-backend = "maturin" @@ -21,8 +21,7 @@ readme = "../README.rst" dependencies = [ "numpy<2", - "pyarrow>=10.0", - "Shapely>=1.7", + "pyarrow>=17.0" ] classifiers = [ "Programming Language :: Python :: 3", @@ -33,14 +32,14 @@ classifiers = [ [project.optional-dependencies] polars = [ - "polars>=1.0" + "polars>=1" ] pandas = [ - "geopandas>=0.10", - "fiona<1.10" + "geopandas>=1" ] test = [ "rasterio", + "Shapely>=1.7", "pytest>=6", "h3>=3.7", "pytest-benchmark" diff --git a/h3ronpy/python/h3ronpy/arrow/raster.py b/h3ronpy/python/h3ronpy/arrow/raster.py index 95b0ccc..1dbb03b 100644 --- a/h3ronpy/python/h3ronpy/arrow/raster.py +++ b/h3ronpy/python/h3ronpy/arrow/raster.py @@ -28,7 +28,6 @@ """ -import shapely from h3ronpy.h3ronpyrs import raster from .. import DEFAULT_CELL_COLUMN_NAME from . import _to_uint64_array, _to_arrow_array @@ -136,7 +135,7 @@ def rasterize_cells( """ Generate a raster numpy array from arrays of cells and values. - This function requires the ``rasterio`` library. + This function requires the ``rasterio`` and `shapely` libraries to be installed. :param cells: array with H3 cells :param values: array with the values which shall be written into the raster @@ -148,6 +147,7 @@ def rasterize_cells( """ from rasterio.transform import from_bounds from rasterio.features import rasterize + import shapely cells = _to_uint64_array(cells) values = _to_arrow_array(values, None)