Skip to content
Merged
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Convert setup.py to pyproject.toml ([#920](https://github.com/Open-EO/openeo-python-client/issues/920))
- Make `_DerivedFrom._from_url` more resilient against unresolvable/unparsable `derived_from` links ([#928](https://github.com/Open-EO/openeo-python-client/issues/928), eu-cdse/openeo-cdse-infra#1338)
- `download_url()`: favor explicit HEAD status check over unhelpful auto-check ([#939](https://github.com/Open-EO/openeo-python-client/issues/939))
- Modernize Xarray version support: remove `<2025.0.2` upper limit but require at least `2024.07.0` ([#721](https://github.com/Open-EO/openeo-python-client/issues/721))

### Removed

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ dependencies = [
"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
"xarray>=2024.7.0",
]

[project.optional-dependencies]
Expand Down
4 changes: 0 additions & 4 deletions tests/testing/test_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -374,10 +374,6 @@ def test_assert_xarray_dataset_allclose_tolerance(self, kwargs, assertion_error)
with raises_assertion_error_or_not(message=assertion_error):
assert_xarray_dataset_allclose(actual=actual, expected=expected, **kwargs)

@pytest.mark.skipif(
ComparableVersion(xarray.__version__) < "2024.07.0" and ComparableVersion(numpy.__version__) >= "2.0.0",
reason="This test doesn't work due to numpy 2 compatibility issue in xarray below 2024.7.0",
)
def test_assert_xarray_dataset_allclose_empty_coords_handling(self):
expected = xarray.Dataset(
{
Expand Down
3 changes: 3 additions & 0 deletions tests/udf/test_xarraydatacube.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@ def _build_xdc(
"""
Build multi-dimensional XarrayDataCube containing given dimensions/coordinates
"""
if isinstance(ts, list) and all(isinstance(t, numpy.datetime64) for t in ts):
# Normalize to "ns" resolution (best compatibility with defaults across old/new versions of xarray/netCDF)
ts = [numpy.datetime64(t, "ns") for t in ts]
dims = []
coords = {}
value = numpy.zeros(shape=())
Expand Down
Loading