Skip to content

Commit 002b787

Browse files
authored
fix(ci): eliminate redundant CI runs and migrate release-please (#70)
* fix(ci): eliminate redundant CI runs on release-please PRs and main pushes - Skip test, lint, and Docker build jobs on release-please PRs (metadata-only changes) - Remove duplicate test-unit/test-integration steps on main (test-coverage already runs full suite) - Migrate from deprecated google-github-actions/release-please-action to googleapis/release-please-action - Update docker-validation to accept skipped upstream jobs gracefully * chore: sync uv.lock version to 1.1.0
1 parent 919dc2b commit 002b787

2 files changed

Lines changed: 14 additions & 18 deletions

File tree

.github/workflows/ci.yml

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ env:
1919
jobs:
2020
test:
2121
runs-on: ubuntu-latest
22+
if: github.event_name != 'pull_request' || github.head_ref != 'release-please--branches--main'
2223
strategy:
2324
matrix:
2425
python-version: ${{ github.event_name == 'pull_request' && fromJSON('["3.11", "3.12"]') || fromJSON('["3.10", "3.11", "3.12", "3.13", "3.14"]') }}
@@ -48,16 +49,9 @@ jobs:
4849
- name: Run all tests with coverage
4950
run: make test-coverage
5051

51-
- name: Run unit tests separately (main branch only)
52-
if: github.ref == 'refs/heads/main'
53-
run: make test-unit
54-
55-
- name: Run integration tests separately (main branch only)
56-
if: github.ref == 'refs/heads/main'
57-
run: make test-integration
58-
5952
lint:
6053
runs-on: ubuntu-latest
54+
if: github.event_name != 'pull_request' || github.head_ref != 'release-please--branches--main'
6155
steps:
6256
- name: Checkout repository
6357
uses: actions/checkout@v4
@@ -80,6 +74,7 @@ jobs:
8074

8175
docker-test:
8276
runs-on: ubuntu-latest
77+
if: github.event_name != 'pull_request' || github.head_ref != 'release-please--branches--main'
8378
needs: [lint]
8479
steps:
8580
- name: Clear Space
@@ -131,6 +126,7 @@ jobs:
131126
132127
docker-test-lb:
133128
runs-on: ubuntu-latest
129+
if: github.event_name != 'pull_request' || github.head_ref != 'release-please--branches--main'
134130
needs: [lint]
135131
steps:
136132
- name: Free Disk Space
@@ -181,6 +177,7 @@ jobs:
181177

182178
docker-test-lb-cpu:
183179
runs-on: ubuntu-latest
180+
if: github.event_name != 'pull_request' || github.head_ref != 'release-please--branches--main'
184181
needs: [lint]
185182
steps:
186183
- name: Clear Space
@@ -232,14 +229,13 @@ jobs:
232229
steps:
233230
- name: Check all jobs succeeded
234231
run: |
235-
if [[ "${{ needs.test.result }}" != "success" ]] || \
236-
[[ "${{ needs.lint.result }}" != "success" ]] || \
237-
[[ "${{ needs.docker-test.result }}" != "success" ]] || \
238-
[[ "${{ needs.docker-test-lb.result }}" != "success" ]] || \
239-
[[ "${{ needs.docker-test-lb-cpu.result }}" != "success" ]]; then
240-
echo "One or more quality checks failed"
241-
exit 1
242-
fi
232+
results=("${{ needs.test.result }}" "${{ needs.lint.result }}" "${{ needs.docker-test.result }}" "${{ needs.docker-test-lb.result }}" "${{ needs.docker-test-lb-cpu.result }}")
233+
for result in "${results[@]}"; do
234+
if [[ "$result" != "success" && "$result" != "skipped" ]]; then
235+
echo "One or more quality checks failed (got: $result)"
236+
exit 1
237+
fi
238+
done
243239
244240
release:
245241
runs-on: ubuntu-latest
@@ -256,7 +252,7 @@ jobs:
256252
app-id: ${{ secrets.RELEASE_APP_ID }}
257253
private-key: ${{ secrets.RELEASE_APP_PRIVATE_KEY }}
258254

259-
- uses: google-github-actions/release-please-action@v4
255+
- uses: googleapis/release-please-action@v4
260256
id: release
261257
with:
262258
token: ${{ steps.app-token.outputs.token }}

uv.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)