-
-
Notifications
You must be signed in to change notification settings - Fork 611
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
generate hashes uses up disk space #544
Comments
3 tasks
suutari
added a commit
to suutari/prequ
that referenced
this issue
Sep 2, 2017
The PyPIRepository._get_file_hash used to call unpack_url, when generating the hash. It only needed the side effect of the downloaded package being left in the download directory and the unpacking part was actually unnecessary. Change it to just open the (local or remote) package as a file object and hash the contents without unpacking. This makes it faster and lighter, since unpacking consumes CPU cycles and disk space, and more importantly, avoids problems which happen when some distribution has a file with the same name as a directory in another. Unpacking both to packages to the same directory will then fail. E.g. matplotlib-2.0.2.tar.gz has a directory named LICENSE, but many other packages have a file named LICENSE. Fixes jazzband#512, jazzband#544
Fixed by #557 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
hash algorithms are (generally) designed so they take up constant space to calculate a hash.
currently the steps are:
it should be:
This might need fixes upstream
The text was updated successfully, but these errors were encountered: