Skip to content

Commit

Permalink
Abandon ESMF-install action, use conda ESMF and remainder from PyPI, …
Browse files Browse the repository at this point in the history
…move nc-time-axis to docs-only deps
  • Loading branch information
Zeitsperre committed Oct 20, 2023
1 parent 24979f8 commit ec03ed5
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 28 deletions.
32 changes: 6 additions & 26 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
tox -e black
testing-pypi:
name: Test with Python${{ matrix.python-version }} (tox)
name: Test with Python${{ matrix.python-version }} (PyPI)
needs: black
runs-on: ubuntu-latest
env:
Expand All @@ -55,23 +55,7 @@ jobs:
shell: bash -l {0}
steps:
- uses: actions/checkout@v4
- name: Install NetCDF
run: |
sudo apt-get -y update
sudo apt install libnetcdf-dev libnetcdff-dev
- name: Cache ESMF
uses: actions/cache@v3
with:
path: $HOME/.esmf-cache
key: ubuntu-latest-esmf-${{ env.ESMF_VERSION }}
- name: Install ESMF
uses: esmf-org/install-esmf-action@v1
env:
ESMF_NETCDF: nc-config
with:
build-key: ubuntu-latest-esmf-${{ env.ESMF_VERSION }}
cache: true
version: ${{ env.ESMF_VERSION }}

- name: Set up Python${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
Expand Down Expand Up @@ -116,9 +100,9 @@ jobs:
needs: black
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version:
- "3.9"
defaults:
run:
shell: bash -l {0}
Expand All @@ -128,22 +112,18 @@ jobs:
uses: mamba-org/setup-micromamba@v1
with:
cache-downloads: true
environment-file: environment.yml
create-args: >-
coveralls
esmf
mamba
python=${{ matrix.python-version }}
pytest
pytest-cov
xdoctest
- name: Conda and Mamba versions
run: |
mamba --version
echo "micromamba $(micromamba --version)"
- name: Compile catalogs and install xscen
run: |
make translate
pip install --editable .
pip install --editable --no-deps .
- name: Check versions
run: |
conda list
Expand Down
3 changes: 2 additions & 1 deletion environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ dependencies:
- shapely >= 2
- sparse
- toolz
- xarray
# FIXME: Unpin xarray when xclim 0.46 is released
- xarray <2023.09.0
- xclim >=0.43.0
- xesmf >=0.7
- zarr
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ def run(self):
"h5py",
"intake-esm>=2023.07.07",
"matplotlib",
"nc-time-axis>=1.3.1",
"netCDF4",
"numpy",
"pandas>=2.0",
Expand All @@ -74,6 +73,7 @@ def run(self):
"ipython",
"jupyter_client",
"nbsphinx",
"nc-time-axis>=1.3.1",
"nbval",
"sphinx",
"sphinx-autoapi",
Expand Down

0 comments on commit ec03ed5

Please sign in to comment.