From ee28dbf2aa039081cbb1a40d231c292548b55b31 Mon Sep 17 00:00:00 2001 From: Oliver Watt-Meyer Date: Mon, 20 Jan 2025 11:57:40 -0800 Subject: [PATCH] Skip new xarray with python==3.9 --- .github/workflows/pytest.yaml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml index f2e4f0f..1ae0fcd 100644 --- a/.github/workflows/pytest.yaml +++ b/.github/workflows/pytest.yaml @@ -20,8 +20,16 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install pytest tox + pip install tox pip install -e . - name: Test with tox run: | - tox -p \ No newline at end of file + PYTHON_VERSION=$(python --version | cut -d' ' -f2) + + if [[ "$PYTHON_VERSION" == "3.9"* ]]; then + echo "Detected Python version: $PYTHON_VERSION" + echo "Skipping tests with xarray versions that require newer python" + tox -p --skip-env xarray202501 + else + tox -p + fi \ No newline at end of file