From bc4bf66d17e38016733b310a3ca2ee7c2c762ae6 Mon Sep 17 00:00:00 2001 From: Saugat Pachhai Date: Sun, 14 Jun 2020 17:42:53 +0000 Subject: [PATCH] (bugfix) get/import: fix broken progress bar (#4039) PR #3672 (6d8499e) extended `LocalRemote::_get_plans` to return one `checksums` too. As all of the args from `_get_plans` was passed down to `download()`, it recognized extra arg of checksum as `no_progress_bar` due to which it became True and stopped showing progress bar at all. Fix #3874 --- dvc/remote/local.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/dvc/remote/local.py b/dvc/remote/local.py index b778ff46c6..9e6b7b6a2e 100644 --- a/dvc/remote/local.py +++ b/dvc/remote/local.py @@ -626,8 +626,12 @@ def _process( func = pbar.wrap_fn(func) with ThreadPoolExecutor(max_workers=jobs) as executor: if download: - fails = sum(executor.map(func, *dir_plans)) - fails += sum(executor.map(func, *file_plans)) + from_infos, to_infos, names, _ = ( + d + f for d, f in zip(dir_plans, file_plans) + ) + fails = sum( + executor.map(func, from_infos, to_infos, names) + ) else: # for uploads, push files first, and any .dir files last