Summary
The current CI workflow triggers too many unnecessary Action runs. Four issues identified:
Problem 1 — Double Triggers (~50% run reduction)
on: [push, pull_request] causes every PR commit to trigger two runs (one for push, one for pull_request).
Fix:
on:
push:
branches: [develop, main]
pull_request:
Problem 2 — No Concurrency / Cancel
Rapid successive commits cause all queued runs to complete, wasting runner minutes.
Fix — top-level in ci.yml:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
Problem 3 — No Path Filtering
A change in server/ still triggers all SDK and compliance-tool jobs.
Fix — per job with paths filter:
# sdk jobs
on:
push:
paths:
- 'sdk/**'
- '.github/workflows/ci.yml'
# compliance-tool jobs
on:
push:
paths:
- 'compliance_tool/**'
- 'sdk/**'
# server jobs
on:
push:
paths:
- 'server/**'
- 'sdk/**'
Note: path filtering at job level requires either separate workflow files per package or use of jobs.<job>.if with github.event.head_commit path checks.
Problem 4 — No pip Caching
All 12 jobs install dependencies from scratch on every run.
Fix — add cache: 'pip' to every actions/setup-python step:
- uses: actions/setup-python@v5
with:
python-version: ${{ env.X_PYTHON_MIN_VERSION }}
cache: 'pip'
Impact Summary
| # |
Problem |
Impact |
Effort |
| 1 |
Double triggers |
~50% fewer runs |
Low |
| 2 |
No concurrency/cancel |
Eliminates waste on rapid pushes |
Low |
| 3 |
No path filtering |
Skips irrelevant jobs |
Medium |
| 4 |
No pip caching |
Faster runs |
Low |
Recommendation: Fix problems 1 and 2 first — immediate impact, zero risk.
Summary
The current CI workflow triggers too many unnecessary Action runs. Four issues identified:
Problem 1 — Double Triggers (~50% run reduction)
on: [push, pull_request]causes every PR commit to trigger two runs (one forpush, one forpull_request).Fix:
Problem 2 — No Concurrency / Cancel
Rapid successive commits cause all queued runs to complete, wasting runner minutes.
Fix — top-level in
ci.yml:Problem 3 — No Path Filtering
A change in
server/still triggers all SDK and compliance-tool jobs.Fix — per job with
pathsfilter:Problem 4 — No pip Caching
All 12 jobs install dependencies from scratch on every run.
Fix — add
cache: 'pip'to everyactions/setup-pythonstep:Impact Summary
Recommendation: Fix problems 1 and 2 first — immediate impact, zero risk.