Skip to content

Full Archive CI

Full Archive CI #187

name: Full Archive CI
on:
workflow_dispatch: # enable a manual trigger
inputs:
name:
description: 'Testing a manual trigger'
schedule:
- cron: "0 13 * * 1" # run every monday
jobs:
cloud-tests:
name: cloud-tests (${{ matrix.catalog}} catalog) | ${{ matrix.variable_id }} | ${{ matrix.experiment_id }} | ${{ matrix.grid_label }}
strategy:
fail-fast: false
matrix:
variable_id: ['zos','so', 'thetao', 'uo','o2']
experiment_id: ['historical','piControl', 'esm-hist', 'esm-piControl',
'ssp245', 'ssp370','ssp585', 'ssp119']
grid_label: ['gn', 'gr']
catalog: ['main']
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Cache conda
uses: actions/cache@v4
env:
# Increase this value to reset cache if ci/environment-upstream-dev.yml has not changed
CACHE_NUMBER: 0
with:
path: ~/conda_pkgs_dir
key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('ci/environment-upstream-dev.yml') }}
- uses: conda-incubator/setup-miniconda@v3.0.3
with:
channels: conda-forge
mamba-version: '*'
channel-priority: strict
activate-environment: test_env_xmip # Defined in ci/environment-upstream-dev.yml
auto-update-conda: false
python-version: 3.8
environment-file: ci/environment-cloud-test.yml
use-only-tar-bz2: true # IMPORTANT: This needs to be set for caching to work properly!
- name: Set up conda environment
shell: bash -l {0}
run: python -m pip install -e . --no-deps --force-reinstall
- name: Conda List
shell: bash -l {0}
run: conda list
- name: Check Machine Config
shell: bash -l {0}
run: lscpu
- name: Run Tests
shell: bash -l {0}
run: |
pwd
echo $PYTHONPATH
pytest --reruns 1 --reruns-delay 10 --maxfail 20 tests/test_preprocessing_cloud.py --gl ${{ matrix.grid_label }} --ei ${{ matrix.experiment_id }} --vi ${{ matrix.variable_id }} --cat ${{ matrix.catalog }}