From 25857b8988de60d7c7a8593c6170b2bbf80d748d Mon Sep 17 00:00:00 2001 From: David Pursehouse Date: Wed, 19 Aug 2015 18:06:22 +0900 Subject: [PATCH] Fix formatting of message when retrying clone Passing the force_sync variable into the string formatting results in the message: "Retrying clone after deleting None" or "Retrying clone after deleting True". Pass the name of the git directory instead. Also, move the print inside the if-block so it's only displayed when the retry is actually going to be attempted. Change-Id: I76d9ecc176cecee4ad512d13e9d1f6bd36aacbbb --- project.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project.py b/project.py index a117f4df..ac60ccc1 100644 --- a/project.py +++ b/project.py @@ -2182,8 +2182,8 @@ class Project(object): try: self._CheckDirReference(self.objdir, self.gitdir, share_refs=False) except GitError as e: - print("Retrying clone after deleting %s" % force_sync, file=sys.stderr) if force_sync: + print("Retrying clone after deleting %s" % self.gitdir, file=sys.stderr) try: shutil.rmtree(os.path.realpath(self.gitdir)) if self.worktree and os.path.exists(