Skip to content
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

Order of hashes in pip lock file #4321

Closed
pcorpet opened this issue Oct 15, 2021 · 2 comments
Closed

Order of hashes in pip lock file #4321

pcorpet opened this issue Oct 15, 2021 · 2 comments
Labels
L: python:pip Python packages via pip T: bug 🐞 Something isn't working

Comments

@pcorpet
Copy link

pcorpet commented Oct 15, 2021

Dependabot is creating commits with diffs that are conflicting with other tools, because the order of the hash values is not lexicographical.

--- a/third_party/requirements_lock.txt
+++ b/third_party/requirements_lock.txt
-certifi==2021.5.30 \
-    --hash=sha256:2bbf76fd432960138b3ef6dda3dde0544f27cbf8546c458e60baf371917ba9ee \
-    --hash=sha256:50b1e4f8446b06f41be7dd6338db18e0990601dce795c2b1686458aa7e8fa7d8
+certifi==2021.10.8 \
+    --hash=sha256:d62a0163eb4c2344ac042ab2bdf75399a71a2d8c7d47eac2e2ee91b9d6339569 \
+    --hash=sha256:78884e7c1d4b00ce3cea67b44566851c4343c120abd683433ce934a68ea58872

Note that the second hash value starts with 7 which should be before the first one starting with d.

The fix could be in here. I've pinged the underlying library to check if we could expect the ordering to be lexicographical as well.

@jurre
Copy link
Member

jurre commented Oct 15, 2021

Thanks for reporting this! Let's see what the hashin maintainer says, if they're not able to fix it on their end right now we can patch it up on our side.

@xlgmokha xlgmokha added L: python:pip Python packages via pip T: bug 🐞 Something isn't working labels Nov 4, 2021
@pcorpet
Copy link
Author

pcorpet commented Jan 10, 2022

@jurre, hashin v0.17.0 is out and contain my fix. As soon as #4610 is accepted and merged, we can close this bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
L: python:pip Python packages via pip T: bug 🐞 Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants