#871938 pristine-tar: Cannot reproduce planetfilter-0.7.4.tar.gz

Package:
pristine-tar
Source:
pristine-tar
Description:
regenerate pristine tarballs
Submitter:
Francois Marier
Date:
2021-11-29 09:33:03 UTC
Severity:
normal
#871938#5
Date:
2017-08-12 18:31:38 UTC
From:
To:
$ wget 'https://pypi.python.org/packages/3b/f5/71cc36f37b2e91aa36cb4234adfa6eaad5f55947eddc9035efe7280cf400/planetfilter-0.7.4.tar.gz#md5=1f810bb2398890a464665f2eaea168e2'
...
$ tar zxf planetfilter-0.7.4.tar.gz
$ cd planetfilter-0.7.4/
$ git init
$ git add .
$ git commit -a -m "Initial commit"
$ pristine-tar gendelta ../planetfilter-0.7.4.tar.gz ../delta
$ pristine-tar gentar ../delta ../planetfilter-0.7.4-new.tar.gz
xdelta3: target window checksum mismatch: XD3_INVALID_INPUT
xdelta3: normally this indicates that the source file is incorrect
xdelta3: please verify the source file with sha1sum or equivalent
xdelta3 decode failed! at /usr/share/perl5/Pristine/Tar/DeltaTools.pm line 56.
pristine-tar: command failed: pristine-gz --no-verbose --no-debug --no-keep gengz /tmp/user/1000/pristine-tar.LHWZr2M6cN/wrapper /tmp/user/1000/pristine-tar.KmM6S0BUty/planetfilter-0.7.4-new.tar.gz.tmp

Original tarball is attached.

Also described on: https://feeding.cloud.geek.nz/posts/pristine-tar-and-git-buildpackage-work-arounds/

Francois

#871938#10
Date:
2017-08-12 19:00:52 UTC
From:
To:
Here's the .delta file I forgot to include.
#871938#15
Date:
2017-08-20 22:27:33 UTC
From:
To:
I confirm the issue. At first, I thought it's due to the new delta
format, but then verified it reproduces with the previous format as well.

The problem seems to lay in the "zgz" utility which incorrectly
rebuilds the file, e.g., the file size does not match. It seems harder
than I expected, will have to investigate more.

Tomasz

#871938#20
Date:
2017-08-20 22:59:57 UTC
From:
To:
That's a regression in the version 1.40 of pristine-tar (during the
commit).  It's almost surely due to
https://anonscm.debian.org/cgit/collab-maint/pristine-tar.git/commit/?id=0743dd36ed90c18982a5a861f4978080c1c4a2e3.

Here is what 1.39 executes during commit:

    zgz -9 --original-name dist/planetfilter-0.7.4.tar --osflag 255 -T 1501972711 -c

And here is what 1.40 does:

    zgz --gnu -9 -T 1501972711

(these can obtained if you use -v switch to pristine-tar).
Extraction works fine in both cases, assuming the file was committed using 1.39.

CCing Lennart. Lennart, could you investigate?

Tomasz

#871938#25
Date:
2017-08-20 23:54:25 UTC
From:
To:
I did some more investigation into this and committed a workaround
which avoids the problematic case [1]. I didn't have time to dig
really into the main problem, though. I'd prefer to understand the zgz
problem before uploading this.

Tomasz

[1] https://anonscm.debian.org/cgit/collab-maint/pristine-tar.git/commit/?id=f7783d4096be24d235b77b9e8f4e3476faf8cd5d

#871938#30
Date:
2021-11-29 09:30:59 UTC
From:
To:
Tomasz,

[...]
[1] https://anonscm.debian.org/cgit/collab-maint/pristine-tar.git/commit/?id=f7783d4096be24d235b77b9e8f4e3476faf8cd5d
[...]


Where is this patch now ?

Thanks