[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] Debian package checker branch, master, updated. 3ae1126d3fe81cee54ba0461306863a0dfcabe2c



The following commit has been merged in the master branch:
commit 3ae1126d3fe81cee54ba0461306863a0dfcabe2c
Author: Russ Allbery <rra@debian.org>
Date:   Sun Jul 13 15:59:37 2008 -0700

    Standards versions become ancient two years after obsolescence
    
    * checks/standards-version{.desc,}:
      + [RA] Base the two-year clock for ancient-standards-version on when
        the Policy version was superseded, not when it was issued.  Thanks,
        Scott Kitterman.  (Closes: #487780)

diff --git a/checks/standards-version b/checks/standards-version
index 8d4d6d4..38217c9 100644
--- a/checks/standards-version
+++ b/checks/standards-version
@@ -116,8 +116,18 @@ if (not exists $standards{$stdver}) {
     # Otherwise, we need to see if the standard that this package declares is
     # both new enough to not be ancient and was the current standard at the
     # time the package was uploaded.
-    my $stddate = $standards{$stdver};
-    if (str2time($stddate) < time - (60 * 60 * 24 * 365 * 2)) {
+    #
+    # A given standards version is considered obsolete if the version
+    # following it has been out for at least two years (so the current version
+    # is never obsolete).
+    my $obsdate = time;
+    for my $index (0 .. $#standards) {
+        if ($standards[$index][0] eq $stdver) {
+            $obsdate = $standards[$index - 1][1] if $index > 0;
+            last;
+        }
+    }
+    if (str2time($obsdate) + (60 * 60 * 24 * 365 * 2) < time) {
         tag 'ancient-standards-version', $tag;
     } else {
         # We have to get the package date from the changelog file.  If we
diff --git a/checks/standards-version.desc b/checks/standards-version.desc
index 5af8de9..7733e8a 100644
--- a/checks/standards-version.desc
+++ b/checks/standards-version.desc
@@ -30,9 +30,9 @@ Info: The source package refers to a Standards-Version which is
 
 Tag: ancient-standards-version
 Type: warning
-Info: The source package refers to a Standards-Version that is more than
- two years old.  Please update your package to latest Policy and set this
- control field appropriately.
+Info: The source package refers to a Standards-Version that has been
+ obsolete for more than two years.  Please update your package to latest
+ Policy and set this control field appropriately.
  .
  If the package is already compliant with the current standards, you don't
  have to re-upload the package just to adjust the Standards-Version
@@ -46,3 +46,8 @@ Info: The source package refers to a Standards-Version older than the one
  timestamp of the latest <tt>debian/changelog</tt> entry).  Please
  consider updating the package to current Policy and setting this control
  field appropriately.
+ .
+ If the package is already compliant with the current standards, you don't
+ have to re-upload the package just to adjust the Standards-Version
+ control field.  However, please remember to update this field next time
+ you upload the package.
diff --git a/debian/changelog b/debian/changelog
index 5b122e8..a6674bd 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -78,9 +78,12 @@ lintian (1.24.2) unstable; urgency=low
       (Closes: #452216)
     + [ADB] Check symbols files for dependencies that are not satisfied by
       the package itself (Closes: #461575)
-  * checks/standards-version:
+  * checks/standards-version{.desc,}:
     + [RA] Only issue out-of-date-standards-version once.  Noticed by
       Raphael Geissert.
+    + [RA] Base the two-year clock for ancient-standards-version on when
+      the Policy version was superseded, not when it was issued.  Thanks,
+      Scott Kitterman.  (Closes: #487780)
   * checks/watch-file{,.desc}:
     + [FL] Check for more Debian specific strings in version
       number.  Issue an info tag if the watch file uses
diff --git a/testset/tags.debconf b/testset/tags.debconf
index 5ef84a2..0400300 100644
--- a/testset/tags.debconf
+++ b/testset/tags.debconf
@@ -24,7 +24,6 @@ I: debconf-test: unused-debconf-template debconf/testnote
 I: debconf-test: unused-debconf-template debconf/teststring
 I: debconf-test: unused-debconf-template debconf/translate
 I: debconf-udeb udeb: unused-debconf-template debian-installer/debconf-udeb/title
-W: debconf source: ancient-standards-version 3.7.2 (current is 3.8.0)
 W: debconf source: debian-rules-calls-debhelper-in-odd-order dh_makeshlibs (line 49)
 W: debconf source: debian-rules-calls-debhelper-in-odd-order dh_makeshlibs (line 53)
 W: debconf source: debian-rules-sets-DH_COMPAT line 3

-- 
Debian package checker


Reply to: