From ada2b52c34d6da9856ad19e758fa024a4c6c0f45 Mon Sep 17 00:00:00 2001 From: "Kevin H. Luu" Date: Fri, 12 Jul 2024 11:36:26 -0700 Subject: [PATCH] [ci] Add GHA workflows to enable full CI run (#6381) Signed-off-by: kevin --- .github/workflows/add_label_automerge.yml | 21 +++++++++++++++++ .github/workflows/add_label_ready_comment.yml | 23 +++++++++++++++++++ .github/workflows/reminder_comment.yml | 21 +++++++++++++++++ 3 files changed, 65 insertions(+) create mode 100644 .github/workflows/add_label_automerge.yml create mode 100644 .github/workflows/add_label_ready_comment.yml create mode 100644 .github/workflows/reminder_comment.yml diff --git a/.github/workflows/add_label_automerge.yml b/.github/workflows/add_label_automerge.yml new file mode 100644 index 0000000000000..cd53b764c7200 --- /dev/null +++ b/.github/workflows/add_label_automerge.yml @@ -0,0 +1,21 @@ +name: Add label on auto-merge enabled +on: + pull_request_target: + types: + - auto_merge_enabled +jobs: + add-label-on-auto-merge: + runs-on: ubuntu-latest + steps: + - name: Add label + uses: actions/github-script@v5 + with: + script: | + github.rest.issues.addLabels({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + labels: ['ready'] + }) + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/add_label_ready_comment.yml b/.github/workflows/add_label_ready_comment.yml new file mode 100644 index 0000000000000..729c1452af03d --- /dev/null +++ b/.github/workflows/add_label_ready_comment.yml @@ -0,0 +1,23 @@ +name: Add Ready Label on Ready Comment + +on: + issue_comment: + types: [created] + +jobs: + add-ready-label: + runs-on: ubuntu-latest + if: github.event.issue.pull_request && contains(github.event.comment.body, '/ready') + steps: + - name: Add label + uses: actions/github-script@v5 + with: + script: | + github.rest.issues.addLabels({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + labels: ['ready'] + }) + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/reminder_comment.yml b/.github/workflows/reminder_comment.yml new file mode 100644 index 0000000000000..978d81ad5c280 --- /dev/null +++ b/.github/workflows/reminder_comment.yml @@ -0,0 +1,21 @@ +name: PR Reminder Comment Bot +on: + pull_request_target: + types: [opened] + +jobs: + pr_reminder: + runs-on: ubuntu-latest + steps: + - name: Remind to run full CI on PR + uses: actions/github-script@v6 + with: + script: | + github.rest.issues.createComment({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + body: 'šŸ‘‹ Hi! Thank you for contributing to the vLLM project.\n Just a reminder: PRs would not trigger full CI run by default. Instead, it would only trigger `fastcheck` CI to run, which consists only a small and essential subset of tests to quickly catch small errors.\n\nFull CI run is still required to merge this PR so please make sure that you run full CI before merging or if you need more test signals.\n\n To run full CI, you can do one of these:\n- Add `ready` label to the PR\n- Comment `/ready` on the PR\n- Enable auto-merge.\n\nšŸš€' + }) + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}