1
1
Fork 0
mirror of https://github.com/pypa/pip synced 2023-12-13 21:30:23 +01:00

Merge pull request #8722 from McSinyx/late-dl-indent

Dedent late download logs
This commit is contained in:
Xavier Fernandez 2020-09-16 14:02:51 +02:00 committed by GitHub
commit 33890bf825
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 42 additions and 45 deletions

View file

@ -519,7 +519,6 @@ class RequirementPreparer(object):
link = req.link
download_dir = self._get_download_dir(link)
with indent_log():
self._ensure_link_req_src_dir(req, download_dir, parallel_builds)
hashes = self._get_linked_req_hashes(req)
if link.url not in self._downloaded:
@ -539,8 +538,8 @@ class RequirementPreparer(object):
hashes.check_against_path(file_path)
local_file = File(file_path, content_type)
# For use in later processing, preserve the file path on the
# requirement.
# For use in later processing,
# preserve the file path on the requirement.
if local_file:
req.local_file_path = local_file.path
@ -552,9 +551,7 @@ class RequirementPreparer(object):
if link.is_existing_dir():
logger.info('Link is a directory, ignoring download_dir')
elif local_file:
download_location = os.path.join(
download_dir, link.filename
)
download_location = os.path.join(download_dir, link.filename)
if not os.path.exists(download_location):
shutil.copy(local_file.path, download_location)
download_path = display_path(download_location)