From c34ce15fa27481aef92001d2c4d840822cc06679 Mon Sep 17 00:00:00 2001 From: Christine Chen <10511452+christineschen@users.noreply.github.com> Date: Mon, 22 Jun 2026 11:20:24 -0400 Subject: [PATCH 1/2] fix: update auto-merge workflow triggers and bot username - Add 'opened' trigger to catch PRs when bot immediately applies label - Fix bot username from github-actions[bot] to app/github-actions This enables the auto-merge workflow to work with Speakeasy SDK generation PRs. --- .github/workflows/auto-merge-speakeasy-pr.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/auto-merge-speakeasy-pr.yaml b/.github/workflows/auto-merge-speakeasy-pr.yaml index af67cfe9..ee2795e9 100644 --- a/.github/workflows/auto-merge-speakeasy-pr.yaml +++ b/.github/workflows/auto-merge-speakeasy-pr.yaml @@ -5,7 +5,7 @@ name: Auto-merge Speakeasy PR on: pull_request: - types: [labeled] + types: [labeled, opened] permissions: contents: write @@ -18,8 +18,8 @@ concurrency: jobs: auto-merge: if: | - github.event.sender.login == 'github-actions[bot]' && - github.event.pull_request.user.login == 'github-actions[bot]' && + github.event.sender.login == 'app/github-actions' && + github.event.pull_request.user.login == 'app/github-actions' && startsWith(github.event.pull_request.head.ref, 'speakeasy-sdk-regen-') && contains(github.event.pull_request.title, '🐝 Update SDK') && contains(fromJSON('["patch", "minor", "major"]'), github.event.label.name) From add423f7624133bc24f54f04c2a08ca243e01c69 Mon Sep 17 00:00:00 2001 From: Christine Chen <10511452+christineschen@users.noreply.github.com> Date: Mon, 22 Jun 2026 11:59:27 -0400 Subject: [PATCH 2/2] fix: add updated workflow with corrected bot username and event handling - Add 'opened' trigger to catch PRs when bot immediately applies label - Fix bot username to github-actions[bot] (verified via API and commit history) - Restructure condition to handle both 'labeled' and 'opened' events * 'labeled': uses github.event.label.name * 'opened': uses github.event.pull_request.labels.*.name * Prevents 'opened' event from failing due to missing github.event.label This enables the auto-merge workflow to work with Speakeasy SDK generation PRs. --- .github/workflows/auto-merge-speakeasy-pr.yaml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/auto-merge-speakeasy-pr.yaml b/.github/workflows/auto-merge-speakeasy-pr.yaml index ee2795e9..9ba77ed5 100644 --- a/.github/workflows/auto-merge-speakeasy-pr.yaml +++ b/.github/workflows/auto-merge-speakeasy-pr.yaml @@ -18,11 +18,17 @@ concurrency: jobs: auto-merge: if: | - github.event.sender.login == 'app/github-actions' && - github.event.pull_request.user.login == 'app/github-actions' && + github.event.sender.login == 'github-actions[bot]' && + github.event.pull_request.user.login == 'github-actions[bot]' && startsWith(github.event.pull_request.head.ref, 'speakeasy-sdk-regen-') && contains(github.event.pull_request.title, '🐝 Update SDK') && - contains(fromJSON('["patch", "minor", "major"]'), github.event.label.name) + ( + (github.event.action == 'labeled' && contains(fromJSON('["patch", "minor", "major"]'), github.event.label.name)) || + (github.event.action == 'opened' && + (contains(github.event.pull_request.labels.*.name, 'patch') || + contains(github.event.pull_request.labels.*.name, 'minor') || + contains(github.event.pull_request.labels.*.name, 'major'))) + ) runs-on: ubuntu-latest steps: - name: Close superseded Speakeasy PRs