Skip to content

Commit 3899183

Browse files
committed
Log sync process failure instead of push fail.
1 parent 1edd70d commit 3899183

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

.drone.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ build:
66
- DEBIAN_FRONTEND=noninteractive
77
commands:
88
- apt-get update && apt-get install -qy build-essential python-pip python-virtualenv python-dev software-properties-common python-software-properties libfuse-dev fuse git libffi-dev python3.4-dev
9-
- sudo add-apt-repository -y ppa:presslabs/gitfs-dev
9+
- sudo add-apt-repository -y ppa:presslabs/gitfs
1010
- sudo apt-get update
1111
- sudo apt-get install -y libgit2 libgit2-dev
1212
- sudo chmod 660 /dev/fuse

gitfs/worker/sync.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,7 @@ def on_idle(self):
102102
log.debug("Retry-ing to sync with remote. Attempt #%d", count)
103103

104104
if count >= 5:
105-
log.debug("Didn't manage to sync, I need some help")
106-
105+
log.error("Didn't manage to sync, I need some help")
107106

108107
def merge(self):
109108
log.debug("Start merging")
@@ -149,10 +148,10 @@ def sync(self):
149148
sync_done.set()
150149
log.debug("Set push_successful")
151150
push_successful.set()
152-
except:
151+
except Exception as error:
153152
push_successful.clear()
154153
fetch.set()
155-
log.exception("Push failed")
154+
log.debug("Push failed because of %s", error)
156155
return False
157156
else:
158157
log.debug("Sync done, clearing")

0 commit comments

Comments
 (0)