[Pkg-rust-maintainers] Bug#932172: dh-cargo: please refresh json timestamps

Gianfranco Costamagna locutusofborg at debian.org
Tue Jul 16 09:33:39 BST 2019

Package: dh-cargo
Version: 18
Severity: serious
Tags: patch


Because of a Debian dak bug, no files with timestamp around 1970 was
rejected by it, so as soon as the dak patch is merged, every rust
package will fail to upload.
ls -l /usr/share/cargo/registry/which-2.0.1/.cargo_vcs_info.json
-rw-r--r-- 1 root root 74 Jan  1  1970 /usr/share/cargo/registry/which-2.0.1/.cargo_vcs_info.json

and so on for every file that apt-file gives you

This is what might happen in dak once the bug is fixed:
DEBUG Considering changefile 32677/ubuntu/rust-which_2.0.1-1ubuntu1_s390x.changes
DEBUG Finding fresh policy
INFO Processing upload rust-which_2.0.1-1ubuntu1_s390x.changes
INFO Upload was rejected:
INFO    librust-which-dev_2.0.1-1ubuntu1_s390x.deb: has 1 file(s) with a time stamp too far in the past (e.g. usr/share/cargo/registry/which-2.0.1/.cargo_vcs_info.json [Thu Jan  1 00:00:00 1970]).
INFO Committing the transaction and any mails associated with this upload.

(this happens in Ubuntu)

dak patch: https://deb.li/Ynw1

Please accept the trivial patch ASAP

@@ -175,6 +175,7 @@ sub install {

 sub clean {
     my $this=shift;
+    doit("touch", "--no-create", ".cargo_vcs_info.json");
     doit("/usr/share/cargo/bin/cargo", "clean", @_);
     doit("rm", "-rf", $this->get_sourcepath(".cargo-checksum.json"));
     doit("rm", "-rf", "debian/cargo_registry");

+dh-cargo (16ubuntu1) disco; urgency=medium
+  * Touch .cargo_vcs_info.json to update timestamp, as otherwise the file
+    has unix creation time of 0 which is rejected by the archive in the
+    .debs.
+ -- Dimitri John Ledkov <xnox at ubuntu.com>  Tue, 22 Jan 2019 17:50:10 +0000

More information about the Pkg-rust-maintainers mailing list