Skip to content

(fix): allow all extension array data types in pandas adapters #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
169 commits
Select commit Hold shift + click to select a range
c2bc4df
(fix): allow all extension array data types in pandas adapters
ilan-gold Oct 23, 2024
84569bc
(fix): dataframes have no `array` attr
ilan-gold Oct 23, 2024
90e390d
(fix): allow chunked numpy extension arrays because of `test_pandas_a…
ilan-gold Oct 24, 2024
7c32bd0
(fix): dtypes for `PandasIndex`
ilan-gold Oct 24, 2024
795ecf6
(chore): remove test for unnecessary conversion
ilan-gold Oct 24, 2024
8eca6e9
(revert): don't let through so much in `as_compatible_data`
ilan-gold Oct 24, 2024
fb91812
(fix): account for series -> numpy conversions
ilan-gold Oct 25, 2024
a06f2b1
(fix): ensure dtype check is for numpy type
ilan-gold Oct 25, 2024
14027e8
(fix): convert pandas `IntervalArray`
ilan-gold Oct 25, 2024
a47a96f
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Oct 25, 2024
ae49850
Merge branch 'any-time-resolution-2' into ig/fix_extension_indexer
ilan-gold Dec 10, 2024
e8f5aa8
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Dec 10, 2024
a405f03
Merge branch 'any-time-resolution-2' into ig/fix_extension_indexer
ilan-gold Dec 10, 2024
503b313
(fix): `dtype` type handling
ilan-gold Dec 11, 2024
c8ab8f3
(fix): move out of type checking block
ilan-gold Dec 11, 2024
66e5b06
(fix): satisfy mypy
ilan-gold Dec 11, 2024
f9fde3a
(fix): doctest
ilan-gold Dec 11, 2024
8a3e834
(fix): `nbytes` test?
ilan-gold Dec 11, 2024
80dc10b
Merge branch 'any-time-resolution-2' into ig/fix_extension_indexer
ilan-gold Jan 7, 2025
9d77885
Merge branch 'any-time-resolution-2' into ig/fix_extension_indexer
ilan-gold Jan 15, 2025
6bea715
Relax nanosecond datetime restriction in CF time decoding (#9618)
kmuehlbauer Jan 15, 2025
b120917
Merge branch 'any-time-resolution-2' into ig/fix_extension_indexer
ilan-gold Jan 15, 2025
f7cda22
merge
ilan-gold Jan 15, 2025
5761de6
fix upstream dev issues (#9953)
kmuehlbauer Jan 17, 2025
70997ef
Suggest the correct name when no key matches in the dataset (#9943)
Illviljan Jan 17, 2025
1126c9b
cast type to PDDatetimeUnitOptions (#9963)
kmuehlbauer Jan 20, 2025
4ccb048
Update time coding tests to assert exact equality (#9961)
spencerkclark Jan 22, 2025
f2e9f86
remove dask-expr from CI runs, fix related tests (#9971)
kmuehlbauer Jan 22, 2025
609412d
Use zarr-fixture to prevent thread leakage errors (#9967)
kmuehlbauer Jan 22, 2025
3ba4ce4
fix weighted polyfit for arrays with more than 2 dimensions (#9974)
malmans2 Jan 23, 2025
10b68c3
Fix test_doc_example on big-endian systems (#9949)
QuLogic Jan 23, 2025
1c7ee65
Remove unnecessary a article (#9980)
salahelfarissi Jan 23, 2025
4d70fd1
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Jan 27, 2025
d62b276
Fix some typing (#9988)
dcherian Jan 27, 2025
99dfffa
Bump the actions group with 2 updates (#9989)
dependabot[bot] Jan 27, 2025
a848044
Use flox for grouped first, last (#9986)
dcherian Jan 27, 2025
2870710
Add `shards` to `valid_encodings` to enable sharded Zarr writing (#9948)
jacobbieker Jan 27, 2025
84f2775
add shxarray to the xarray ecosystem list (#9995)
strawpants Jan 28, 2025
4e728b8
Remove repetitive that (replace it with the) (#9994)
salahelfarissi Jan 28, 2025
2bedca4
remove gate and add a test (#9958)
slevang Jan 28, 2025
e432479
Add `time_unit` argument to `CFTimeIndex.to_datetimeindex` (#9965)
spencerkclark Jan 29, 2025
e28f171
fix mean for datetime-like using the respective time resolution unit …
kmuehlbauer Jan 29, 2025
666d279
Merge branch 'main' into ig/fix_extension_indexer
kmuehlbauer Jan 29, 2025
d475036
Enable passing a `CFTimedeltaCoder` to `decode_timedelta` (#9966)
spencerkclark Jan 29, 2025
8ccf1cb
Revert "Use flox for grouped first, last (#9986)" (#10001)
dcherian Jan 29, 2025
018b241
Fix infer_freq, check for subdtype "datetime64"/"timedelta64" (#9999)
kmuehlbauer Jan 29, 2025
5fdceff
Migrate Zarr region="auto" tests to a class (#9990)
dcherian Jan 29, 2025
d7ac79a
Fix the push method when the limit parameter is bigger than the chunk…
josephnowak Jan 29, 2025
e84e421
Use freq='D' instead of freq='d' in pd.timedelta_range (#10004)
spencerkclark Jan 30, 2025
f91306a
cast `numpy` scalars to arrays in `NamedArray.from_array` (#10008)
keewis Jan 30, 2025
97a4a71
fix typing (#10006)
kmuehlbauer Jan 30, 2025
5b3f127
Preserve order of variables in combine_by_coords (#9070)
kmuehlbauer Jan 30, 2025
326dbe7
Add FAQ answer about API stability & backwards compatibility (#9855)
TomNicholas Jan 30, 2025
d8d1d9e
release notes: 2025.01.2 (#10007)
kmuehlbauer Jan 31, 2025
c252152
add new section in whats-new.rst (#10011)
kmuehlbauer Jan 31, 2025
3623dd5
(fix): try to address pandas comments
ilan-gold Jan 31, 2025
da0ee36
(fix): try-logic was not correct
ilan-gold Jan 31, 2025
b53ba64
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Jan 31, 2025
d924d93
Update pre-commit hooks (#10021)
pre-commit-ci[bot] Feb 3, 2025
2068b8c
(refactor): remove super class casting
ilan-gold Feb 4, 2025
13fc8fe
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Feb 4, 2025
067f8f2
(fix): namedarray mypy issues
ilan-gold Feb 4, 2025
459f56b
(fix): typing patch
ilan-gold Feb 4, 2025
0aa5862
(fix): revert dataarray dtype change
ilan-gold Feb 4, 2025
4a73535
(fix): just ignore dtype issue
ilan-gold Feb 4, 2025
9b4ce62
(fix): ignore redefinition issue
ilan-gold Feb 4, 2025
2658c00
spelling fix (#10023)
shoyer Feb 4, 2025
4b48cf7
Duck array ops for `all` and `any` (#9883)
tomwhite Feb 4, 2025
160cced
`map_over_datasets`: fix error message for wrong result type (#10016)
mathause Feb 5, 2025
03c1014
Use resolution-dependent default units for lazy time encoding (#10017)
spencerkclark Feb 5, 2025
d57f05c
DOC: Fix 404 (#10029)
VeckoTheGecko Feb 6, 2025
e1be388
(fix): remove erroneous generic hint
ilan-gold Feb 7, 2025
1fee9d4
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Feb 7, 2025
df2ecf4
use mean of min/max years as offset in calculation of datetime64 mean…
kmuehlbauer Feb 7, 2025
1a7650c
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Feb 7, 2025
54946eb
Fix dataarray drop attrs (#10030)
j-haacker Feb 9, 2025
1873874
Start splitting up `dataset.py` (#10039)
max-sixty Feb 10, 2025
c8f7dc6
Upgrade mypy to 1.15 (#10041)
max-sixty Feb 10, 2025
1189240
implement map_over_datasets kwargs (#10012)
kmuehlbauer Feb 10, 2025
414b6b2
run CI on `python=3.13` (#9681)
keewis Feb 12, 2025
3dafcf9
Add `Coordinates.from_xindex` method (+ refactor API doc) (#10000)
benbovy Feb 12, 2025
84e81bc
Add types stubs to optional dependencies (#10048)
max-sixty Feb 13, 2025
4bbab48
Flexible coordinate transform (#9543)
benbovy Feb 14, 2025
0caf096
More precisely type `pipe` methods (#10038)
chuckwondo Feb 19, 2025
62f3892
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Feb 21, 2025
cf0d0ea
Default to phony_dims="access" in h5netcdf-backend (#10058)
kmuehlbauer Feb 24, 2025
df33a9a
More permissive Index typing (#10067)
benbovy Feb 24, 2025
2475d49
Restrict fastpath isel indexes to the case of all PandasIndex (#10066)
benbovy Feb 24, 2025
36dcbb6
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Feb 24, 2025
5ea1e81
deprecate cftime_range() in favor of date_range(use_cftime=True) (#10…
Maddogghoek Feb 27, 2025
0184702
Generalize lazy backend indexing a little more (#10078)
dcherian Feb 28, 2025
282235f
Another reduction in the size of `dataset.py` (#10088)
max-sixty Mar 5, 2025
b22d24b
Prune data tree for Isomorphic operations (#10097)
kobebryant432 Mar 6, 2025
864b9c4
Skip failing array api test. (#10102)
dcherian Mar 7, 2025
c97399f
Pass node path to tokenize in `open_datatree` (#10100)
slevang Mar 7, 2025
d21eda2
Fix false timedelta decoding `SerializationWarning` and improve warni…
spencerkclark Mar 7, 2025
25bb865
Update pre-commit hooks (#10093)
pre-commit-ci[bot] Mar 7, 2025
2a8340d
Bump codecov/codecov-action from 5.3.1 to 5.4.0 in the actions group …
dependabot[bot] Mar 7, 2025
4d8bbee
Add typos check to pre-commit hooks (#10040)
max-sixty Mar 7, 2025
70d2f1d
Ensure KeyError raised for zarr datasets missing dim names (#10025)
oliverwm1 Mar 7, 2025
7a3a4c6
Improve handling of dtype and NaT when encoding/decoding masked and p…
kmuehlbauer Mar 7, 2025
4c2540d
fix and supress some test warnings (#10104)
mathause Mar 7, 2025
852ad11
Update asv badge url in README.md (#10113)
sjvrijn Mar 11, 2025
48be376
Fix broken Zarr test (#10109)
dcherian Mar 13, 2025
91e31b1
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Mar 13, 2025
4a41386
Pin pandas stubs (#10119)
jsignell Mar 13, 2025
1e1938f
Use `to_numpy` in time decoding (#10081)
dcherian Mar 13, 2025
bc33fda
explicitly cast the dtype of `where`'s condition parameter to `bool` …
keewis Mar 13, 2025
97f178a
Better `uv` compatibility (#10124)
max-sixty Mar 14, 2025
6c89f97
Change `python_files` in `pyproject.toml` to a list (#10127)
max-sixty Mar 14, 2025
702909d
Don't skip tests when on a `mypy` branch (#10129)
max-sixty Mar 14, 2025
5e0b2e7
Fix type issues from pandas stubs (#10128)
max-sixty Mar 14, 2025
b085d8b
Refactor compatibility modules into xarray.compat package (#10131)
max-sixty Mar 15, 2025
3c3e111
Refactor modules from `core` into `xarray.computation` (#10132)
max-sixty Mar 15, 2025
e4c1a04
Split `apply_ufunc` out of `computation.py` (#10133)
max-sixty Mar 15, 2025
8ba2707
Refactor concat / combine / merge into `xarray/structure` (#10134)
max-sixty Mar 15, 2025
bb539d8
Fix test_distributed::test_async (#10138)
fjetter Mar 17, 2025
e6eabca
Refactor datetime and timedelta encoding for increased robustness (#9…
spencerkclark Mar 18, 2025
380b6b1
[docs] `DataTree` cannot be constructed from `DataArray` (#10142)
mathause Mar 18, 2025
314cb26
Fix `open_datatree` when `decode_cf=False` (#10141)
ianhi Mar 18, 2025
b7ec48a
Fix version in requires_zarr_v3 fixture (#10145)
TomNicholas Mar 18, 2025
bd92782
Adds open_datatree and load_datatree to the tutorial module (#10082)
eni-awowale Mar 18, 2025
3ca8824
Update flaky pydap test (#10149)
dcherian Mar 19, 2025
2da7f55
Use flox for grouped first, last. (#10148)
dcherian Mar 19, 2025
45cc2ee
Refactor calendar fixtures (#10150)
dcherian Mar 20, 2025
f0809e4
Refactoring/fixing zarr-python v3 incompatibilities in xarray datatre…
aladinor Mar 20, 2025
8d14227
Release 2025.03.0 (#10143)
dcherian Mar 20, 2025
7a98ea8
Add dev whats-new (#10152)
dcherian Mar 20, 2025
1219109
Fix GitHub Actions badge in README (#10155)
spencerkclark Mar 20, 2025
b7c1c11
Forbid datatree to zarr append dim (#10156)
TomNicholas Mar 20, 2025
5809b2f
(fix): use `coord_type` check
ilan-gold Mar 21, 2025
a22ff34
(chore): clean up numpy dtype handling
ilan-gold Mar 21, 2025
d41e5ee
Merge branch 'ig/fix_extension_indexer' of github.com:ilan-gold/xarra…
ilan-gold Mar 21, 2025
ef54645
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Mar 21, 2025
5c64310
(chore): try casting earlier?
ilan-gold Mar 21, 2025
d9fc4ca
Update xarray/core/indexing.py
ilan-gold Mar 21, 2025
7169fb1
Update xarray/core/indexing.py
ilan-gold Mar 21, 2025
cdebbf5
Fix numpy advanced indexing docs link (#10160)
wpbonelli Mar 21, 2025
fd7c765
Update DataArray.to_zarr to match Dataset.to_zarr. (#10164)
Karl-Krauth Mar 24, 2025
4174aa1
Preserve label ordering for multi-variable GroupBy (#10151)
dcherian Mar 24, 2025
ab7164c
Move chunks-related functions to a new file (#10172)
max-sixty Mar 25, 2025
fe40be3
Move fit computation code to dedicated new file (#10174)
max-sixty Mar 25, 2025
ec88c28
Fix GroupBy first, last with flox (#10173)
dcherian Mar 26, 2025
7ffdcc7
Allow setting `fill_value` on Zarr format 3 arrays (#10161)
dcherian Mar 26, 2025
66f6c17
DataTree: sel & isel add error context (#10154)
mathause Mar 26, 2025
ea5c066
Merge branch 'main' into ig/fix_extension_indexer
ilan-gold Mar 27, 2025
fdfe15e
DOC: Update docstring to reflect renamed section (#10180)
VeckoTheGecko Mar 28, 2025
d008e33
Use explicit repo name in upstream wheels (#10181)
ianhi Mar 28, 2025
61d4e26
Fix: Correct axis labelling with units for FacetGrid plots (#10185)
andrewendlinger Mar 29, 2025
2e1a6ae
Small cleanup
dcherian Mar 29, 2025
4a5cf1d
Skip dask tests with pandas index
dcherian Mar 29, 2025
44a05a4
fix test, typing
dcherian Mar 29, 2025
6167eaa
Vendor pandas to xarray conversion tests (#10187)
dcherian Mar 29, 2025
983f5e0
Merge branch 'main' into ig/fix_extension_indexer
dcherian Mar 29, 2025
c25c824
fix
dcherian Mar 29, 2025
3eb3372
Add nbytes
dcherian Mar 29, 2025
fbae574
Update pandas_to_xarray tests
dcherian Mar 29, 2025
8eb0685
Revert nbytes
dcherian Mar 29, 2025
516aa68
One more fix.
dcherian Mar 29, 2025
f25637d
Support zarr `write_empty_chunks` for zarr-python 3 and up (#10177)
ianhi Mar 30, 2025
2aa2e73
release 2025.03.1 (#10188)
dcherian Mar 31, 2025
e8b1daf
Add new whats-new section (#10190)
dcherian Mar 31, 2025
52cafdb
Bump scientific-python/upload-nightly-action in the actions group (#1…
dependabot[bot] Mar 31, 2025
dd3dd51
Expose PandasExtensionArray
dcherian Mar 31, 2025
2e32b92
Merge branch 'main' into ig/fix_extension_indexer
dcherian Mar 31, 2025
6fbdf8b
Better comment
dcherian Mar 31, 2025
b9167b6
Fix tests
dcherian Apr 1, 2025
2f4bbba
fix groupby test
dcherian Apr 1, 2025
7888609
revert _maybe_wrap_data
dcherian Apr 1, 2025
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
12 changes: 6 additions & 6 deletions .github/workflows/ci-additional.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,14 +116,14 @@ jobs:
python xarray/util/print_versions.py
- name: Install mypy
run: |
python -m pip install "mypy==1.13" --force-reinstall
python -m pip install "mypy==1.15" --force-reinstall

- name: Run mypy
run: |
python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report

- name: Upload mypy coverage to Codecov
uses: codecov/codecov-action@v5.1.2
uses: codecov/codecov-action@v5.4.0
with:
file: mypy_report/cobertura.xml
flags: mypy
Expand Down Expand Up @@ -167,14 +167,14 @@ jobs:
python xarray/util/print_versions.py
- name: Install mypy
run: |
python -m pip install "mypy==1.13" --force-reinstall
python -m pip install "mypy==1.15" --force-reinstall

- name: Run mypy
run: |
python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report

- name: Upload mypy coverage to Codecov
uses: codecov/codecov-action@v5.1.2
uses: codecov/codecov-action@v5.4.0
with:
file: mypy_report/cobertura.xml
flags: mypy-min
Expand Down Expand Up @@ -230,7 +230,7 @@ jobs:
python -m pyright xarray/

- name: Upload pyright coverage to Codecov
uses: codecov/codecov-action@v5.1.2
uses: codecov/codecov-action@v5.4.0
with:
file: pyright_report/cobertura.xml
flags: pyright
Expand Down Expand Up @@ -286,7 +286,7 @@ jobs:
python -m pyright xarray/

- name: Upload pyright coverage to Codecov
uses: codecov/codecov-action@v5.1.2
uses: codecov/codecov-action@v5.4.0
with:
file: pyright_report/cobertura.xml
flags: pyright39
Expand Down
35 changes: 24 additions & 11 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
matrix:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
# Bookend python versions
python-version: ["3.10", "3.12"]
python-version: ["3.10", "3.13"]
env: [""]
include:
# Minimum python version:
Expand All @@ -59,14 +59,23 @@ jobs:
os: ubuntu-latest
# Latest python version:
- env: "all-but-numba"
python-version: "3.12"
python-version: "3.13"
os: ubuntu-latest
- env: "all-but-dask"
# Not 3.12 because of pint
python-version: "3.11"
python-version: "3.12"
os: ubuntu-latest
- env: "flaky"
python-version: "3.12"
python-version: "3.13"
os: ubuntu-latest
# The mypy tests must be executed using only 1 process in order to guarantee
# predictable mypy output messages for comparison to expectations.
- env: "mypy"
python-version: "3.10"
numprocesses: 1
os: ubuntu-latest
- env: "mypy"
python-version: "3.13"
numprocesses: 1
os: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -78,17 +87,21 @@ jobs:

if [[ ${{ matrix.os }} == windows* ]] ;
then
if [[ ${{ matrix.python-version }} != "3.13" ]]; then
if [[ ${{ matrix.python-version }} != "3.14" ]]; then
echo "CONDA_ENV_FILE=ci/requirements/environment-windows.yml" >> $GITHUB_ENV
else
echo "CONDA_ENV_FILE=ci/requirements/environment-windows-3.13.yml" >> $GITHUB_ENV
echo "CONDA_ENV_FILE=ci/requirements/environment-windows-3.14.yml" >> $GITHUB_ENV
fi
elif [[ "${{ matrix.env }}" != "" ]] ;
then
if [[ "${{ matrix.env }}" == "flaky" ]] ;
then
echo "CONDA_ENV_FILE=ci/requirements/environment.yml" >> $GITHUB_ENV
echo "PYTEST_ADDOPTS=-m 'flaky or network' --run-flaky --run-network-tests -W default" >> $GITHUB_ENV
elif [[ "${{ matrix.env }}" == "mypy" ]] ;
then
echo "CONDA_ENV_FILE=ci/requirements/environment.yml" >> $GITHUB_ENV
echo "PYTEST_ADDOPTS=-n 1 -m 'mypy' --run-mypy -W default" >> $GITHUB_ENV
else
echo "CONDA_ENV_FILE=ci/requirements/${{ matrix.env }}.yml" >> $GITHUB_ENV
fi
Expand All @@ -98,10 +111,10 @@ jobs:
echo "PYTEST_ADDOPTS=-W default" >> $GITHUB_ENV
fi
else
if [[ ${{ matrix.python-version }} != "3.13" ]]; then
if [[ ${{ matrix.python-version }} != "3.14" ]]; then
echo "CONDA_ENV_FILE=ci/requirements/environment.yml" >> $GITHUB_ENV
else
echo "CONDA_ENV_FILE=ci/requirements/environment-3.13.yml" >> $GITHUB_ENV
echo "CONDA_ENV_FILE=ci/requirements/environment-3.14.yml" >> $GITHUB_ENV
fi
fi

Expand Down Expand Up @@ -145,7 +158,7 @@ jobs:
save-always: true

- name: Run tests
run: python -m pytest -n 4
run: python -m pytest -n ${{ matrix.numprocesses || 4 }}
--timeout 180
--cov=xarray
--cov-report=xml
Expand All @@ -159,7 +172,7 @@ jobs:
path: pytest.xml

- name: Upload code coverage to Codecov
uses: codecov/codecov-action@v5.1.2
uses: codecov/codecov-action@v5.4.0
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
fi

- name: Upload wheel
uses: scientific-python/upload-nightly-action@82396a2ed4269ba06c6b2988bb4fd568ef3c3d6b # 0.6.1
uses: scientific-python/upload-nightly-action@b36e8c0c10dbcfd2e05bf95f17ef8c14fd708dbf # 0.6.2
with:
anaconda_nightly_upload_token: ${{ secrets.ANACONDA_NIGHTLY }}
artifacts_path: dist
4 changes: 2 additions & 2 deletions .github/workflows/pypi-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ jobs:
path: dist
- name: Publish package to TestPyPI
if: github.event_name == 'push'
uses: pypa/[email protected].3
uses: pypa/[email protected].4
with:
repository_url: https://test.pypi.org/legacy/
verbose: true
Expand All @@ -110,6 +110,6 @@ jobs:
name: releases
path: dist
- name: Publish package to PyPI
uses: pypa/[email protected].3
uses: pypa/[email protected].4
with:
verbose: true
4 changes: 2 additions & 2 deletions .github/workflows/upstream-dev-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
if: success()
id: status
run: |
python -m pytest --timeout=60 -rf \
python -m pytest --timeout=60 -rf -nauto \
--report-log output-${{ matrix.python-version }}-log.jsonl
- name: Generate and publish the report
if: |
Expand Down Expand Up @@ -140,7 +140,7 @@ jobs:
run: |
python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
- name: Upload mypy coverage to Codecov
uses: codecov/codecov-action@v5.1.2
uses: codecov/codecov-action@v5.4.0
with:
file: mypy_report/cobertura.xml
flags: mypy
Expand Down
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -81,3 +81,8 @@ doc/team-panel.txt
doc/external-examples-gallery.txt
doc/notebooks-examples-gallery.txt
doc/videos-gallery.txt

# Until we support this properly, excluding from gitignore. (adding it to
# gitignore to make it _easier_ to work with `uv`, not as an indication that I
# think we shouldn't...)
uv.lock
12 changes: 9 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ repos:
- id: text-unicode-replacement-char
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.8.6
rev: v0.9.9
hooks:
- id: ruff-format
- id: ruff
Expand All @@ -37,12 +37,12 @@ repos:
exclude: "generate_aggregations.py"
additional_dependencies: ["black==24.8.0"]
- repo: https://github.com/rbubley/mirrors-prettier
rev: v3.4.2
rev: v3.5.3
hooks:
- id: prettier
args: [--cache-location=.prettier_cache/cache]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.14.1
rev: v1.15.0
hooks:
- id: mypy
# Copied from setup.cfg
Expand Down Expand Up @@ -73,3 +73,9 @@ repos:
hooks:
- id: validate-pyproject
additional_dependencies: ["validate-pyproject-schema-store[all]"]
- repo: https://github.com/crate-ci/typos
rev: dictgen-v0.3.1
hooks:
- id: typos
# https://github.com/crate-ci/typos/issues/347
pass_filenames: false
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# xarray: N-D labeled arrays and datasets

[![CI](https://github.com/pydata/xarray/workflows/CI/badge.svg?branch=main)](https://github.com/pydata/xarray/actions?query=workflow%3ACI)
[![CI](https://github.com/pydata/xarray/actions/workflows/ci.yaml/badge.svg?branch=main)](https://github.com/pydata/xarray/actions/workflows/ci.yaml?query=branch%3Amain)
[![Code coverage](https://codecov.io/gh/pydata/xarray/branch/main/graph/badge.svg?flag=unittests)](https://codecov.io/gh/pydata/xarray)
[![Docs](https://readthedocs.org/projects/xray/badge/?version=latest)](https://docs.xarray.dev/)
[![Benchmarked with asv](https://img.shields.io/badge/benchmarked%20by-asv-green.svg?style=flat)](https://pandas.pydata.org/speed/xarray/)
[![Benchmarked with asv](https://img.shields.io/badge/benchmarked%20by-asv-green.svg?style=flat)](https://asv-runner.github.io/asv-collection/xarray/)
[![Formatted with black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/python/black)
[![Checked with mypy](http://www.mypy-lang.org/static/mypy_badge.svg)](http://mypy-lang.org/)
[![Available on pypi](https://img.shields.io/pypi/v/xarray.svg)](https://pypi.python.org/pypi/xarray/)
Expand Down
2 changes: 1 addition & 1 deletion ci/install-upstream-wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ python -m pip install \
git+https://github.com/dask/dask \
git+https://github.com/dask/dask-expr \
git+https://github.com/dask/distributed \
git+https://github.com/zarr-developers/zarr \
git+https://github.com/zarr-developers/zarr-python \
git+https://github.com/Unidata/cftime \
git+https://github.com/pypa/packaging \
git+https://github.com/hgrecco/pint \
Expand Down
3 changes: 2 additions & 1 deletion ci/minimum_versions.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,9 @@
"pytest",
"pytest-cov",
"pytest-env",
"pytest-xdist",
"pytest-mypy-plugins",
"pytest-timeout",
"pytest-xdist",
"hypothesis",
]

Expand Down
3 changes: 2 additions & 1 deletion ci/requirements/all-but-dask.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,9 @@ dependencies:
- pytest
- pytest-cov
- pytest-env
- pytest-xdist
- pytest-mypy-plugins
- pytest-timeout
- pytest-xdist
- rasterio
- scipy
- seaborn
Expand Down
4 changes: 2 additions & 2 deletions ci/requirements/all-but-numba.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ dependencies:
- cartopy
- cftime
- dask-core
- dask-expr # dask raises a deprecation warning without this, breaking doctests
- distributed
- flox
- fsspec
Expand Down Expand Up @@ -44,8 +43,9 @@ dependencies:
- pytest
- pytest-cov
- pytest-env
- pytest-xdist
- pytest-mypy-plugins
- pytest-timeout
- pytest-xdist
- rasterio
- scipy
- seaborn
Expand Down
3 changes: 2 additions & 1 deletion ci/requirements/bare-minimum.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ dependencies:
- pytest
- pytest-cov
- pytest-env
- pytest-xdist
- pytest-mypy-plugins
- pytest-timeout
- pytest-xdist
- numpy=1.24
- packaging=23.1
- pandas=2.1
1 change: 0 additions & 1 deletion ci/requirements/doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ dependencies:
- cfgrib
- kerchunk
- dask-core>=2022.1
- dask-expr
- hypothesis>=6.75.8
- h5netcdf>=0.13
- ipykernel
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ dependencies:
- cartopy
- cftime
- dask-core
- dask-expr
- distributed
- flox
- fsspec
Expand All @@ -30,22 +29,35 @@ dependencies:
- opt_einsum
- packaging
- pandas
- pandas-stubs<=2.2.3.241126 # https://github.com/pydata/xarray/issues/10110
# - pint>=0.22
- pip
- pooch
- pre-commit
- pyarrow # pandas raises a deprecation warning without this, breaking doctests
- pydap
- pytest
- pytest-cov
- pytest-env
- pytest-xdist
- pytest-mypy-plugins
- pytest-timeout
- pytest-xdist
- rasterio
- scipy
- seaborn
# - sparse
- toolz
- types-colorama
- types-docutils
- types-psutil
- types-Pygments
- types-python-dateutil
- types-pytz
- types-PyYAML
- types-setuptools
- typing_extensions
- zarr
- pip:
- jax # no way to get cpu-only jaxlib from conda if gpu is present
- types-defusedxml
- types-pexpect
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ dependencies:
- cartopy
- cftime
- dask-core
- dask-expr
- distributed
- flox
- fsspec
Expand All @@ -26,19 +25,33 @@ dependencies:
- numpy
- packaging
- pandas
- pandas-stubs<=2.2.3.241126 # https://github.com/pydata/xarray/issues/10110
# - pint>=0.22
- pip
- pre-commit
- pyarrow # importing dask.dataframe raises an ImportError without this
- pydap
- pytest
- pytest-cov
- pytest-env
- pytest-xdist
- pytest-mypy-plugins
- pytest-timeout
- pytest-xdist
- rasterio
- scipy
- seaborn
# - sparse
- toolz
- types-colorama
- types-docutils
- types-psutil
- types-Pygments
- types-python-dateutil
- types-pytz
- types-PyYAML
- types-setuptools
- typing_extensions
- zarr
- pip:
- types-defusedxml
- types-pexpect
Loading