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
28 changes: 14 additions & 14 deletions .github/workflows/ci-additional.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
run:
shell: bash -l {0}
env:
PIXI_ENV: test
PIXI_ENV: "test-py313"
steps:
- uses: actions/checkout@v6
with:
Expand All @@ -75,7 +75,7 @@ jobs:

- name: Version info
run: |
pixi run -e ${{env.PIXI_ENV}} python xarray/util/print_versions.py
pixi run -e ${{env.PIXI_ENV}} -- python xarray/util/print_versions.py
- name: Run doctests
run: |
# Raise an error if there are warnings in the doctests, with `-Werror`.
Expand All @@ -84,7 +84,7 @@ jobs:
#
# If dependencies emit warnings we can't do anything about, add ignores to
# `xarray/tests/__init__.py`.
pixi run -e ${{env.PIXI_ENV}} python -m pytest --doctest-modules xarray --ignore xarray/tests -Werror
pixi run -e ${{env.PIXI_ENV}} -- python -m pytest --doctest-modules xarray --ignore xarray/tests -Werror

mypy:
name: Mypy
Expand All @@ -94,7 +94,7 @@ jobs:
run:
shell: bash -l {0}
env:
PIXI_ENV: test-with-typing
PIXI_ENV: test-py313-with-typing

steps:
- uses: actions/checkout@v6
Expand All @@ -117,14 +117,14 @@ jobs:
- name: set environment variables
run: |
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{env.PIXI_ENV}} python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{env.PIXI_ENV}} -- python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
- name: Version info
run: |
pixi run -e ${{env.PIXI_ENV}} python xarray/util/print_versions.py
pixi run -e ${{env.PIXI_ENV}} -- python xarray/util/print_versions.py

- name: Run mypy
run: |
pixi run -e ${{env.PIXI_ENV}} python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
pixi run -e ${{env.PIXI_ENV}} -- python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report

- name: Upload mypy coverage to Codecov
uses: codecov/codecov-action@v5.5.1
Expand Down Expand Up @@ -166,14 +166,14 @@ jobs:
- name: set environment variables
run: |
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{env.PIXI_ENV}} python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{env.PIXI_ENV}} -- python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
- name: Version info
run: |
pixi run -e ${{env.PIXI_ENV}} python xarray/util/print_versions.py
pixi run -e ${{env.PIXI_ENV}} -- python xarray/util/print_versions.py

- name: Run mypy
run: |
pixi run -e ${{env.PIXI_ENV}} python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
pixi run -e ${{env.PIXI_ENV}} -- python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report

- name: Upload mypy coverage to Codecov
uses: codecov/codecov-action@v5.5.1
Expand All @@ -191,7 +191,7 @@ jobs:
strategy:
fail-fast: false
matrix:
pixi-env: ["test-with-typing", "test-py311-with-typing"]
pixi-env: ["test-py313-with-typing", "test-py311-with-typing"]
if: |
always()
&& (
Expand Down Expand Up @@ -223,14 +223,14 @@ jobs:
- name: set environment variables
run: |
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{ matrix.pixi-env }} python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{ matrix.pixi-env }} -- python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
- name: Version info
run: |
pixi run -e ${{ matrix.pixi-env }} python xarray/util/print_versions.py
pixi run -e ${{ matrix.pixi-env }} -- python xarray/util/print_versions.py

- name: Run pyright
run: |
pixi run -e ${{ matrix.pixi-env }} python -m pyright xarray/
pixi run -e ${{ matrix.pixi-env }} -- python -m pyright xarray/

- name: Upload pyright coverage to Codecov
uses: codecov/codecov-action@v5.5.1
Expand Down
34 changes: 17 additions & 17 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,22 +52,22 @@ jobs:
matrix:
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
# Bookend python versions
pixi-env: ["test-py311", "test"]
pixi-env: ["test-py311", "test-py313"]
pytest-addopts: [""]
include:
# Minimum python version:
- pixi-env: "test-bare-minimum"
- pixi-env: "test-py311-bare-minimum"
os: ubuntu-latest
- pixi-env: "test-bare-min-and-scipy"
- pixi-env: "test-py311-bare-min-and-scipy"
os: ubuntu-latest
- pixi-env: "test-min-versions"
- pixi-env: "test-py311-min-versions"
os: ubuntu-latest
# Latest python version:
- pixi-env: "test-no-numba"
- pixi-env: "test-py313-no-numba"
os: ubuntu-latest
- pixi-env: "test-no-dask"
- pixi-env: "test-py313-no-dask"
os: ubuntu-latest
- pixi-env: "test"
- pixi-env: "test-py313"
pytest-addopts: "flaky"
os: ubuntu-latest
# The mypy tests must be executed using only 1 process in order to guarantee
Expand All @@ -76,7 +76,7 @@ jobs:
pytest-addopts: "mypy"
numprocesses: 1
os: ubuntu-latest
- pixi-env: "test-with-typing"
- pixi-env: "test-py313-with-typing"
numprocesses: 1
os: ubuntu-latest
steps:
Expand All @@ -101,7 +101,7 @@ jobs:
- name: Set environment variables
run: |
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{env.PIXI_ENV}} python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{ matrix.pixi-env }} -- python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV

if [[ "${{ matrix.pytest-addopts }}" != "" ]] ;
then
Expand All @@ -128,11 +128,11 @@ jobs:

- name: Version info
run: |
pixi run -e ${{ matrix.pixi-env }} python xarray/util/print_versions.py
pixi run -e ${{ matrix.pixi-env }} -- python xarray/util/print_versions.py

- name: Import xarray
run: |
pixi run -e ${{ matrix.pixi-env }} python -c "import xarray"
pixi run -e ${{ matrix.pixi-env }} -- python -c "import xarray"

- name: Restore cached hypothesis directory
uses: actions/cache@v4
Expand All @@ -143,12 +143,12 @@ jobs:
save-always: true

- name: Run tests
run:
pixi run -e ${{ matrix.pixi-env }} python -m pytest -n ${{ matrix.numprocesses || 4 }}
--timeout 180
--cov=xarray
--cov-report=xml
--junitxml=pytest.xml
run: |
pixi run -e ${{ matrix.pixi-env }} -- python -m pytest -n ${{ matrix.numprocesses || 4 }} \
--timeout 180 \
--cov=xarray \
--cov-report=xml \
--junitxml=pytest.xml

- name: Upload test results
if: always()
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/hypothesis.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
shell: bash -l {0}

env:
PIXI_ENV: test
PIXI_ENV: "test-py313"

steps:
- uses: actions/checkout@v6
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/upstream-dev-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,15 @@ jobs:
cache-write: ${{ github.event_name == 'push' && github.ref_name == 'main' }}
- name: Version info
run: |
pixi run -e ${{matrix.pixi-env}} python xarray/util/print_versions.py
pixi run -e ${{matrix.pixi-env}} -- python xarray/util/print_versions.py
- name: Import xarray
run: |
pixi run -e ${{matrix.pixi-env}} python -c 'import xarray'
pixi run -e ${{matrix.pixi-env}} -- python -c 'import xarray'
- name: Run Tests
if: success()
id: status
run: |
pixi run -e ${{matrix.pixi-env}} python -m pytest --timeout=60 -rf -nauto \
pixi run -e ${{matrix.pixi-env}} -- python -m pytest --timeout=60 -rf -nauto \
--report-log output-${{ matrix.pixi-env }}-log.jsonl
- name: Generate and publish the report
if: |
Expand Down Expand Up @@ -138,13 +138,13 @@ jobs:
- name: set environment variables
run: |
echo "TODAY=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{matrix.pixi-env}} python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
echo "PYTHON_VERSION=$(pixi run -e ${{matrix.pixi-env}} -- python --version | cut -d' ' -f2 | cut -d. -f1,2)" >> $GITHUB_ENV
- name: Version info
run: |
pixi run -e ${{matrix.pixi-env}} python xarray/util/print_versions.py
pixi run -e ${{matrix.pixi-env}} -- python xarray/util/print_versions.py
- name: Run mypy
run: |
pixi run -e ${{matrix.pixi-env}} python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
pixi run -e ${{matrix.pixi-env}} -- python -m mypy --install-types --non-interactive --cobertura-xml-report mypy_report
- name: Upload mypy coverage to Codecov
uses: codecov/codecov-action@v5.5.1
with:
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ repos:
- id: blackdoc
exclude: "generate_aggregations.py"
# make sure this is the most recent version of black
additional_dependencies: ["black==25.9.0"]
additional_dependencies: ["black==25.11.0"]
- repo: https://github.com/rbubley/mirrors-prettier
rev: v3.7.3
hooks:
Expand Down
Loading
Loading