-
Notifications
You must be signed in to change notification settings - Fork 380
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Checksum test failure on Ubuntu #2874
Comments
When you build locally, do you see the same failure also without the patch associated with the PR in that CI job? This test has hardcoded checksums to test build reproducibility (with There probably are other factors that also cause these checksums to change but I can't think of anything right now. |
One thing I noticed is that, in this case, even the payload checksums have changed. An RPM version bump would only affect the header checksums... So there must be something else at play here. |
I reset the rpm-sequoia branch to the last release (v1.5.0), and I see the same error.
|
Hmm, that's indeed strange. I tried to reproduce the same myself (using the steps you provided, thanks!) but could not - the test passed for me. Could you try doing this against a new, fresh build of RPM in another directory? |
If guessing and trying fails, 'runroot rpm -qp --xml /build/RPMS/noarch/attrtest-1.0-1.noarch.rpm' is your friend, one can then diff the output of that between working and non-working files. We should probably dump that output anyway to make it more debuggable. |
I did one better, I tried for a fresh Fedora 39 VM :D. There it works for me. Perhaps the issue is that rpm-sequoia's CI is running the test suite from Ubuntu. Do you think that could be a cause of the problem? |
I remember a case or two where the checksums mismatch due to different libmagic versions producing different strings. I also remember tweaking the test to avoid relying on libmagic stuff there, but don't remember when exactly. But yes, it's fragile. Very. |
4.18.2 would be missing at least this: 7ec148c which could affect it. |
Yup, and the CI running on Ubuntu could indeed have an effect on the checksums. I can't see any obvious candidates in the tag list but it would be useful if you could get us the output of |
My built
Instead I've attached the generated rpm file (found in |
Thanks! Meanwhile, I did a build of RPM in an Ubuntu 22.04 LTS container and got the exact same package as you, the diff follows: diff --git a/fedora.xml b/ubuntu.xml
index c4f4df7..6546d2e 100644
--- a/fedora.xml
+++ b/ubuntu.xml
@@ -6,14 +6,14 @@
<integer>5925</integer>
</rpmTag>
<rpmTag name="Sigmd5">
- <base64>iNEDdobtP19rZ2GLAsxH7w==
+ <base64>mNM0PRkFKXQ5LtOJ4SH0+A==
</base64>
</rpmTag>
<rpmTag name="Sha1header">
- <string>a42c611d67870c1937623f0da2631eabdf33e948</string>
+ <string>8036a9b66aa7781e4000a441e695bb076acfc450</string>
</rpmTag>
<rpmTag name="Sha256header">
- <string>eb512d3d8c282d0249701032591c53ffb5904c54c95de04783028387b224d8fe</string>
+ <string>94d13620f7058c14f24605c1461a9ef89b5b50b80c421a0a0eb7f0c62fe0f638</string>
</rpmTag>
<rpmTag name="Name">
<string>attrtest</string>
@@ -502,12 +502,12 @@
<string>utf-8</string>
</rpmTag>
<rpmTag name="Payloaddigest">
- <string>116ce41ebb72f1877cda3d7dedaf5b78770e202d6389ade4e415d78548d703a8</string>
+ <string>91438332ac8fe92e4d4fcd45edb64b659323b893d9496a339f8587d19d00531a</string>
</rpmTag>
<rpmTag name="Payloaddigestalgo">
<integer>8</integer>
</rpmTag>
<rpmTag name="Payloaddigestalt">
- <string>116ce41ebb72f1877cda3d7dedaf5b78770e202d6389ade4e415d78548d703a8</string>
+ <string>91438332ac8fe92e4d4fcd45edb64b659323b893d9496a339f8587d19d00531a</string>
</rpmTag>
</rpmHeader> So apparently the checksums are affected by the running OS, although all the other tags are equivalent. |
This is because |
Okay, the headers are otherwise identical so it's the payload that has to differ then, and that payloaddigest changing throws everything else off too. And indeed, extracting the rpm2cpio output shows some differences (from
What that difference actually is and why it happens, no clue. Rpm writes its own cpio so this isn't due to some cpio utility version differences. |
Looking at This from the Ubuntu-created file:
And this on Fedora:
I bet uid 2 is "bin" instead on Ubuntu:
...yep (containers FTW):
In 4.18.x we still do some name->uid lookups in the build even though all that supposedly is unused. I guess not... |
So this is actually another bug fixed by a0553eb |
I've just tried this with the latest RPM snapshot on master and this checksum test still fails on Ubuntu, even with commit a0553eb in place. This time, though, the payload is identical (as confirmed with |
Mmm, but with current master the test would be running on Fedora because there's no native test-suite for Ubuntu? Those matryoshkas are really out to get us now. |
OK, I was a bit vague above, so to clarify: What I did was:
Note that this is currently not supported in our test-suite on master so I used my draft #2830 patch here. TL;DR: I did run the test-suite on Ubuntu, it's just not supported out-of-the-box in our test-suite right now (pending in #2830) 😄 |
I'm noticing a test suite failure when building 4.18.2. See this CI output
I'm seeing the same failure when building locally. (I'm following the instructions here).
I'd appreciate any tips on how to debug this.
The text was updated successfully, but these errors were encountered: