Skip to content

Commit 7fc30e1

Browse files
committed
ci: Cache Zenodo data, and retry on http 502, 503 errors
Also reduce max number of tries to avoid hammering Zenodo
1 parent d2f3f44 commit 7fc30e1

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

.github/workflows/tests.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,29 @@ jobs:
181181
python -m pip install --upgrade pip setuptools
182182
python -m pip install -r requirements.txt
183183
184+
- name: Cache Zenodo test data
185+
uses: actions/cache@v4
186+
with:
187+
path: ./zenodo_data
188+
# Data doesn't depend on matrix job, so this should cache between all jobs
189+
key: zenodo-data
190+
191+
- name: Download Zenodo test data
192+
run: |
193+
if [[ ! -e zenodo_data/grid.fci.nc ]]; then
194+
echo "Downloading Zenodo data"
195+
mkdir -p zenodo_data
196+
wget \
197+
https://zenodo.org/record/7614499/files/W7X-conf4-36x8x128.fci.nc?download=1 \
198+
-output-document=zenodo_data/grid.fci.nc \
199+
--retry-on-http-error=502,503 \
200+
--tries 3
201+
else
202+
echo "Using cached Zenodo data"
203+
fi
204+
mkdir -pv build/tests/integrated/test-fci-mpi
205+
cp -v zenodo_data/grid.fci.nc build/tests/integrated/test-fci-mpi
206+
184207
- name: Cache SUNDIALS build
185208
uses: actions/cache@v4
186209
with:

0 commit comments

Comments
 (0)