From 809bb8ee48a0c6b4dc370979088b8309fdde308a Mon Sep 17 00:00:00 2001 From: Florent Clarret Date: Tue, 3 Dec 2024 16:32:39 +0100 Subject: [PATCH] Add the version to the slack notification for RC PRs (#31710) --- tasks/release.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tasks/release.py b/tasks/release.py index 9d2ce03afe866..cabf0568e9d20 100644 --- a/tasks/release.py +++ b/tasks/release.py @@ -449,9 +449,12 @@ def create_rc(ctx, major_versions="6,7", patch_version=False, upstream="origin", # Step 4 - If slack workflow webhook is provided, send a slack message if slack_webhook: print(color_message("Sending slack notification", "bold")) - ctx.run( - f"curl -X POST -H 'Content-Type: application/json' --data '{{\"pr_url\":\"{pr_url}\"}}' {slack_webhook}" - ) + payload = { + "pr_url": pr_url, + "version": str(new_highest_version), + } + + ctx.run(f"curl -X POST -H 'Content-Type: application/json' --data '{json.dumps(payload)}' {slack_webhook}") @task