From fb3a41f224c8c5f8b8165e63563c538fd0db390d Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Tue, 17 Nov 2026 19:42:39 -0800 Subject: [PATCH] release notes: skip the release edit when the notes are already grouped Co-Authored-By: Claude Opus 5.5 --- .github/scripts/release_notes_by_component.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/scripts/release_notes_by_component.py b/.github/scripts/release_notes_by_component.py index b7e6a0af88..d9bb6093f9 100644 --- a/.github/scripts/release_notes_by_component.py +++ b/.github/scripts/release_notes_by_component.py @@ -280,9 +280,10 @@ def main(): notes = regroup(body, pr_files) except ValueError as e: sys.exit("release %s: %s" % (args.tag, e)) + sys.stdout.write(notes) if notes.strip() == body.replace("\r\n", "\n").strip(): print("release %s: notes already grouped, nothing to change" % args.tag, file=sys.stderr) - sys.stdout.write(notes) + return if failed and args.write: sys.exit("release %s: not writing, could not read the files of %s" % (args.tag, ", ".join("#%d" % n for n in failed)))