From 56d7dff551c45d5712d64eba6dcf77109342cd64 Mon Sep 17 00:00:00 2001 From: leecoder Date: Tue, 8 Sep 2026 15:34:22 +0900 Subject: [PATCH] ci(workflow): accept repository_dispatch and let manual triggers run on the fork - repository_dispatch (event_type: dbx-monitor) provides an external trigger for price-drift alerting to kick off a check - the job guard previously allowed only workflow_dispatch on the fork, which would have skipped repository_dispatch runs; now only the schedule event is pinned to upstream so cron never races, while both manual trigger types run on either repo --- .github/workflows/monitor_databricks_pricing.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/monitor_databricks_pricing.yml b/.github/workflows/monitor_databricks_pricing.yml index 01ed6112c6c..884d8169435 100644 --- a/.github/workflows/monitor_databricks_pricing.yml +++ b/.github/workflows/monitor_databricks_pricing.yml @@ -9,6 +9,9 @@ on: schedule: - cron: "0 2 * * *" # daily 02:00 UTC workflow_dispatch: + # external trigger: POST /repos///dispatches {"event_type":"dbx-monitor"} + repository_dispatch: + types: [dbx-monitor] permissions: contents: write @@ -22,9 +25,9 @@ env: jobs: monitor-db-pricing: - # once merged the cron fires on both repos; upstream owns the schedule, - # the fork stays dispatch-only so the two never race on the same base - if: github.repository == 'BerriAI/litellm' || github.event_name == 'workflow_dispatch' + # the merged cron fires on both repos; upstream owns the schedule so the + # two never race on the same base. manual triggers run on either repo. + if: github.event_name != 'schedule' || github.repository == 'BerriAI/litellm' runs-on: ubuntu-latest steps: - uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4.3.0