Create cancel-all-pr-test-runs (#8986)
This commit is contained in:
32
.github/workflows/cancel-all-pending-pr-test-runs.yml
vendored
Normal file
32
.github/workflows/cancel-all-pending-pr-test-runs.yml
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
name: Cancel All Pending PR Test Runs
|
||||
|
||||
on:
|
||||
workflow_dispatch: # Manual trigger
|
||||
|
||||
jobs:
|
||||
cancel-pending:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Install GitHub CLI
|
||||
run: apt-get install -y gh jq
|
||||
|
||||
- name: Authenticate GitHub CLI
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: gh auth login --with-token <<< "$GH_TOKEN"
|
||||
|
||||
- name: Cancel all pending/waiting pr-test.yml runs
|
||||
env:
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
REPO: ${{ github.repository }}
|
||||
run: |
|
||||
# Get all pending or waiting runs of pr-test.yml across all branches
|
||||
gh run list \
|
||||
--workflow pr-test.yml \
|
||||
--json databaseId,status,conclusion \
|
||||
--limit 1000 \
|
||||
| jq -r '.[] | select(.status=="queued" or .status=="in_progress") | .databaseId' \
|
||||
| while read run_id; do
|
||||
echo "Cancelling run ID: $run_id"
|
||||
gh run cancel "$run_id"
|
||||
done
|
||||
2
.github/workflows/pr-test-amd.yml
vendored
2
.github/workflows/pr-test-amd.yml
vendored
@@ -323,7 +323,7 @@ jobs:
|
||||
docker exec -w /sglang-checkout/sgl-kernel/tests ci_sglang python3 -m pytest test_moe_topk_softmax.py
|
||||
docker exec -w /sglang-checkout/sgl-kernel/tests/speculative ci_sglang python3 -m pytest test_eagle_utils.py
|
||||
|
||||
finish:
|
||||
pr-test-amd-finish:
|
||||
if: always()
|
||||
needs: [
|
||||
accuracy-test-1-gpu-amd, mla-test-1-gpu-amd, bench-test-2-gpu-amd,
|
||||
|
||||
2
.github/workflows/pr-test-npu.yml
vendored
2
.github/workflows/pr-test-npu.yml
vendored
@@ -109,7 +109,7 @@ jobs:
|
||||
cd test/srt
|
||||
python3 run_suite.py --suite per-commit-4-ascend-npu --timeout-per-file 3600
|
||||
|
||||
finish:
|
||||
pr-test-npu-finish:
|
||||
if: always()
|
||||
needs:
|
||||
- per-commit-1-ascend-npu
|
||||
|
||||
36
.github/workflows/pr-test-xeon.yml
vendored
36
.github/workflows/pr-test-xeon.yml
vendored
@@ -1,17 +1,32 @@
|
||||
name: PR Test (Xeon)
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ main ]
|
||||
paths:
|
||||
- "python/**"
|
||||
- "scripts/**"
|
||||
- "test/**"
|
||||
- "sgl-kernel/**"
|
||||
- ".github/workflows/pr-test-xeon.yml"
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
branches: [ main ]
|
||||
paths:
|
||||
- "python/**"
|
||||
- "scripts/**"
|
||||
- "test/**"
|
||||
- "sgl-kernel/**"
|
||||
- ".github/workflows/pr-test-xeon.yml"
|
||||
workflow_dispatch:
|
||||
|
||||
concurrency:
|
||||
group: pr-test-xeon
|
||||
group: pr-test-xeon-${{ github.ref }}
|
||||
cancel-in-progress: false
|
||||
|
||||
jobs:
|
||||
build-test:
|
||||
if: github.event_name == 'pull_request'
|
||||
if: (github.repository == 'sgl-project/sglang' || github.event_name == 'pull_request') &&
|
||||
github.event.pull_request.draft == false
|
||||
runs-on: sglang-pvc
|
||||
strategy:
|
||||
matrix:
|
||||
@@ -34,16 +49,15 @@ jobs:
|
||||
--name ci_sglang_xeon \
|
||||
sglang_xeon
|
||||
|
||||
- name: Install Dependency
|
||||
- name: Install dependencies
|
||||
timeout-minutes: 20
|
||||
run: |
|
||||
docker exec ci_sglang_xeon bash -c "python3 -m pip install --upgrade pip"
|
||||
docker exec ci_sglang_xeon pip uninstall sgl-kernel -y || true
|
||||
docker exec -w /sglang-checkout/sgl-kernel ci_sglang_xeon bash -c "cp pyproject_cpu.toml pyproject.toml && pip install -v ."
|
||||
docker exec -w /sglang-checkout/ ci_sglang_xeon bash -c "pip install -e "python[all_cpu]""
|
||||
docker exec ci_sglang_xeon bash -c "python3 -m pip install pytest expecttest"
|
||||
docker exec -w /sglang-checkout/ ci_sglang_xeon bash -c "pip install -e "python[dev_cpu]""
|
||||
|
||||
- name: Check AMX Support
|
||||
- name: Check AMX support
|
||||
id: check_amx
|
||||
timeout-minutes: 5
|
||||
run: |
|
||||
@@ -51,7 +65,7 @@ jobs:
|
||||
bash -c "python3 -c 'import torch; import sgl_kernel; assert torch._C._cpu._is_amx_tile_supported(); assert hasattr(torch.ops.sgl_kernel, \"convert_weight_packed\"); '"
|
||||
continue-on-error: true
|
||||
|
||||
- name: Run UT Cases
|
||||
- name: Run unit tests
|
||||
if: steps.check_amx.outcome == 'success'
|
||||
timeout-minutes: 20
|
||||
run: |
|
||||
@@ -63,10 +77,10 @@ jobs:
|
||||
run: |
|
||||
docker rm -f ci_sglang_xeon || true
|
||||
|
||||
finish:
|
||||
pr-test-xeon-finish:
|
||||
if: always()
|
||||
needs: [build-test]
|
||||
runs-on: ubuntu-24.04
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check all dependent job statuses
|
||||
run: |
|
||||
|
||||
@@ -105,6 +105,7 @@ torch_memory_saver = ["torch_memory_saver>=0.0.8"]
|
||||
decord = ["decord"]
|
||||
test = [
|
||||
"accelerate",
|
||||
"expecttest",
|
||||
"jsonlines",
|
||||
"matplotlib",
|
||||
"pandas",
|
||||
|
||||
Reference in New Issue
Block a user