Skip to content

Commit cc8be10

Browse files
committed
Revert "Debug benchmarks."
This reverts commit ff0e7ff.
1 parent 8751670 commit cc8be10

File tree

7 files changed

+784
-436
lines changed

7 files changed

+784
-436
lines changed

.github/workflows/ci-citation.yml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: ci-citation
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- "CITATION.cff"
7+
8+
push:
9+
paths:
10+
- "CITATION.cff"
11+
12+
workflow_dispatch:
13+
14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.ref }}
16+
cancel-in-progress: true
17+
18+
permissions:
19+
contents: read
20+
21+
jobs:
22+
validate:
23+
name: "validate"
24+
runs-on: ubuntu-latest
25+
steps:
26+
- uses: actions/checkout@v4
27+
with:
28+
fetch-depth: 0
29+
30+
- name: "check CITATION.cff"
31+
uses: citation-file-format/cffconvert-github-action@2.0.0
32+
with:
33+
args: "--validate"

.github/workflows/ci-manifest.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: ci-manifest
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- "*"
7+
8+
push:
9+
branches-ignore:
10+
- "auto-update-lockfiles"
11+
- "pre-commit-ci-update-config"
12+
- "dependabot/*"
13+
14+
workflow_dispatch:
15+
16+
concurrency:
17+
group: ${{ github.workflow }}-${{ github.ref }}
18+
cancel-in-progress: true
19+
20+
jobs:
21+
manifest:
22+
name: "check-manifest"
23+
uses: scitools/workflows/.github/workflows/ci-manifest.yml@2025.04.3
+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Checks if a PR makes any changes that ought to be shared via templating.
2+
# See the called workflow in the scitools/workflows repo for more details.
3+
4+
name: ci-template-check
5+
6+
on:
7+
pull_request_target:
8+
branches:
9+
- main
10+
11+
jobs:
12+
prompt-share:
13+
uses: scitools/workflows/.github/workflows/ci-template-check.yml@2025.04.3
14+
secrets: inherit
15+
with:
16+
pr_number: ${{ github.event.pull_request.number }}

.github/workflows/ci-tests.yml

+105
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
# reference:
2+
# - https://github.com/actions/cache
3+
# - https://github.com/actions/checkout
4+
5+
name: ci-tests
6+
7+
on:
8+
pull_request:
9+
10+
push:
11+
branches:
12+
- "main"
13+
- "v*x"
14+
- "!auto-update-lockfiles"
15+
- "!pre-commit-ci-update-config"
16+
- "!dependabot/*"
17+
tags:
18+
- "v*"
19+
20+
workflow_dispatch:
21+
22+
concurrency:
23+
group: ${{ github.workflow }}-${{ github.ref }}
24+
cancel-in-progress: true
25+
26+
jobs:
27+
tests:
28+
name: "${{ matrix.session }} (py${{ matrix.python-version }} ${{ matrix.os }})"
29+
30+
runs-on: ${{ matrix.os }}
31+
32+
defaults:
33+
run:
34+
shell: bash -l {0}
35+
36+
env:
37+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
38+
#: If you change the IRIS_SOURCE here you will also need to change it in
39+
#: the noxfile and the benchmark and wheel workflows.
40+
IRIS_SOURCE: "github:main"
41+
IRIS_TEST_DATA_LOC_PATH: tests
42+
IRIS_TEST_DATA_PATH: tests/iris-test-data
43+
IRIS_TEST_DATA_VERSION: "2.19"
44+
ENV_CACHE_BUILD: "0"
45+
TEST_DATA_CACHE_BUILD: "0"
46+
47+
strategy:
48+
fail-fast: false
49+
matrix:
50+
os: ["ubuntu-latest"]
51+
python-version: ["3.11", "3.12", "3.13"]
52+
include:
53+
- python-version: "3.11"
54+
coverage: true
55+
56+
steps:
57+
- name: "checkout"
58+
uses: actions/checkout@v4
59+
60+
- name: Install Nox
61+
run: |
62+
pip install nox
63+
64+
- name: Cache environment directories
65+
id: cache-env-dir
66+
uses: actions/cache@v4
67+
with:
68+
path: |
69+
.nox
70+
$CONDA/pkgs
71+
key: ${{ runner.os }}-${{ hashFiles('requirements/locks/') }}-${{ env.ENV_CACHE_BUILD }}-${{ env.IRIS_SOURCE }}-${{ matrix.python-version }}
72+
73+
- name: Cache test data directory
74+
id: cache-test-data
75+
uses: actions/cache@v4
76+
with:
77+
path: |
78+
${{ env.IRIS_TEST_DATA_PATH }}
79+
key:
80+
test-data-${{ env.IRIS_TEST_DATA_VERSION }}-${{ env.TEST_DATA_CACHE_BUILD }}
81+
82+
- name: Fetch the test data
83+
if: steps.cache-test-data.outputs.cache-hit != 'true'
84+
run: |
85+
wget --quiet https://github.com/SciTools/iris-test-data/archive/v${IRIS_TEST_DATA_VERSION}.zip -O iris-test-data.zip
86+
unzip -q iris-test-data.zip
87+
mkdir --parents ${{ github.workspace }}/${IRIS_TEST_DATA_LOC_PATH}
88+
mv iris-test-data-${IRIS_TEST_DATA_VERSION} ${IRIS_TEST_DATA_PATH}
89+
90+
- name: Set test data var
91+
run: |
92+
echo "OVERRIDE_TEST_DATA_REPOSITORY=${{ github.workspace }}/${IRIS_TEST_DATA_PATH}/test_data" >> $GITHUB_ENV
93+
94+
- name: "tests (py${{ matrix.python-version }})"
95+
env:
96+
PY_VER: ${{ matrix.python-version }}
97+
COVERAGE: ${{ matrix.coverage }}
98+
run: |
99+
nox --session tests -- --verbose
100+
101+
- name: Upload coverage report
102+
uses: codecov/codecov-action@v5
103+
if: ${{ matrix.coverage }}
104+
with:
105+
token: ${{ secrets.CODECOV_TOKEN }}

.github/workflows/ci-wheels.yml

+158
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,158 @@
1+
# reference:
2+
# - https://github.com/actions/cache
3+
# - https://github.com/actions/checkout
4+
5+
name: ci-wheels
6+
7+
on:
8+
pull_request:
9+
10+
push:
11+
branches:
12+
- "main"
13+
- "v*x"
14+
- "!conda-lock-auto-update"
15+
- "!pre-commit-ci-update-config"
16+
- "!dependabot/*"
17+
tags:
18+
- "v*"
19+
20+
workflow_dispatch:
21+
22+
concurrency:
23+
group: ${{ github.workflow }}-${{ github.ref }}
24+
cancel-in-progress: true
25+
26+
jobs:
27+
build-artifacts:
28+
name: "build pypi artifacts"
29+
30+
runs-on: ubuntu-latest
31+
32+
defaults:
33+
run:
34+
shell: bash -l {0}
35+
36+
steps:
37+
- uses: actions/checkout@v4
38+
with:
39+
fetch-depth: 0
40+
41+
- name: "build sdist and whell"
42+
run: |
43+
pipx run build
44+
45+
- name: "show sdist and wheel"
46+
run: |
47+
ls -l ${{ github.workspace }}/dist
48+
49+
- uses: actions/upload-artifact@v4
50+
with:
51+
name: pypi-artifacts-${{ github.job }}-${{ strategy.job-index }}
52+
path: ${{ github.workspace }}/dist
53+
54+
test-artifacts:
55+
needs: [build-artifacts]
56+
name: "test wheel (${{ matrix.python-version }})"
57+
runs-on: ubuntu-latest
58+
defaults:
59+
run:
60+
shell: bash -l {0}
61+
env:
62+
ENV_CACHE_BUILD: "0"
63+
#: If you change the IRIS_SOURCE here you will also need to change it in
64+
#: the noxfile and the tests and benchmark workflows.
65+
IRIS_SOURCE: "github:main"
66+
67+
strategy:
68+
fail-fast: false
69+
matrix:
70+
python-version: ["3.11", "3.12", "3.13"]
71+
session: ["wheel"]
72+
73+
steps:
74+
- name: "checkout"
75+
uses: actions/checkout@v4
76+
with:
77+
fetch-depth: 0
78+
79+
- uses: actions/download-artifact@v4
80+
with:
81+
pattern: pypi-artifacts-*
82+
path: ${{ github.workspace }}/dist
83+
merge-multiple: true
84+
85+
- name: Install Nox
86+
run: |
87+
pip install nox
88+
89+
- name: Cache environment directories
90+
id: cache-env-dir
91+
uses: actions/cache@v4
92+
with:
93+
path: |
94+
.nox
95+
$CONDA/pkgs
96+
key: ${{ runner.os }}-${{ hashFiles('requirements/locks/') }}-${{ env.ENV_CACHE_BUILD }}-${{ env.IRIS_SOURCE }}-${{ matrix.python-version }}
97+
98+
- name: "nox install and test wheel"
99+
env:
100+
PY_VER: ${{ matrix.python-version }}
101+
run: |
102+
nox --session ${{ matrix.session }} -- --verbose
103+
104+
show-artifacts:
105+
needs: [build-artifacts]
106+
name: "show artifacts"
107+
runs-on: ubuntu-latest
108+
steps:
109+
- uses: actions/download-artifact@v4
110+
with:
111+
pattern: pypi-artifacts-*
112+
path: ${{ github.workspace }}/dist
113+
merge-multiple: true
114+
115+
- shell: bash
116+
run: |
117+
ls -l ${{ github.workspace }}/dist
118+
119+
publish-artifacts-test-pypi:
120+
needs: [test-artifacts]
121+
name: "Publish to Test PyPI"
122+
runs-on: ubuntu-latest
123+
# upload to Test PyPI for every commit on main branch
124+
# and check for the SciTools repo
125+
if: github.event_name == 'push' && github.event.ref == 'refs/heads/main' && github.repository_owner == 'SciTools'
126+
steps:
127+
- uses: actions/download-artifact@v4
128+
with:
129+
pattern: pypi-artifacts-*
130+
path: ${{ github.workspace }}/dist
131+
merge-multiple: true
132+
133+
- uses: pypa/gh-action-pypi-publish@release/v1
134+
with:
135+
user: __token__
136+
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
137+
repository_url: https://test.pypi.org/legacy/
138+
skip_existing: true
139+
print_hash: true
140+
141+
publish-artifacts-pypi:
142+
needs: [test-artifacts]
143+
name: "Publish to PyPI"
144+
runs-on: ubuntu-latest
145+
# upload to PyPI for every tag starting with 'v'
146+
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v') && github.repository_owner == 'SciTools'
147+
steps:
148+
- uses: actions/download-artifact@v4
149+
with:
150+
pattern: pypi-artifacts-*
151+
path: ${{ github.workspace }}/dist
152+
merge-multiple: true
153+
154+
- uses: pypa/gh-action-pypi-publish@release/v1
155+
with:
156+
user: __token__
157+
password: ${{ secrets.PYPI_API_TOKEN }}
158+
print_hash: true

0 commit comments

Comments
 (0)