Skip to content
forked from pydata/xarray

Commit

Permalink
migrate the other CI to python 3.11 (pydata#8416)
Browse files Browse the repository at this point in the history
* migrate the additional CI to py311

* migrate the upstream-dev CI to python 3.11

* switch to the default environment file

* convert a left-over use of `provision-with-micromamba`

* silence the `cgi` deprecation warning from `pydap`

---------

Co-authored-by: Deepak Cherian <[email protected]>
  • Loading branch information
keewis and dcherian authored Nov 17, 2023
1 parent 74901af commit b6eaf43
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci-additional.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:

env:
CONDA_ENV_FILE: ci/requirements/environment.yml
PYTHON_VERSION: "3.10"
PYTHON_VERSION: "3.11"

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -87,7 +87,7 @@ jobs:
shell: bash -l {0}
env:
CONDA_ENV_FILE: ci/requirements/environment.yml
PYTHON_VERSION: "3.10"
PYTHON_VERSION: "3.11"

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -332,7 +332,7 @@ jobs:
with:
environment-name: xarray-tests
create-args: >-
python=3.10
python=3.11
pyyaml
conda
python-dateutil
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/upstream-dev-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.10"]
python-version: ["3.11"]
steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -110,17 +110,17 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.10"]
python-version: ["3.11"]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for all branches and tags.
- name: Set up conda environment
uses: mamba-org/provision-with-micromamba@v15
uses: mamba-org/setup-micromamba@v1
with:
environment-file: ci/requirements/environment.yml
environment-name: xarray-tests
extra-specs: |
create-args: >-
python=${{ matrix.python-version }}
pytest-reportlog
conda
Expand Down
9 changes: 8 additions & 1 deletion xarray/tests/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,14 @@ def _importorskip(

has_matplotlib, requires_matplotlib = _importorskip("matplotlib")
has_scipy, requires_scipy = _importorskip("scipy")
has_pydap, requires_pydap = _importorskip("pydap.client")
with warnings.catch_warnings():
warnings.filterwarnings(
"ignore",
message="'cgi' is deprecated and slated for removal in Python 3.13",
category=DeprecationWarning,
)

has_pydap, requires_pydap = _importorskip("pydap.client")
has_netCDF4, requires_netCDF4 = _importorskip("netCDF4")
has_h5netcdf, requires_h5netcdf = _importorskip("h5netcdf")
has_pynio, requires_pynio = _importorskip("Nio")
Expand Down

0 comments on commit b6eaf43

Please sign in to comment.