Skip to content
Open
Show file tree
Hide file tree
Changes from all 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
6 changes: 3 additions & 3 deletions .github/workflows/build-wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install wheel
- name: Build bdist_wheel
run: python setup.py bdist_wheel
pip install build wheel
- name: Build wheel
run: python3 -m build
- uses: actions/upload-artifact@v4
with:
path: dist/*.whl
4 changes: 1 addition & 3 deletions .github/workflows/unittests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,11 @@ name: Unit tests
on:
push:
paths:
- 'setup.py'
- 'pyproject.toml'
- 'openeo/**'
- 'tests/**'
pull_request:
paths:
- 'setup.py'
- 'pyproject.toml'
- 'openeo/**'
- 'tests/**'
Expand Down Expand Up @@ -42,6 +40,6 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install .[tests]
python -m pip install -e .[tests]

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error message looks similar so I think this is the root cause for the failing non-public CI as well, but I'm not sure I can fix that.

- name: Test with pytest
run: pytest
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- Convert setup.py to pyproject.toml ([#920](https://github.com/Open-EO/openeo-python-client/issues/920))

### Removed

### Fixed
Expand Down
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
include pyproject.toml
include openeo/extra/spectral_indices/resources/*.json
include openeo/extra/spectral_indices/resources/*/*.json
include openeo/extra/spectral_indices/resources/*/LICENSE*
4 changes: 2 additions & 2 deletions docs/development.rst
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ Prerequisites
Important files
---------------

``setup.py``
``pyproject.toml``
describes the metadata of the package,
like package name ``openeo`` and version
(which is extracted from ``openeo/_version.py``).
Expand Down Expand Up @@ -289,7 +289,7 @@ we will use a concrete version ``0.8.0`` in the examples below.
- *Or, if you know what you are doing* and you're sure you have a clean
local checkout, you can also build it locally::

python setup.py bdist_wheel
python -m build -w

This should create ``dist/openeo-0.8.0-py3-none-any.whl``

Expand Down
143 changes: 140 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,144 @@
[build-system]
requires = ["setuptools>=69"]
build-backend = "setuptools.build_meta"

#[build-system]
#requires = ["setuptools"]
#build-backend = "setuptools.build_meta"
[project]
name = "openeo"
dynamic = ["version"]
description = "Client API for openEO"
readme = "README.md"
license = { text = "Apache-2.0" }
requires-python = ">=3.8"
authors = [
{ name = "Jeroen Dries", email = "jeroen.dries@vito.be" },
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.8",
"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",
]
dependencies = [
"deprecated>=1.2.12",
# TODO #717 Simplify geopandas constraints when Python 3.8 support is dropped
"geopandas", # Best-effort geopandas dependency for Python 3.8
"geopandas>=0.14; python_version>='3.9'",
"importlib_resources; python_version<'3.9'",
"numpy>=1.17.0",
"oschmod>=0.3.12; sys_platform == \"win32\"",
"pandas>0.20.0,<3.0.0", # TODO pandas 3 compatibility https://github.com/Open-EO/openeo-python-client/issues/856
# TODO #578: pystac 1.5.0 is highest version available for lowest Python
# version we still support (3.7).
"pystac>=1.5.0",
"requests>=2.26.0",
"shapely>=1.6.4",
"urllib3>=1.9.0",
"xarray>=0.12.3,<2025.01.2", # TODO #721 xarray non-nanosecond support
]

[project.optional-dependencies]
artifacts = [
"boto3",
"botocore",
]
dev = [
"boto3",
"boto3~=1.37.38; python_version<'3.9'",
"botocore",
"botocore~=1.37.38; python_version<'3.9'",
"dirty_equals>=0.8.0",
"flake8>=5.0.0",
"httpretty>=1.1.4",
"mock",
"moto>=5.0.0",
"moto~=5.0.28; python_version<'3.9'",
"myst-parser",
"netCDF4>=1.7.0",
"pyarrow>=10.0.1",
"pydata_sphinx_theme",
"pyproj>=3.2.0", # Pyproj is an optional, best-effort runtime dependency
"pystac-client>=0.7.5",
"pytest>=4.5.0",
"python-dateutil>=2.7.0",
"requests-mock>=1.8.0",
"sphinx",
"sphinx-autodoc-annotation",
"sphinx-autodoc-typehints >=2.2.3; python_version>='3.10'",
"sphinx-autodoc-typehints; python_version<='3.9'",
"sphinx-copybutton",
"time_machine>=2.13.0",
"types-boto3-s3",
"types-boto3-sts",
"urllib3<2.3.0",
]
docs = [
"myst-parser",
"pydata_sphinx_theme",
"sphinx",
"sphinx-autodoc-annotation",
"sphinx-autodoc-typehints >=2.2.3; python_version>='3.10'",
"sphinx-autodoc-typehints; python_version<='3.9'",
"sphinx-copybutton",
]
jupyter = [
"ipyleaflet>=0.17.0",
"ipython",
]
localprocessing = [
"openeo_pg_parser_networkx>=2023.5.1; python_version>='3.9'",
"openeo_processes_dask[implementations]>=2023.7.1; python_version>='3.9'",
"pyproj",
"rioxarray>=0.13.0",
]
# Install oschmod even when platform is not Windows, e.g. for testing in CI.
oschmod = [
"oschmod>=0.3.12",
]
tests = [
"boto3",
"boto3~=1.37.38; python_version<'3.9'",
"botocore",
"botocore~=1.37.38; python_version<'3.9'",
"dirty_equals>=0.8.0",
"flake8>=5.0.0",
"httpretty>=1.1.4",
"mock",
"moto>=5.0.0",
# Some pins to speed up slow dependency resolution in Python 3.8 venvs
"moto~=5.0.28; python_version<'3.9'",
"netCDF4>=1.7.0",
"pyarrow>=10.0.1", # For Parquet read/write support in pandas
"pyproj>=3.2.0",
"pystac-client>=0.7.5",
"pytest>=4.5.0",
"python-dateutil>=2.7.0",
"requests-mock>=1.8.0",
"time_machine>=2.13.0",
# httpretty doesn't work properly with urllib3>=2.3.0. See #700 and
# https://github.com/gabrielfalcao/HTTPretty/issues/484
"urllib3<2.3.0",
]

[project.scripts]
openeo-auth = "openeo.rest.auth.cli:main"

[project.urls]
"Bug Tracker" = "https://github.com/Open-EO/openeo-python-client/issues"
Changelog = "https://github.com/Open-EO/openeo-python-client/blob/master/CHANGELOG.md"
Documentation = "https://open-eo.github.io/openeo-python-client/"
Homepage = "https://github.com/Open-EO/openeo-python-client"
"Source Code" = "https://github.com/Open-EO/openeo-python-client"

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

[tool.setuptools.packages.find]
include = ["openeo"]

[tool.black]
line-length = 120
Expand Down
128 changes: 0 additions & 128 deletions setup.py

This file was deleted.

Loading