[Git][reproducible-builds/diffoscope][master] 2 commits: Revert "Allow stable-bpo to fail for now."

Chris Lamb (@lamby) gitlab at salsa.debian.org
Tue May 13 22:23:11 UTC 2025



Chris Lamb pushed to branch master at Reproducible Builds / diffoscope


Commits:
47591178 by Chris Lamb at 2025-05-13T15:22:10-07:00
Revert "Allow stable-bpo to fail for now."

Was added to allow contributor to merge MR.

This reverts commit 8425d51cc516a4ab15bc4acad4d53f8930d1dba0.

- - - - -
b1b0d849 by Chris Lamb at 2025-05-13T15:22:50-07:00
Don't rely on zipdetails' --walk being available, and only add that argument on newer versions. (Closes: reproducible-builds/diffoscope#408)

- - - - -


3 changed files:

- .gitlab-ci.yml
- diffoscope/comparators/zip.py
- tests/comparators/test_zip.py


Changes:

=====================================
.gitlab-ci.yml
=====================================
@@ -42,7 +42,6 @@ stable-bpo:
     - set -e; for pkg in coreboot-utils python3-pypdf systemd-ukify; do
         sed -i "/$pkg/d" debian/control ;
       done
-  allow_failure: true
 
 ubuntu-devel:
   <<: *test


=====================================
diffoscope/comparators/zip.py
=====================================
@@ -32,7 +32,11 @@ from diffoscope.tempfiles import get_named_temporary_file
 from .utils.file import File
 from .directory import Directory
 from .utils.archive import Archive, ArchiveMember
-from .utils.command import Command
+from .utils.command import Command, our_check_output
+
+
+def zipdetails_version():
+    return our_check_output(["zipdetails", "--version"]).decode("UTF-8")
 
 
 class Zipinfo(Command):
@@ -159,6 +163,16 @@ class Zipdetails(Command):
     def cmdline(self):
         # See <https://salsa.debian.org/reproducible-builds/diffoscope/-/issues/406>
         # for discussion of zipdetails command line arguments.
+        #
+        # Older zipdetails does not support --walk; added in Debian
+        # 5.40.0~rc1-1, but "zipdetails --version" shipped in, say, perl
+        # 5.36.0-7+deb12u1 returns "2.104".
+        #
+        # See <https://salsa.debian.org/reproducible-builds/diffoscope/-/issues/408>
+        #
+        if float(zipdetails_version()) < 4.0:
+            return ["zipdetails", "--redact", "--utc", self.path]
+
         return ["zipdetails", "--redact", "--walk", "--utc", self.path]
 
 


=====================================
tests/comparators/test_zip.py
=====================================
@@ -25,6 +25,7 @@ from diffoscope.comparators.zip import (
     MozillaZipFile,
     NuGetPackageFile,
     JmodJavaModule,
+    zipdetails_version,
 )
 
 from ..utils.data import load_fixture, assert_diff
@@ -47,10 +48,6 @@ test_comment1 = load_fixture("test_comment1.zip")
 test_comment2 = load_fixture("test_comment2.zip")
 
 
-def zipdetails_version():
-    return subprocess.check_output(["zipdetails", "--version"]).decode("UTF-8")
-
-
 def io_compress_zip_version():
     try:
         return subprocess.check_output(



View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/-/compare/09abd4cddbebdf0f2310c47dc562826e44f18088...b1b0d849f205a217b846f9e4a81064fe2e5f42b6

-- 
View it on GitLab: https://salsa.debian.org/reproducible-builds/diffoscope/-/compare/09abd4cddbebdf0f2310c47dc562826e44f18088...b1b0d849f205a217b846f9e4a81064fe2e5f42b6
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20250513/6e9570f0/attachment.htm>


More information about the rb-commits mailing list