Don't unconditionally create destination directory

Dropping the top-level directory creation allows us to make the
processing completely dependent on files to be installed, and not on the
top-level directory they happen to be installed in.

We already create the parent directory in the loop below, so this call
should be redundant for files that get installed.
This commit is contained in:
Chris Hunt 2020-07-05 11:25:00 -04:00
parent 2f9b50c097
commit 64dd286d88
1 changed files with 0 additions and 2 deletions

View File

@ -469,8 +469,6 @@ def install_unpacked_wheel(
filter=None # type: Optional[Callable[[text_type], bool]]
):
# type: (...) -> None
ensure_dir(dest) # common for the 'include' path
for dir, subdirs, files in os.walk(source):
basedir = dir[len(source):].lstrip(os.path.sep)
destdir = os.path.join(dest, basedir)