tags 873520 + patch wontfix thanks Hi,
> lintian: Check for bad-distribution in debian/changelog too Patch attached (see below). However, unless I'm missing something this would mean that every time you built a package locally as part of regular development it would emit this tag. I think this would be far too annoying, so am marking this as wontfix unless one can think of a nicer way of detecting this. commit 0c261c49b135a50a88b443ed8dc1a627b2c6358d Author: Chris Lamb <la...@debian.org> Date: Tue Oct 17 19:17:30 2017 -0400 Check source packages for UNRELEASED distributions too. (Closes: #873520) checks/source-changelog.desc | 7 +++++++ checks/source-changelog.pm | 4 ++++ debian/changelog | 2 ++ .../changelog-file-national-encoding/debian/debian/changelog.in | 2 +- t/tests/changelog-file-unreleased/desc | 2 ++ t/tests/changelog-file-unreleased/tags | 1 + t/tests/standards-version-timewarp-unrel/desc | 2 ++ t/tests/standards-version-timewarp-unrel/tags | 1 + 8 files changed, 20 insertions(+), 1 deletion(-) Regards, -- ,''`. : :' : Chris Lamb `. `'` la...@debian.org / chris-lamb.co.uk `-
>From 0c261c49b135a50a88b443ed8dc1a627b2c6358d Mon Sep 17 00:00:00 2001 From: Chris Lamb <la...@debian.org> Date: Tue, 17 Oct 2017 19:17:30 -0400 Subject: [PATCH] Check source packages for UNRELEASED distributions too. (Closes: #873520) --- checks/source-changelog.desc | 7 +++++++ checks/source-changelog.pm | 4 ++++ debian/changelog | 2 ++ .../changelog-file-national-encoding/debian/debian/changelog.in | 2 +- t/tests/changelog-file-unreleased/desc | 2 ++ t/tests/changelog-file-unreleased/tags | 1 + t/tests/standards-version-timewarp-unrel/desc | 2 ++ t/tests/standards-version-timewarp-unrel/tags | 1 + 8 files changed, 20 insertions(+), 1 deletion(-) diff --git a/checks/source-changelog.desc b/checks/source-changelog.desc index 32f4615ea..949c1b3c2 100644 --- a/checks/source-changelog.desc +++ b/checks/source-changelog.desc @@ -16,3 +16,10 @@ Info: The latest Debian changelog entry has either the same or even an This can result in subtle bugs due to the <tt>SOURCE_DATE_EPOCH</tt> environment variable being the same between the older and newer versions. + +Tag: unreleased-changelog-distribution +Severity: important +Certainty: certain +Info: The distribution in the latest Debian changelog entry indicates + that this package was not intended to be released yet. +Ref: #873520 diff --git a/checks/source-changelog.pm b/checks/source-changelog.pm index d37c4d5ea..29f19502d 100644 --- a/checks/source-changelog.pm +++ b/checks/source-changelog.pm @@ -29,6 +29,10 @@ sub run { my ($pkg, undef, $info, undef, undef) = @_; my @entries = $info->changelog->data; + + tag 'unreleased-changelog-distribution' if + @entries and lc($entries[0]->Distribution) eq 'unreleased'; + if (@entries > 1) { my $first_timestamp = $entries[0]->Timestamp; my $second_timestamp = $entries[1]->Timestamp; diff --git a/debian/changelog b/debian/changelog index 2facee400..e61f6e367 100644 --- a/debian/changelog +++ b/debian/changelog @@ -29,6 +29,8 @@ lintian (2.5.56) UNRELEASED; urgency=medium * checks/source-changelog.{desc.pm}: + [CL] Move latest-debian-changelog-entry-without-new-date tag into a new check of type "source". (Closes: #873612) + + [CL] Check source packages for UNRELEASED distributions too. + (Closes: #873520) * checks/watch-file.pm: + [CL] Include the offending URI in debian-watch-uses-insecure-uri output, not the line number. diff --git a/t/tests/changelog-file-national-encoding/debian/debian/changelog.in b/t/tests/changelog-file-national-encoding/debian/debian/changelog.in index 39df74576..27145cd14 100644 --- a/t/tests/changelog-file-national-encoding/debian/debian/changelog.in +++ b/t/tests/changelog-file-national-encoding/debian/debian/changelog.in @@ -1,4 +1,4 @@ -{$source} ({$version}) UNRELEASED; urgency=low +{$source} ({$version}) unstable; urgency=low * Lintian Test Suite. * Test: {$testname} diff --git a/t/tests/changelog-file-unreleased/desc b/t/tests/changelog-file-unreleased/desc index 0b0285429..f5a0f3494 100644 --- a/t/tests/changelog-file-unreleased/desc +++ b/t/tests/changelog-file-unreleased/desc @@ -4,4 +4,6 @@ Description: Suppress new date warnings for UNRELEASED Test-Against: latest-changelog-entry-without-new-date latest-debian-changelog-entry-without-new-date +Test-For: + unreleased-changelog-distribution References: Debian Bug#560149 diff --git a/t/tests/changelog-file-unreleased/tags b/t/tests/changelog-file-unreleased/tags index e69de29bb..976ead062 100644 --- a/t/tests/changelog-file-unreleased/tags +++ b/t/tests/changelog-file-unreleased/tags @@ -0,0 +1 @@ +E: changelog-file-unreleased source: unreleased-changelog-distribution diff --git a/t/tests/standards-version-timewarp-unrel/desc b/t/tests/standards-version-timewarp-unrel/desc index d0647c6a0..80104c7f9 100644 --- a/t/tests/standards-version-timewarp-unrel/desc +++ b/t/tests/standards-version-timewarp-unrel/desc @@ -1,5 +1,7 @@ Testname: standards-version-timewarp-unrel Version: 1.0 Description: Test newer standards version with unreleased old changelog date +Test-For: + unreleased-changelog-distribution Test-Against: timewarp-standards-version diff --git a/t/tests/standards-version-timewarp-unrel/tags b/t/tests/standards-version-timewarp-unrel/tags index e69de29bb..ce11b709b 100644 --- a/t/tests/standards-version-timewarp-unrel/tags +++ b/t/tests/standards-version-timewarp-unrel/tags @@ -0,0 +1 @@ +E: standards-version-timewarp-unrel source: unreleased-changelog-distribution -- 2.15.0.rc1