[CI] Replace the Lark queue-digest card with a daily queue-timeline chart (#38380)
This commit is contained in:
@@ -9,14 +9,13 @@ on:
|
||||
branches: [main]
|
||||
schedule:
|
||||
- cron: '*/15 * * * *' # runner-health
|
||||
- cron: '30 */8 * * *' # queue-digest
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
task:
|
||||
description: 'Which report to run'
|
||||
required: true
|
||||
type: choice
|
||||
options: [ci-status, runner-health, queue-digest]
|
||||
options: [ci-status, runner-health]
|
||||
run_id:
|
||||
description: 'Workflow run id (ci-status only)'
|
||||
required: false
|
||||
@@ -94,33 +93,11 @@ jobs:
|
||||
LARK_WEBHOOK: ${{ secrets.LARK_WEBHOOK }}
|
||||
run: |
|
||||
python scripts/ci_monitor/lark_notify.py $DRY_RUN_FLAG runner-health \
|
||||
--state-file runner-health-state.json
|
||||
--state-file runner-health-state.json \
|
||||
--remind-hours 6
|
||||
- name: Save runner-health state
|
||||
if: ${{ !inputs.dry_run }}
|
||||
uses: actions/cache/save@v4
|
||||
with:
|
||||
path: runner-health-state.json
|
||||
key: lark-runner-health-${{ github.run_id }}
|
||||
|
||||
queue-digest:
|
||||
if: >-
|
||||
github.repository == 'sgl-project/sglang' && (
|
||||
(github.event_name == 'schedule' && github.event.schedule == '30 */8 * * *') ||
|
||||
(github.event_name == 'workflow_dispatch' && inputs.task == 'queue-digest')
|
||||
)
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
sparse-checkout: scripts/ci_monitor
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.12'
|
||||
- name: Post queue digest
|
||||
env:
|
||||
# PAT: an 8h window is ~400-500 API calls, too close to GITHUB_TOKEN's 1000/h
|
||||
GITHUB_TOKEN: ${{ secrets.GH_PAT_FOR_NIGHTLY_CI_DATA }}
|
||||
LARK_WEBHOOK: ${{ secrets.LARK_WEBHOOK }}
|
||||
run: |
|
||||
python scripts/ci_monitor/lark_notify.py $DRY_RUN_FLAG queue-digest --hours 8 --only-if-slow
|
||||
|
||||
@@ -68,4 +68,18 @@ jobs:
|
||||
python scripts/ci/utils/runner_utilization_report.py \
|
||||
--repo ${{ github.repository }} \
|
||||
--hours ${{ (github.event_name == 'pull_request' && '0.34') || inputs.hours || '24' }} \
|
||||
${{ inputs.filter && format('--filter {0}', inputs.filter) || '' }}
|
||||
${{ inputs.filter && format('--filter {0}', inputs.filter) || '' }} \
|
||||
--queue-series-out queue-series.json
|
||||
|
||||
# The card rides on the scan above rather than running its own: a 24h
|
||||
# window is ~5000 API calls, the whole hourly budget of ci-lark-notify's PAT.
|
||||
- name: Post queue timeline card
|
||||
if: >-
|
||||
github.repository == 'sgl-project/sglang' &&
|
||||
github.event_name != 'pull_request'
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
LARK_WEBHOOK: ${{ secrets.LARK_WEBHOOK }}
|
||||
run: |
|
||||
python scripts/ci_monitor/lark_notify.py queue-timeline \
|
||||
--series-file queue-series.json
|
||||
|
||||
Reference in New Issue
Block a user