diff --git a/subcmds/sync.py b/subcmds/sync.py index 9ae8a4ce..0e4f34c0 100644 --- a/subcmds/sync.py +++ b/subcmds/sync.py @@ -677,9 +677,6 @@ later is required to fix a server side protocol bug. cls.ssh_proxy = ssh_proxy def _GetSyncProgressMessage(self): - if len(self._sync_dict) == 0: - return None - earliest_time = float("inf") earliest_proj = None for project, t in self._sync_dict.items(): @@ -687,6 +684,9 @@ later is required to fix a server side protocol bug. earliest_time = t earliest_proj = project + if not earliest_proj: + return None + elapsed = time.time() - earliest_time jobs = jobs_str(len(self._sync_dict)) return f"{jobs} | {elapsed_str(elapsed)} {earliest_proj}"