From 16109a66b705211efd25f434201d113628aff04c Mon Sep 17 00:00:00 2001 From: Gavin Mak Date: Tue, 22 Aug 2023 01:24:46 +0000 Subject: upload: Suggest full sync if hooks fail with partially synced tree Pre-upload hooks may fail because of partial syncs. Bug: b/271507654 Change-Id: I124cd386c5af2c34e1dcaa3e86916624e235b1e3 Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/383474 Reviewed-by: Mike Frysinger Commit-Queue: Gavin Mak Tested-by: Gavin Mak --- subcmds/sync.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'subcmds/sync.py') diff --git a/subcmds/sync.py b/subcmds/sync.py index bbe03722..159771eb 100644 --- a/subcmds/sync.py +++ b/subcmds/sync.py @@ -1696,7 +1696,7 @@ later is required to fix a server side protocol bug. ) self._fetch_times = _FetchTimes(manifest) - self._local_sync_state = _LocalSyncState(manifest) + self._local_sync_state = LocalSyncState(manifest) if not opt.local_only: with multiprocessing.Manager() as manager: with ssh.ProxyManager(manager) as ssh_proxy: @@ -1932,7 +1932,7 @@ class _FetchTimes(object): platform_utils.remove(self._path, missing_ok=True) -class _LocalSyncState(object): +class LocalSyncState(object): _LAST_FETCH = "last_fetch" _LAST_CHECKOUT = "last_checkout" -- cgit v1.2.3-54-g00ecf