-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Refactor wheel info extraction during install #7536
Merged
chrahunt
merged 12 commits into
pypa:master
from
chrahunt:refactor/extract-wheel-info-functions
Jan 1, 2020
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
918b154
Move info_dir calculation up
chrahunt d66bc39
Split wheel_metadata from wheel_version
chrahunt ca729c8
Simplify wheel_version tests
chrahunt 42c6dd7
Use WHEEL metadata to determine Root-Is-Purelib
chrahunt c9b0742
Remove old root_is_purelib
chrahunt c51f020
Read WHEEL from .dist-info instead of using has_metadata
chrahunt 32115b5
Extract getting wheel .dist-info directory into a separate function
chrahunt a539c8d
Normalize exception message for dist_info_dir check
chrahunt e1c7de8
Raise UnsupportedWheel instead of AssertionError, and let caller add …
chrahunt 6c56557
Remove unused req_description from wheel_dist_info_dir
chrahunt fc48a17
Simplify positive wheel_version unit test
chrahunt 010c24d
Take .dist-info dir directly in wheel_metadata
chrahunt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 0 additions & 4 deletions
4
tests/data/packages/plat_wheel-1.7/plat_wheel-1.7.dist-info/WHEEL
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
tests/data/packages/plat_wheel-_invalidversion_/plat_wheel-_invalidversion_.dist-info/WHEEL
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
tests/data/packages/pure_wheel-1.7/pure_wheel-1.7.dist-info/WHEEL
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
tests/data/packages/pure_wheel-_invalidversion_/pure_wheel-_invalidversion_.dist-info/WHEEL
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit (and for a follow-up PR): since we have canonicalized everything we might as well check for an exact match
if not info_dir_name[:-len('.dist-info')] == canonical_name
this would catch a messed-up wheel with
canonical_name = foobar
andinfo_dir_name = foobar1234.dist-info
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the
.dist-info
dir also has version, we would need that too.