From d8e2897a79889970eedf7223893ca3e76b898f2d Mon Sep 17 00:00:00 2001 From: Rene Fichtmueller Date: Sat, 18 Jul 2026 07:13:21 +0000 Subject: [PATCH] fix: add missing header when CHANGELOG_PENDING.md pre-exists but is empty The repo already had an empty CHANGELOG_PENDING.md from 2026-03-30, so the FileNotFoundError branch that adds the header/marker never fired -- the first automated entry landed with no header, just leading blank lines. Treat an existing-but-blank file the same as a missing one. Also fixes up the header on the entry already drafted by the previous run. [skip ci] --- .github/scripts/changelog-draft.py | 2 ++ CHANGELOG_PENDING.md | 3 +++ 2 files changed, 5 insertions(+) diff --git a/.github/scripts/changelog-draft.py b/.github/scripts/changelog-draft.py index 7dc378a..f9e96d7 100644 --- a/.github/scripts/changelog-draft.py +++ b/.github/scripts/changelog-draft.py @@ -83,6 +83,8 @@ def main(): try: with open("CHANGELOG_PENDING.md", "r") as f: existing = f.read() + if not existing.strip(): + existing = PENDING_HEADER # pre-existing but empty placeholder file except FileNotFoundError: existing = PENDING_HEADER diff --git a/CHANGELOG_PENDING.md b/CHANGELOG_PENDING.md index 876f847..170935e 100644 --- a/CHANGELOG_PENDING.md +++ b/CHANGELOG_PENDING.md @@ -1,5 +1,8 @@ +# Pending Changelog Entries +Drafted automatically from commit messages since the last processed push. Review, edit as needed, and fold into CHANGELOG.md -- then clear this file. + ## Pending -- 2026-07-18 ### Fixed