Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: experimental PR speed improvement: filter PR change folder #3477

Open
wants to merge 12 commits into
base: master
Choose a base branch
from
10 changes: 10 additions & 0 deletions .github/workflows/image-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,23 @@ name: 'build container images tests'

on:
pull_request:
paths-ignore:
- '.devcontainer/**'
- '.devcontainer-scripts/**'
- '.github/**'
- '.vscode/**'
- 'examples/**'
- 'docs/**'
- 'gallery/**'
- '*.md'

concurrency:
group: ci-${{ github.head_ref || github.ref }}-${{ github.repository }}
cancel-in-progress: true

jobs:
extras-image-build:
if: github.event.pull_request.changed_files != 0
uses: ./.github/workflows/image_build.yml
with:
tag-latest: ${{ matrix.tag-latest }}
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ on:
tags:
- 'v*'
pull_request:
paths-ignore:
- '.devcontainer/**'
- '.devcontainer-scripts/**'
- '.github/**'
- '.vscode/**'
- 'examples/**'
- 'docs/**'
- 'gallery/**'
- '*.md'

env:
GRPC_VERSION: v1.65.0
Expand All @@ -21,6 +30,7 @@ concurrency:
jobs:

build-linux-arm:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand Down Expand Up @@ -129,6 +139,7 @@ jobs:
connect-timeout-seconds: 180
limit-access-to-actor: true
build-linux:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: arc-runner-set
steps:
- name: Force Install GIT latest
Expand Down Expand Up @@ -238,6 +249,7 @@ jobs:
connect-timeout-seconds: 180
limit-access-to-actor: true
build-stablediffusion:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand Down Expand Up @@ -273,6 +285,7 @@ jobs:
release/*

build-macOS-x86_64:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: macos-13
steps:
- name: Clone
Expand Down Expand Up @@ -315,6 +328,7 @@ jobs:
limit-access-to-actor: true

build-macOS-arm64:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: macos-14
steps:
- name: Clone
Expand Down
30 changes: 30 additions & 0 deletions .github/workflows/report_status.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# .github/actions/report-status/action.yml
name: 'Report Status'
on:
workflow_call:
inputs:
job_name:
description: 'The name of the job to report'
required: true
default: ''
type: string
runs-on:
description: 'Runs on'
required: true
default: 'ubuntu-latest'
type: string
jobs:
reusable-report-status:
runs-on: ${{ inputs.runs-on }}
steps:
- name: Print Job Result
run: |
echo "Job: ${{ inputs.job_name }}""
echo "${{ needs[inputs.job_name].result }}"

- name: Check Job Status
run: |
if [[ "${{ needs[inputs.job_name].result }}" == "failure" || "${{ needs[inputs.job_name].result }}" == "cancelled" ]]; then
echo "${{ needs[inputs.job_name].output }}"
exit 1
fi
65 changes: 64 additions & 1 deletion .github/workflows/test-extra.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,15 @@ name: 'Tests extras backends'

on:
pull_request:
paths-ignore:
- '.devcontainer/**'
- '.devcontainer-scripts/**'
- '.github/**'
- '.vscode/**'
- 'examples/**'
- 'docs/**'
- 'gallery/**'
- '*.md'
push:
branches:
- master
Expand All @@ -15,6 +24,7 @@ concurrency:

jobs:
tests-transformers:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -37,6 +47,7 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/transformers test

tests-sentencetransformers:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -58,8 +69,8 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/sentencetransformers
make --jobs=5 --output-sync=target -C backend/python/sentencetransformers test


tests-rerankers:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -82,6 +93,7 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/rerankers test

tests-diffusers:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -103,6 +115,7 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/diffusers test

tests-parler-tts:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -125,6 +138,7 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/parler-tts test

tests-openvoice:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -147,6 +161,7 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/openvoice test

tests-transformers-musicgen:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand Down Expand Up @@ -254,6 +269,7 @@ jobs:
# make --jobs=5 --output-sync=target -C backend/python/vllm
# make --jobs=5 --output-sync=target -C backend/python/vllm test
tests-vallex:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -275,6 +291,7 @@ jobs:
make --jobs=5 --output-sync=target -C backend/python/vall-e-x test

tests-coqui:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Clone
Expand All @@ -293,3 +310,49 @@ jobs:
run: |
make --jobs=5 --output-sync=target -C backend/python/coqui
make --jobs=5 --output-sync=target -C backend/python/coqui test

report-extra-test-results:
runs-on: ubuntu-latest
if: ${{ always() }}
needs: [tests-transformers, tests-sentencetransformers, tests-rerankers, tests-diffusers, tests-parler-tts, tests-openvoice, tests-transformers-musicgen, tests-vallex, tests-coqui]
steps:
- name: Report Status for coqui
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-coqui
- name: Report Status for diffusers
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-diffusers
- name: Report Status for openvoice
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-openvoice
- name: Report Status for parler-tts
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-parler-tts
- name: Report Status for tests-transformers
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-transformers
- name: Report Status for tests-transformers-musicgen
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-transformers-musicgen
- name: Report Status for tests-sentencetransformers
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-sentencetransformers
- name: Report Status for tests-rerankers
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-rerankers
- name: Report Status for tests-vallex
uses: ./.github/workflows/report_status.yaml
with:
job_name: tests-vallex
- name: Report Success
run: |
echo "test-extra successfully completed"
exit 0
12 changes: 12 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,15 @@ name: 'tests'

on:
pull_request:
paths-ignore:
- '.devcontainer/**'
- '.devcontainer-scripts/**'
- '.github/**'
- '.vscode/**'
- 'examples/**'
- 'docs/**'
- 'gallery/**'
- '*.md'
push:
branches:
- master
Expand All @@ -18,6 +27,7 @@ concurrency:

jobs:
tests-linux:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
strategy:
matrix:
Expand Down Expand Up @@ -140,6 +150,7 @@ jobs:
limit-access-to-actor: true

tests-aio-container:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: ubuntu-latest
steps:
- name: Release space from worker
Expand Down Expand Up @@ -204,6 +215,7 @@ jobs:
limit-access-to-actor: true

tests-apple:
if: github.event_name != 'pull_request' || github.event.pull_request.changed_files != 0
runs-on: macOS-14
strategy:
matrix:
Expand Down