Skip to content
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ Vagrantfile
venv
.eggs
.cache
.python-version
*.lprof

# no uv lockfile until this is fixed:
# https://github.com/astral-sh/uv/issues/10845
Expand Down
110 changes: 53 additions & 57 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,65 +1,64 @@
# Note: code auto-formatted with `taplo fmt`
Comment thread
perrygeo marked this conversation as resolved.
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "rasterstats"
description = "Summarize geospatial raster datasets based on vector geometries"
authors = [
{name = "Matthew Perry", email = "perrygeo@gmail.com"},
]
authors = [{ name = "Matthew Perry", email = "perrygeo@gmail.com" }]
readme = "README.rst"
keywords = ["gis", "geospatial", "geographic", "raster", "vector", "zonal statistics"]
keywords = [
"gis",
"geospatial",
"geographic",
"raster",
"vector",
"zonal statistics",
]
dynamic = ["version"]
license = {text = "BSD-3-Clause"}
license = { text = "BSD-3-Clause" }
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Utilities",
"Topic :: Scientific/Engineering :: GIS",
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Utilities",
"Topic :: Scientific/Engineering :: GIS",
]
requires-python = ">=3.9"
dependencies = [
"affine",
"click >7.1, !=8.2.1",
"cligj >=0.4",
"fiona",
"numpy >=1.9",
"rasterio >=1.0",
"simplejson",
"shapely",
"affine",
"click >7.1, !=8.2.1",
"cligj >=0.4",
"numpy >=1.9",
"pyogrio",
"rasterio >=1.0",
"simplejson",
"shapely",
]

[project.optional-dependencies]
progress = [
"tqdm"
]
docs = [
"numpydoc",
"sphinx",
"sphinx-rtd-theme",
]
progress = ["tqdm"]
fiona = ["fiona"]
docs = ["numpydoc", "sphinx", "sphinx-rtd-theme"]
test = [
"coverage",
"geopandas",
"pyshp >=1.1.4",
"pytest >=4.6",
"pytest-cov >=2.2.0",
"simplejson",
]
dev = [
"rasterstats[test]",
"ruff",
"twine",
"coverage",
"geopandas",
"pyshp >=1.1.4",
"pytest >=4.6",
"pytest-cov >=2.2.0",
"simplejson",
]
dev = ["rasterstats[test,fiona]", "ruff", "twine"]

[project.entry-points."rasterio.rio_plugins"]
zonalstats = "rasterstats.cli:zonalstats"
Expand All @@ -73,31 +72,28 @@ Documentation = "https://pythonhosted.org/rasterstats/"
only-include = ["src", "tests"]

[tool.pytest.ini_options]
filterwarnings = [
"error",
"ignore::UserWarning",
]
filterwarnings = ["error", "ignore::UserWarning"]
testpaths = ["tests"]
# addopts = "--verbose -rf --ipdb --maxfail=1"
addopts = "--verbose -rf --cov rasterstats --cov-report html"

[tool.setuptools.dynamic]
version = {attr = "rasterstats._version.__version__"}
version = { attr = "rasterstats._version.__version__" }

[tool.hatch.version]
path = "src/rasterstats/_version.py"

[tool.ruff.lint]
select = [
"E", # pycodestyle
"F", # Pyflakes
"I", # isort
"RUF", # Ruff-specific rules
"UP", # pyupgrade
"E", # pycodestyle
"F", # Pyflakes
"I", # isort
"RUF", # Ruff-specific rules
"UP", # pyupgrade
]
ignore = [
"RUF005", # Consider iterable unpacking instead of concatenation
"E501", # Disable: line too long
"RUF005", # Disable: Consider iterable unpacking instead of concatenation
]

[tool.ruff]
# TODO: files in docs/notebooks/ use old versions and are incompatible with modern tools
extend-exclude = ["*.ipynb"]
Loading
Loading