We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
RequirementPreparer hashes more than necessary. This leads to poor performance on large wheels in the GB size range.
A call to prepare_linked_requirement calls down to _checked_download_dir.
pip/src/pip/_internal/operations/prepare.py
Line 501 in f5e4ee1
If the file exists in the download_dir, hashing is triggered. The file is marked as downloaded.
Line 516 in f5e4ee1
Then we head into _prepare_linked_requirement and eventually hash again. https://github.com/pypa/pip/blob/main/src/pip/_internal/operations/prepare.py#L612
Files which have passed the hash check can be marked as such, to prevent rehashing.
RequirementPreparer hashes each file at most once.
24.0
3.11
Windows 10
Construct a RequirementPreparer supplied with a download_dir. Run prepare_linked_requirement() for a link available as a wheel in the download_dir.
No response
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
RequirementPreparer hashes more than necessary. This leads to poor performance on large wheels in the GB size range.
A call to prepare_linked_requirement calls down to _checked_download_dir.
pip/src/pip/_internal/operations/prepare.py
Line 501 in f5e4ee1
If the file exists in the download_dir, hashing is triggered. The file is marked as downloaded.
pip/src/pip/_internal/operations/prepare.py
Line 516 in f5e4ee1
Then we head into _prepare_linked_requirement and eventually hash again.
https://github.com/pypa/pip/blob/main/src/pip/_internal/operations/prepare.py#L612
Potential Fix
Files which have passed the hash check can be marked as such, to prevent rehashing.
Expected behavior
RequirementPreparer hashes each file at most once.
pip version
24.0
Python version
3.11
OS
Windows 10
How to Reproduce
Construct a RequirementPreparer supplied with a download_dir. Run prepare_linked_requirement() for a link available as a wheel in the download_dir.
Output
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: