From 62054cda7a3fd90a0cdf13c6ea0c9edaba44bdc3 Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Fri, 6 Feb 2026 11:01:17 -0800 Subject: [PATCH 01/21] [bfops/discord-post-on-merge]: WIP --- .github/workflows/discord-posts.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index b1e55497401..825942e02c4 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -69,3 +69,23 @@ jobs: # Use `jq` to construct the json data blob in the format required by the webhook. data="$(jq --null-input --arg msg "$message" '.content=$msg')" curl -X POST -H 'Content-Type: application/json' -d "$data" "${DISCORD_WEBHOOK_URL}" + + - name: Trigger private merge follow-up + uses: actions/github-script@v7 + with: + github-token: ${{ secrets.SPACETIMEDB_PRIVATE_TOKEN }} + script: | + const workflowId = 'public-pr-merge.yml'; + const targetOwner = 'clockworklabs'; + const targetRepo = 'SpacetimeDBPrivate'; + const targetRef = 'master'; + + await github.rest.actions.createWorkflowDispatch({ + owner: targetOwner, + repo: targetRepo, + workflow_id: workflowId, + ref: targetRef, + inputs: { + public_pr_number: String(context.payload.pull_request.number), + } + }); From e3014ed15874ce2327043b367a0feb25364923ce Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Fri, 6 Feb 2026 11:06:28 -0800 Subject: [PATCH 02/21] [bfops/discord-post-on-merge]: simplify --- .github/workflows/discord-posts.yml | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index 825942e02c4..bcdba753d91 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -20,6 +20,7 @@ jobs: sudo apt-get update sudo apt-get install -y gh + # TODO: Perhaps we should merge this into the public-pr-merge.yml workflow, now that that exists. - name: Send Discord notification env: DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }} @@ -70,21 +71,16 @@ jobs: data="$(jq --null-input --arg msg "$message" '.content=$msg')" curl -X POST -H 'Content-Type: application/json' -d "$data" "${DISCORD_WEBHOOK_URL}" - - name: Trigger private merge follow-up + - name: Dispatch private merge workflow uses: actions/github-script@v7 with: github-token: ${{ secrets.SPACETIMEDB_PRIVATE_TOKEN }} script: | - const workflowId = 'public-pr-merge.yml'; - const targetOwner = 'clockworklabs'; - const targetRepo = 'SpacetimeDBPrivate'; - const targetRef = 'master'; - await github.rest.actions.createWorkflowDispatch({ - owner: targetOwner, - repo: targetRepo, - workflow_id: workflowId, - ref: targetRef, + owner: 'clockworklabs', + repo: 'SpacetimeDBPrivate', + workflow_id: 'public-pr-merge.yml', + ref: 'master', inputs: { public_pr_number: String(context.payload.pull_request.number), } From 3722020b52ad5551e83e3d382cb1115308b246c2 Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Fri, 6 Feb 2026 13:38:02 -0800 Subject: [PATCH 03/21] [bfops/discord-post-on-merge]: test --- .github/workflows/discord-posts.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index bcdba753d91..5ccce404d10 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -80,7 +80,7 @@ jobs: owner: 'clockworklabs', repo: 'SpacetimeDBPrivate', workflow_id: 'public-pr-merge.yml', - ref: 'master', + ref: 'bfops/smarter-internal-tests', inputs: { public_pr_number: String(context.payload.pull_request.number), } From 59daa3425bea1d3dde8cc000444b256d92a37d5e Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Fri, 6 Feb 2026 13:46:52 -0800 Subject: [PATCH 04/21] [bfops/discord-post-on-merge]: break up --- .github/workflows/discord-posts.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index 5ccce404d10..3c7627e558c 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -71,6 +71,12 @@ jobs: data="$(jq --null-input --arg msg "$message" '.content=$msg')" curl -X POST -H 'Content-Type: application/json' -d "$data" "${DISCORD_WEBHOOK_URL}" + invokePrivate: + runs-on: ubuntu-latest + if: github.event.pull_request.merged == true + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + steps: - name: Dispatch private merge workflow uses: actions/github-script@v7 with: From 3284ae57f370e42cd21819577347c70a23b03e51 Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Fri, 6 Feb 2026 13:49:25 -0800 Subject: [PATCH 05/21] [bfops/discord-post-on-merge]: reduce --- .github/workflows/discord-posts.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index 3c7627e558c..f64e7862dc3 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -74,8 +74,6 @@ jobs: invokePrivate: runs-on: ubuntu-latest if: github.event.pull_request.merged == true - env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - name: Dispatch private merge workflow uses: actions/github-script@v7 From 303b4115670584a285454c6696a0539cbc976020 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Fri, 6 Feb 2026 13:49:58 -0800 Subject: [PATCH 06/21] Discord test PR (#4227) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] Co-authored-by: Zeke Foppa From 0d3eb535be52c344ec9e08cb8a30db78bea7b00a Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Mon, 9 Feb 2026 14:30:12 -0800 Subject: [PATCH 07/21] Bfops/discord test pr 2 (#4235) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] --------- Co-authored-by: Zeke Foppa From 580e90edbf9227091fc70b101fef758a0b2b9918 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Mon, 9 Feb 2026 14:35:39 -0800 Subject: [PATCH 08/21] Discord notification test PR (#4236) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] --------- Co-authored-by: Zeke Foppa From d4cc1f4b9007fc828e197ecc257377bb6271c3d5 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Mon, 9 Feb 2026 14:36:41 -0800 Subject: [PATCH 09/21] Discord notification test PR (#4237) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] Co-authored-by: Zeke Foppa From 5bb498f04d02a3f497198b2711563f4c4fb2c629 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Mon, 9 Feb 2026 14:42:58 -0800 Subject: [PATCH 10/21] Discord notification test PR (#4238) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] Co-authored-by: Zeke Foppa From 11d768aac5e542f718bcb9361fd770a699c658d4 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Mon, 9 Feb 2026 14:44:56 -0800 Subject: [PATCH 11/21] Discord notification test PR (#4239) Co-authored-by: Zeke Foppa From 51e9c91706cd2c6514deb9b7e74276af11434523 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Mon, 9 Feb 2026 14:45:39 -0800 Subject: [PATCH 12/21] Discord notification test PR (#4240) Co-authored-by: Zeke Foppa From 7595a75132489792d6e63bfd0eab8e498ae2626d Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Mon, 9 Feb 2026 16:20:46 -0800 Subject: [PATCH 13/21] [bfops/discord-post-on-merge]: empty From 8835d6d27478a59282eeaefba8b6f13deea6afc2 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Wed, 22 Apr 2026 10:54:13 -0500 Subject: [PATCH 14/21] Bfops/4224 test without private (#4865) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] Co-authored-by: Zeke Foppa From e50567c0dce28d31c8a3a752592beaf5e4cf655b Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Wed, 22 Apr 2026 08:57:28 -0700 Subject: [PATCH 15/21] [bfops/discord-post-on-merge]: fix --- .github/workflows/discord-posts.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index f64e7862dc3..646cbe3059a 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -84,7 +84,7 @@ jobs: owner: 'clockworklabs', repo: 'SpacetimeDBPrivate', workflow_id: 'public-pr-merge.yml', - ref: 'bfops/smarter-internal-tests', + ref: 'master', inputs: { public_pr_number: String(context.payload.pull_request.number), } From 3c949b30513689914f33a7881101d535a541388e Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Wed, 22 Apr 2026 10:58:37 -0500 Subject: [PATCH 16/21] [bfops/4224-test-without-private]: empty (#4866) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] Co-authored-by: Zeke Foppa From 348ea2221d97b3adfa115c374108cd80a0090fe4 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Wed, 22 Apr 2026 11:00:51 -0500 Subject: [PATCH 17/21] Bfops/4224 test with private (#4864) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] Co-authored-by: Zeke Foppa From af453828c693a8c09941b1981f1ee65c8cb1b75a Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Wed, 22 Apr 2026 11:16:36 -0500 Subject: [PATCH 18/21] Bfops/4224 test with private (#4867) # Description of Changes # API and ABI breaking changes # Expected complexity level and risk # Testing - [ ] - [ ] --------- Co-authored-by: Zeke Foppa From ea904643acf285d527b2be3b87d638b8398accf0 Mon Sep 17 00:00:00 2001 From: Zeke Foppa <196249+bfops@users.noreply.github.com> Date: Wed, 22 Apr 2026 09:20:12 -0700 Subject: [PATCH 19/21] Apply suggestion from @bfops Signed-off-by: Zeke Foppa <196249+bfops@users.noreply.github.com> --- .github/workflows/discord-posts.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index 646cbe3059a..c923f4e23ac 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -73,7 +73,8 @@ jobs: invokePrivate: runs-on: ubuntu-latest - if: github.event.pull_request.merged == true + if: github.event.pull_request.merged == true && + github.event.pull_request.base.ref == 'master' steps: - name: Dispatch private merge workflow uses: actions/github-script@v7 From 9463edd9ab4dee3a1750c322aace1902bca2f625 Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Wed, 22 Apr 2026 09:23:19 -0700 Subject: [PATCH 20/21] [bfops/discord-post-on-merge]: [bfops/4224-test-with-private]: fix complaint? --- .github/workflows/discord-posts.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index c923f4e23ac..38f27b062f0 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -4,6 +4,7 @@ on: pull_request: types: [closed] + jobs: discordNotification: runs-on: ubuntu-latest @@ -75,6 +76,8 @@ jobs: runs-on: ubuntu-latest if: github.event.pull_request.merged == true && github.event.pull_request.base.ref == 'master' + permissions: + contents: read steps: - name: Dispatch private merge workflow uses: actions/github-script@v7 From a1a95e84dcc794dc9a4604a84b70e76e30ede06d Mon Sep 17 00:00:00 2001 From: Zeke Foppa Date: Wed, 22 Apr 2026 09:25:20 -0700 Subject: [PATCH 21/21] [bfops/discord-post-on-merge]: review --- .github/workflows/discord-posts.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/discord-posts.yml b/.github/workflows/discord-posts.yml index 38f27b062f0..1e53262971e 100644 --- a/.github/workflows/discord-posts.yml +++ b/.github/workflows/discord-posts.yml @@ -4,7 +4,6 @@ on: pull_request: types: [closed] - jobs: discordNotification: runs-on: ubuntu-latest