From: Michal Nowak Date: Wed, 18 Jun 2025 07:52:37 +0000 (+0200) Subject: Make empty changelog fatal error X-Git-Tag: v9.20.11~12^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5fa13bedf5e5a75dfece4fa8fe67d6614a672a47;p=thirdparty%2Fbind9.git Make empty changelog fatal error The prep_doc_mr.py script of the bind9-qa repo needs a way to know that gitchangelog.py did not produce entries. In the case of release notes, it dies with "No commits matching given revlist". For changelog entries it used to warn about "Empty changelog", but did not return non-zero exit code. (cherry picked from commit 4d0ae4068f07a0f1a62b11629d3f26d798bddb45) --- diff --git a/contrib/gitchangelog/gitchangelog.py b/contrib/gitchangelog/gitchangelog.py index 7d22fe483d5..33583185b9a 100755 --- a/contrib/gitchangelog/gitchangelog.py +++ b/contrib/gitchangelog/gitchangelog.py @@ -1889,8 +1889,7 @@ def changelog( try: first_version = next(versions) except StopIteration: - warn("Empty changelog. No commits were elected to be used as entry.") - data["versions"] = [] + die("Empty changelog. No commits were elected to be used as entry.") else: data["versions"] = itertools.chain([first_version], versions)