From c52f57094c0db6089b357d18ab1354f319a3b31b Mon Sep 17 00:00:00 2001 From: Antoine du Hamel Date: Fri, 21 Aug 2026 15:22:48 +0200 Subject: [PATCH] tools: fix max body length handler in `create-release-proposal.sh` Signed-off-by: Antoine du Hamel --- tools/actions/create-release-proposal.sh | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/tools/actions/create-release-proposal.sh b/tools/actions/create-release-proposal.sh index f4878f1cc940..9240fa2ad7f7 100755 --- a/tools/actions/create-release-proposal.sh +++ b/tools/actions/create-release-proposal.sh @@ -35,9 +35,14 @@ HEAD_SHA="$(git rev-parse HEAD^)" TITLE="$(git log -1 --format=%s)" -TEMP_BODY="$(awk -v MAX_BODY_LENGTH="65536" \ - "/^## ${RELEASE_DATE}/,/^ MAX_BODY_LENGTH) {exit 1;} print }" \ - "doc/changelogs/CHANGELOG_V${RELEASE_LINE}.md" || echo "…")" +# GH rest API has an undocumented limit of 65536 char for the body, setting it +# to 65534 to account for the ellipsis and the final EOL. +TEMP_BODY="$(awk -v MAX_BODY_LENGTH="65534" \ + "/^## ${RELEASE_DATE}/,/^ MAX_BODY_LENGTH) {exit 1;} + print + }" "doc/changelogs/CHANGELOG_V${RELEASE_LINE}.md" || echo "…")" # Create the proposal branch gh api \