Skip to content

Commit 0e7787a

Browse files
authored
feat: merge-train/spartan (#24972)
BEGIN_COMMIT_OVERRIDE chore(ci): route spartan/spartan-v5 merge-train notifications to #team-alpha-ci (#24963) END_COMMIT_OVERRIDE
2 parents feff585 + 40e0206 commit 0e7787a

6 files changed

Lines changed: 20 additions & 10 deletions

File tree

.github/workflows/merge-train-stale-check.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
env:
2121
GH_TOKEN: ${{ secrets.AZTEC_BOT_GITHUB_TOKEN }}
2222
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
23-
run: ./ci3/merge_train_stale_check merge-train/spartan '#team-alpha'
23+
run: ./ci3/merge_train_stale_check merge-train/spartan '#team-alpha-ci'
2424

2525
spartan-v5:
2626
name: Check merge-train/spartan-v5
@@ -36,7 +36,7 @@ jobs:
3636
GH_TOKEN: ${{ secrets.AZTEC_BOT_GITHUB_TOKEN }}
3737
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
3838
BASE_BRANCH: v5-next
39-
run: ./ci3/merge_train_stale_check merge-train/spartan-v5 '#team-alpha'
39+
run: ./ci3/merge_train_stale_check merge-train/spartan-v5 '#team-alpha-ci'
4040

4141
fairies-v5:
4242
name: Check merge-train/fairies-v5

.github/workflows/network-healthcheck.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,14 @@ jobs:
3737
5. Any errors (level >= 50) or warnings (level 40) in the last 8 hours
3838
6. Bot status if applicable
3939
40-
Create a gist with the full healthcheck report. Then post a concise summary to the #team-alpha channel via respond_to_user. Flag anything that needs attention (stopped bots, missed slots, errors, low peer counts).
40+
Create a gist with the full healthcheck report. Then post a concise summary to the #team-alpha-ci channel via respond_to_user. Flag anything that needs attention (stopped bots, missed slots, errors, low peer counts).
4141
4242
Format the respond_to_user message as a brief network status overview, e.g.:
4343
- testnet: healthy, block 5570, 100 peers
4444
- mainnet: healthy, block 1234, 50 peers
4545
- devnet: WARNING - bot stopped (insufficient balance)
4646
Link to the gist for full details."
4747
48-
./ci3/slack_notify_with_claudebox_kickoff "#team-alpha" \
48+
./ci3/slack_notify_with_claudebox_kickoff "#team-alpha-ci" \
4949
"Starting network healthcheck for: ${NETWORKS}" \
5050
"$PROMPT"

ci3/merge_train_failure_slack_notify

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ elif [[ "$REF_NAME" == "merge-train/fairies" ]]; then
3636
elif [[ "$REF_NAME" == "merge-train/fairies-v5" ]]; then
3737
channel="#team-fairies"
3838
elif [[ "$REF_NAME" == "merge-train/spartan" ]]; then
39-
channel="#team-alpha"
39+
channel="#team-alpha-ci"
4040
elif [[ "$REF_NAME" == "merge-train/spartan-v5" ]]; then
41-
channel="#team-alpha"
41+
channel="#team-alpha-ci"
4242
else
4343
exit 0
4444
fi

ci3/merge_train_stale_check

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# Usage: merge_train_stale_check <merge-train-branch> <slack-channel>
77
#
88
# Example:
9-
# merge_train_stale_check merge-train/spartan '#team-alpha'
9+
# merge_train_stale_check merge-train/spartan '#team-alpha-ci'
1010
#
1111
# Required env vars:
1212
# GH_TOKEN — GitHub API token (used by `gh api`)

ci3/slack_notify

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,17 @@ fi
88
channel=${2:-"#aztec3-ci"}
99
data=$(jq -n --arg channel "$channel" --arg text "$1" '{channel: $channel, text: $text}')
1010

11-
curl -X POST https://slack.com/api/chat.postMessage \
11+
# Post to Slack, capturing the API response. Previously the response went to
12+
# /dev/null, so a failed post (most commonly the bot not being a member of the
13+
# target channel -> "not_in_channel", or an invalid channel/token) vanished with
14+
# no trace and could not be troubleshooted. Surface any failure in the CI log.
15+
# Best-effort: log the failure but do not fail the caller.
16+
response=$(curl -sS -X POST https://slack.com/api/chat.postMessage \
1217
-H "Authorization: Bearer $SLACK_BOT_TOKEN" \
1318
-H "Content-type: application/json" \
14-
--data "$data" &>/dev/null
19+
--data "$data" 2>&1)
20+
21+
if [ "$(jq -r '.ok // false' <<<"$response" 2>/dev/null)" != "true" ]; then
22+
error=$(jq -r '.error // empty' <<<"$response" 2>/dev/null)
23+
echo "slack_notify: failed to post to Slack channel '$channel': ${error:-$response}" >&2
24+
fi

scripts/socket-fix-ci.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ ${LINKS}"
122122
${LINKS}"
123123
fi
124124

125-
data=$(jq -n --arg channel "#team-alpha" --arg text "$TEXT" '{channel: $channel, text: $text}')
125+
data=$(jq -n --arg channel "#team-alpha-ci" --arg text "$TEXT" '{channel: $channel, text: $text}')
126126

127127
curl -X POST https://slack.com/api/chat.postMessage \
128128
-H "Authorization: Bearer $SLACK_BOT_TOKEN" \

0 commit comments

Comments
 (0)