-
Notifications
You must be signed in to change notification settings - Fork 740
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow non-nested archives for
hexdump
and others (#1564)
## Summary#1562 It turns out that `hexdump` uses an invalid source distribution format whereby the contents aren't nested in a top-level directory -- instead, they're all just flattened at the top-level. In looking at pip's source (https://github.com/pypa/pip/blob/51de88ca6459fdd5213f86a54b021a80884572f9/src/pip/_internal/utils/unpacking.py#L62), it only strips the top-level directory if all entries have the same directory prefix (i.e., if it's the only thing in the directory). This PR accommodates these "invalid" distributions. I can't find any history on this method in `pip`. It looks like it dates back over 15 years ago, to before `pip` was even called `pip`. Closes #1376.
- Loading branch information
1 parent
4a09889
commit 340cb67
Showing
4 changed files
with
26 additions
and
13 deletions.
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
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
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
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